From 8dda51e236a2b30a98a5ae3a73f36e879bd10b3a Mon Sep 17 00:00:00 2001 From: John Vu Date: Tue, 10 Oct 2023 15:00:52 -0700 Subject: [PATCH] Label >v4.X.X as beta --- .dockerignore | 3 + .github/workflows/build.yml | 32 + .../workflows/publish-to-github-releases.yml | 17 + .github/workflows/publish-to-pypi.yml | 42 + .github/workflows/publish.yaml | 104 - .github/workflows/publish.yml | 87 + .gitignore | 68 +- .swagger-codegen-ignore | 22 +- .swagger-codegen/VERSION | 1 - .travis.yml | 13 - CHANGELOG | 0 CONTRIBUTORS | 0 Dockerfile | 20 + MANIFEST.in | 4 + README.md | 1404 +------- TESTING | 4 + VERSION | 1 + asana/__init__.py | 496 +-- asana/api/__init__.py | 40 - asana/api/attachments_api.py | 464 --- asana/api/audit_log_api_api.py | 162 - asana/api/batch_api_api.py | 139 - asana/api/custom_field_settings_api.py | 253 -- asana/api/custom_fields_api.py | 888 ----- asana/api/events_api.py | 139 - asana/api/goal_relationships_api.py | 586 ---- asana/api/goals_api.py | 1137 ------ asana/api/jobs_api.py | 135 - asana/api/memberships_api.py | 439 --- asana/api/organization_exports_api.py | 241 -- asana/api/portfolio_memberships_api.py | 363 -- asana/api/portfolios_api.py | 1340 ------- asana/api/project_briefs_api.py | 460 --- asana/api/project_memberships_api.py | 249 -- asana/api/project_statuses_api.py | 456 --- asana/api/project_templates_api.py | 562 --- asana/api/projects_api.py | 2132 ----------- asana/api/rules_api.py | 142 - asana/api/sections_api.py | 772 ---- asana/api/status_updates_api.py | 460 --- asana/api/stories_api.py | 570 --- asana/api/tags_api.py | 880 ----- asana/api/task_templates_api.py | 351 -- asana/api/tasks_api.py | 3124 ----------------- asana/api/team_memberships_api.py | 477 --- asana/api/teams_api.py | 806 ----- asana/api/time_periods_api.py | 253 -- asana/api/time_tracking_entries_api.py | 570 --- asana/api/typeahead_api.py | 155 - asana/api/user_task_lists_api.py | 245 -- asana/api/users_api.py | 583 --- asana/api/webhooks_api.py | 566 --- asana/api/workspace_memberships_api.py | 359 -- asana/api/workspaces_api.py | 574 --- asana/api_client.py | 650 ---- asana/client.py | 367 ++ asana/configuration.py | 253 -- asana/error.py | 105 + asana/models/__init__.py | 452 --- .../add_custom_field_setting_request.py | 197 -- asana/models/add_followers_request.py | 113 - asana/models/add_members_request.py | 113 - asana/models/all_of_project_response_owner.py | 84 - .../all_of_project_template_base_owner.py | 84 - .../all_of_project_template_response_owner.py | 84 - .../all_of_story_response_new_date_value.py | 84 - .../all_of_story_response_old_date_value.py | 84 - ...ll_of_task_template_response_created_by.py | 84 - .../all_of_task_template_response_project.py | 84 - .../all_of_task_template_response_template.py | 84 - .../all_of_user_task_list_base_owner.py | 84 - .../all_of_user_task_list_base_workspace.py | 84 - .../all_of_user_task_list_compact_owner.py | 84 - ...all_of_user_task_list_compact_workspace.py | 84 - .../all_of_user_task_list_request_owner.py | 84 - ...all_of_user_task_list_request_workspace.py | 84 - .../all_of_user_task_list_response_owner.py | 84 - ...ll_of_user_task_list_response_workspace.py | 84 - ...embership_response_user_task_list_owner.py | 84 - ...rship_response_user_task_list_workspace.py | 84 - asana/models/asana_named_resource.py | 168 - asana/models/asana_named_resource_array.py | 137 - asana/models/asana_resource.py | 140 - asana/models/attachment_base.py | 196 -- asana/models/attachment_compact.py | 196 -- asana/models/attachment_request.py | 259 -- asana/models/attachment_response.py | 416 --- asana/models/attachment_response_array.py | 137 - asana/models/attachment_response_data.py | 111 - asana/models/attachment_response_parent.py | 222 -- .../attachment_response_parent_created_by.py | 140 - asana/models/audit_log_event.py | 302 -- asana/models/audit_log_event_actor.py | 202 -- asana/models/audit_log_event_array.py | 137 - asana/models/audit_log_event_context.py | 236 -- asana/models/audit_log_event_details.py | 84 - asana/models/audit_log_event_resource.py | 224 -- asana/models/batch_body.py | 110 - asana/models/batch_request.py | 110 - asana/models/batch_request_action.py | 202 -- asana/models/batch_request_actions.py | 202 -- asana/models/batch_request_options.py | 168 - asana/models/batch_response.py | 168 - asana/models/batch_response_array.py | 137 - asana/models/create_membership_request.py | 168 - .../create_time_tracking_entry_request.py | 140 - asana/models/custom_field_base.py | 754 ---- asana/models/custom_field_base_date_value.py | 140 - .../models/custom_field_base_enum_options.py | 224 -- asana/models/custom_field_base_enum_value.py | 224 -- asana/models/custom_field_compact.py | 484 --- .../custom_field_gid_enum_options_body.py | 110 - asana/models/custom_field_request.py | 839 ----- asana/models/custom_field_response.py | 836 ----- asana/models/custom_field_response_array.py | 137 - .../custom_field_response_created_by.py | 168 - asana/models/custom_field_response_data.py | 111 - .../custom_field_response_people_value.py | 168 - asana/models/custom_field_setting_base.py | 140 - asana/models/custom_field_setting_compact.py | 140 - asana/models/custom_field_setting_response.py | 246 -- .../custom_field_setting_response_array.py | 137 - ...tom_field_setting_response_custom_field.py | 836 ----- .../custom_field_setting_response_data.py | 111 - .../custom_field_setting_response_parent.py | 168 - .../custom_field_setting_response_project.py | 168 - asana/models/custom_fields_body.py | 110 - .../custom_fields_custom_field_gid_body.py | 110 - asana/models/date_variable_compact.py | 168 - asana/models/date_variable_request.py | 140 - asana/models/empty_response.py | 84 - asana/models/empty_response_data.py | 111 - asana/models/enum_option.py | 224 -- asana/models/enum_option_base.py | 224 -- asana/models/enum_option_data.py | 111 - asana/models/enum_option_insert_request.py | 169 - asana/models/enum_option_request.py | 280 -- .../enum_options_enum_option_gid_body.py | 110 - asana/models/enum_options_insert_body.py | 110 - asana/models/error.py | 168 - asana/models/error_response.py | 110 - asana/models/error_response_errors.py | 168 - asana/models/event_response.py | 272 -- asana/models/event_response_array.py | 137 - asana/models/event_response_change.py | 224 -- asana/models/event_response_parent.py | 168 - asana/models/event_response_resource.py | 168 - asana/models/event_response_user.py | 168 - asana/models/goal_add_subgoal_request.py | 169 - ...oal_add_supporting_relationship_request.py | 197 -- .../goal_add_supporting_work_request.py | 113 - asana/models/goal_base.py | 336 -- asana/models/goal_compact.py | 194 - asana/models/goal_gid_add_followers_body.py | 110 - ...al_gid_add_supporting_relationship_body.py | 110 - .../models/goal_gid_remove_followers_body.py | 110 - ...gid_remove_supporting_relationship_body.py | 110 - asana/models/goal_gid_set_metric_body.py | 110 - .../goal_gid_set_metric_current_value_body.py | 110 - asana/models/goal_membership_base.py | 280 -- asana/models/goal_membership_base_goal.py | 194 - asana/models/goal_membership_compact.py | 336 -- asana/models/goal_membership_response.py | 332 -- asana/models/goal_membership_response_user.py | 168 - .../goal_membership_response_workspace.py | 168 - asana/models/goal_metric_base.py | 410 --- .../goal_metric_current_value_request.py | 168 - asana/models/goal_metric_request.py | 410 --- asana/models/goal_relationship_base.py | 254 -- .../goal_relationship_base_supported_goal.py | 194 - ...l_relationship_base_supporting_resource.py | 168 - asana/models/goal_relationship_compact.py | 228 -- asana/models/goal_relationship_request.py | 254 -- asana/models/goal_relationship_response.py | 254 -- .../goal_relationship_response_array.py | 137 - .../models/goal_relationship_response_data.py | 111 - ...elationships_goal_relationship_gid_body.py | 110 - asana/models/goal_remove_subgoal_request.py | 113 - ..._remove_supporting_relationship_request.py | 113 - asana/models/goal_request.py | 474 --- asana/models/goal_request_base.py | 448 --- asana/models/goal_response.py | 604 ---- asana/models/goal_response_array.py | 137 - .../goal_response_current_status_update.py | 202 -- asana/models/goal_response_data.py | 111 - asana/models/goal_response_likes.py | 138 - asana/models/goal_response_metric.py | 438 --- asana/models/goal_response_team.py | 168 - asana/models/goal_response_time_period.py | 258 -- asana/models/goal_response_workspace.py | 168 - asana/models/goal_update_request.py | 476 --- asana/models/goals_body.py | 110 - asana/models/goals_goal_gid_body.py | 110 - asana/models/inline_response412.py | 138 - asana/models/inline_response412_errors.py | 112 - asana/models/job_base.py | 280 -- asana/models/job_base_new_project.py | 168 - asana/models/job_base_new_project_template.py | 168 - asana/models/job_base_new_task.py | 228 -- asana/models/job_compact.py | 280 -- asana/models/job_response.py | 280 -- asana/models/job_response_data.py | 111 - asana/models/like.py | 138 - asana/models/member_compact.py | 168 - asana/models/membership_compact.py | 84 - asana/models/membership_compact_goal.py | 194 - asana/models/membership_compact_member.py | 168 - asana/models/membership_compact_parent.py | 194 - asana/models/membership_request.py | 112 - asana/models/membership_response.py | 84 - asana/models/membership_response_array.py | 137 - asana/models/membership_response_data.py | 111 - asana/models/memberships_body.py | 110 - asana/models/modify_dependencies_request.py | 112 - asana/models/modify_dependents_request.py | 112 - asana/models/next_page.py | 168 - asana/models/organization_export_base.py | 256 -- asana/models/organization_export_compact.py | 256 -- asana/models/organization_export_request.py | 112 - asana/models/organization_export_response.py | 256 -- .../organization_export_response_data.py | 111 - asana/models/organization_exports_body.py | 110 - asana/models/portfolio_add_item_request.py | 169 - asana/models/portfolio_base.py | 202 -- asana/models/portfolio_compact.py | 168 - ...folio_gid_add_custom_field_setting_body.py | 110 - asana/models/portfolio_gid_add_item_body.py | 110 - .../models/portfolio_gid_add_members_body.py | 110 - ...io_gid_remove_custom_field_setting_body.py | 110 - .../models/portfolio_gid_remove_item_body.py | 110 - .../portfolio_gid_remove_members_body.py | 110 - asana/models/portfolio_membership_base.py | 192 - .../portfolio_membership_base_portfolio.py | 168 - asana/models/portfolio_membership_compact.py | 192 - asana/models/portfolio_membership_response.py | 192 - .../portfolio_membership_response_array.py | 137 - .../portfolio_membership_response_data.py | 111 - asana/models/portfolio_remove_item_request.py | 113 - asana/models/portfolio_request.py | 286 -- asana/models/portfolio_response.py | 556 --- asana/models/portfolio_response_array.py | 137 - ...ortfolio_response_current_status_update.py | 202 -- ...ortfolio_response_custom_field_settings.py | 246 -- .../portfolio_response_custom_fields.py | 484 --- asana/models/portfolio_response_data.py | 111 - asana/models/portfolio_response_workspace.py | 168 - asana/models/portfolios_body.py | 110 - asana/models/portfolios_portfolio_gid_body.py | 110 - asana/models/preview.py | 308 -- asana/models/project_base.py | 698 ---- asana/models/project_base_current_status.py | 366 -- .../project_base_current_status_update.py | 202 -- asana/models/project_base_workspace.py | 168 - asana/models/project_brief_base.py | 196 -- asana/models/project_brief_compact.py | 140 - asana/models/project_brief_request.py | 224 -- asana/models/project_brief_response.py | 278 -- asana/models/project_brief_response_data.py | 111 - .../models/project_brief_response_project.py | 168 - .../project_briefs_project_brief_gid_body.py | 110 - asana/models/project_compact.py | 168 - asana/models/project_duplicate_request.py | 195 - ...roject_duplicate_request_schedule_dates.py | 169 - ...oject_gid_add_custom_field_setting_body.py | 110 - .../models/project_gid_add_followers_body.py | 110 - asana/models/project_gid_add_members_body.py | 110 - asana/models/project_gid_duplicate_body.py | 110 - .../models/project_gid_project_briefs_body.py | 110 - .../project_gid_project_statuses_body.py | 110 - ...ct_gid_remove_custom_field_setting_body.py | 110 - .../project_gid_remove_followers_body.py | 110 - .../models/project_gid_remove_members_body.py | 110 - .../project_gid_save_as_template_body.py | 110 - asana/models/project_gid_sections_body.py | 110 - asana/models/project_membership_base.py | 226 -- asana/models/project_membership_compact.py | 226 -- .../project_membership_compact_array.py | 137 - .../project_membership_compact_response.py | 254 -- ...roject_membership_compact_response_data.py | 111 - .../project_membership_normal_response.py | 312 -- ...project_membership_normal_response_data.py | 111 - asana/models/project_membership_response.py | 286 -- .../project_membership_response_array.py | 137 - .../project_membership_response_data.py | 111 - .../project_membership_response_member.py | 168 - asana/models/project_request.py | 838 ----- asana/models/project_response.py | 1030 ------ asana/models/project_response_array.py | 137 - asana/models/project_response_completed_by.py | 168 - .../project_response_created_from_template.py | 168 - asana/models/project_response_data.py | 111 - .../models/project_response_project_brief.py | 140 - asana/models/project_response_team.py | 168 - asana/models/project_response_workspace.py | 168 - .../project_save_as_template_request.py | 198 -- .../models/project_section_insert_request.py | 169 - asana/models/project_status_base.py | 258 -- asana/models/project_status_compact.py | 168 - asana/models/project_status_request.py | 258 -- asana/models/project_status_response.py | 366 -- asana/models/project_status_response_array.py | 137 - asana/models/project_status_response_data.py | 111 - asana/models/project_template_base.py | 396 --- .../project_template_base_requested_dates.py | 168 - .../project_template_base_requested_roles.py | 168 - asana/models/project_template_base_team.py | 168 - asana/models/project_template_compact.py | 168 - ...t_template_gid_instantiate_project_body.py | 110 - ...ct_template_instantiate_project_request.py | 253 -- ...antiate_project_request_requested_dates.py | 140 - ...antiate_project_request_requested_roles.py | 140 - asana/models/project_template_response.py | 396 --- .../models/project_template_response_array.py | 137 - .../models/project_template_response_data.py | 111 - asana/models/project_update_request.py | 810 ----- asana/models/projects_body.py | 110 - asana/models/projects_project_gid_body.py | 110 - .../remove_custom_field_setting_request.py | 113 - asana/models/remove_followers_request.py | 113 - asana/models/remove_members_request.py | 113 - asana/models/requested_role_request.py | 140 - asana/models/rule_trigger_gid_run_body.py | 110 - asana/models/rule_trigger_request.py | 142 - asana/models/rule_trigger_response.py | 112 - asana/models/rule_trigger_response_data.py | 111 - asana/models/section_base.py | 168 - asana/models/section_compact.py | 168 - asana/models/section_gid_add_task_body.py | 110 - asana/models/section_request.py | 169 - asana/models/section_response.py | 250 -- asana/models/section_response_array.py | 137 - asana/models/section_response_data.py | 111 - asana/models/section_task_insert_request.py | 169 - asana/models/sections_insert_body.py | 110 - asana/models/sections_section_gid_body.py | 110 - asana/models/status_update_base.py | 294 -- asana/models/status_update_compact.py | 202 -- asana/models/status_update_request.py | 323 -- asana/models/status_update_response.py | 596 ---- asana/models/status_update_response_array.py | 137 - asana/models/status_update_response_data.py | 111 - asana/models/status_update_response_parent.py | 168 - asana/models/status_updates_body.py | 110 - asana/models/stories_story_gid_body.py | 110 - asana/models/story_base.py | 314 -- asana/models/story_compact.py | 250 -- asana/models/story_request.py | 314 -- asana/models/story_response.py | 1544 -------- asana/models/story_response_array.py | 137 - asana/models/story_response_assignee.py | 168 - asana/models/story_response_custom_field.py | 484 --- asana/models/story_response_data.py | 111 - asana/models/story_response_dates.py | 168 - asana/models/story_response_old_dates.py | 168 - asana/models/story_response_old_enum_value.py | 224 -- asana/models/story_response_old_section.py | 168 - asana/models/story_response_previews.py | 308 -- asana/models/story_response_project.py | 168 - asana/models/story_response_story.py | 250 -- asana/models/story_response_tag.py | 168 - asana/models/story_response_target.py | 228 -- asana/models/story_response_task.py | 228 -- asana/models/tag_base.py | 230 -- asana/models/tag_compact.py | 168 - .../tag_create_tag_for_workspace_request.py | 258 -- asana/models/tag_request.py | 286 -- asana/models/tag_response.py | 340 -- asana/models/tag_response_array.py | 137 - asana/models/tag_response_data.py | 111 - asana/models/tags_body.py | 110 - asana/models/task_add_followers_request.py | 113 - asana/models/task_add_project_request.py | 197 -- asana/models/task_add_tag_request.py | 113 - asana/models/task_base.py | 964 ----- asana/models/task_base_completed_by.py | 168 - asana/models/task_base_dependencies.py | 140 - asana/models/task_base_external.py | 136 - asana/models/task_base_memberships.py | 136 - asana/models/task_base_section.py | 168 - asana/models/task_compact.py | 228 -- asana/models/task_count_response.py | 252 -- asana/models/task_count_response_data.py | 111 - asana/models/task_duplicate_request.py | 140 - .../models/task_gid_add_dependencies_body.py | 110 - asana/models/task_gid_add_dependents_body.py | 110 - asana/models/task_gid_add_followers_body.py | 110 - asana/models/task_gid_add_project_body.py | 110 - asana/models/task_gid_add_tag_body.py | 110 - asana/models/task_gid_duplicate_body.py | 110 - .../task_gid_remove_dependencies_body.py | 110 - .../models/task_gid_remove_dependents_body.py | 110 - .../models/task_gid_remove_followers_body.py | 110 - asana/models/task_gid_remove_project_body.py | 110 - asana/models/task_gid_remove_tag_body.py | 110 - asana/models/task_gid_set_parent_body.py | 110 - asana/models/task_gid_stories_body.py | 110 - asana/models/task_gid_subtasks_body.py | 110 - .../task_gid_time_tracking_entries_body.py | 110 - asana/models/task_remove_followers_request.py | 113 - asana/models/task_remove_project_request.py | 113 - asana/models/task_remove_tag_request.py | 113 - asana/models/task_request.py | 1188 ------- asana/models/task_response.py | 1208 ------- asana/models/task_response_array.py | 137 - .../models/task_response_assignee_section.py | 168 - asana/models/task_response_custom_fields.py | 836 ----- asana/models/task_response_data.py | 111 - asana/models/task_response_parent.py | 228 -- asana/models/task_response_tags.py | 168 - asana/models/task_response_workspace.py | 168 - asana/models/task_set_parent_request.py | 169 - asana/models/task_template_base.py | 168 - asana/models/task_template_compact.py | 168 - ...task_template_gid_instantiate_task_body.py | 110 - .../task_template_instantiate_task_request.py | 112 - asana/models/task_template_recipe.py | 482 --- .../task_template_recipe_attachments.py | 196 -- asana/models/task_template_recipe_compact.py | 146 - .../task_template_recipe_dependencies.py | 146 - asana/models/task_template_response.py | 280 -- asana/models/task_template_response_array.py | 137 - asana/models/task_template_response_data.py | 111 - asana/models/tasks_body.py | 110 - asana/models/tasks_task_gid_body.py | 110 - asana/models/team_add_user_request.py | 112 - asana/models/team_base.py | 168 - asana/models/team_compact.py | 168 - asana/models/team_gid_add_user_body.py | 110 - asana/models/team_gid_projects_body.py | 110 - asana/models/team_gid_remove_user_body.py | 110 - asana/models/team_membership_base.py | 276 -- asana/models/team_membership_compact.py | 276 -- asana/models/team_membership_response.py | 276 -- .../models/team_membership_response_array.py | 137 - asana/models/team_membership_response_data.py | 111 - asana/models/team_remove_user_request.py | 112 - asana/models/team_request.py | 490 --- asana/models/team_response.py | 516 --- asana/models/team_response_array.py | 137 - asana/models/team_response_data.py | 111 - asana/models/team_response_organization.py | 168 - asana/models/teams_body.py | 110 - asana/models/teams_team_gid_body.py | 110 - asana/models/template_role.py | 168 - asana/models/time_period_base.py | 284 -- asana/models/time_period_compact.py | 258 -- asana/models/time_period_response.py | 284 -- asana/models/time_period_response_array.py | 137 - asana/models/time_period_response_data.py | 111 - ...ng_entries_time_tracking_entry_gid_body.py | 110 - asana/models/time_tracking_entry_base.py | 276 -- asana/models/time_tracking_entry_base_data.py | 111 - asana/models/time_tracking_entry_compact.py | 222 -- .../time_tracking_entry_compact_array.py | 137 - .../update_time_tracking_entry_request.py | 140 - asana/models/user_base.py | 168 - asana/models/user_base_response.py | 222 -- asana/models/user_base_response_data.py | 111 - asana/models/user_base_response_photo.py | 240 -- asana/models/user_compact.py | 168 - asana/models/user_request.py | 168 - asana/models/user_response.py | 250 -- asana/models/user_response_array.py | 137 - asana/models/user_response_data.py | 111 - asana/models/user_task_list_base.py | 224 -- asana/models/user_task_list_compact.py | 224 -- asana/models/user_task_list_request.py | 224 -- asana/models/user_task_list_response.py | 224 -- asana/models/user_task_list_response_data.py | 111 - asana/models/webhook_compact.py | 222 -- asana/models/webhook_compact_resource.py | 168 - asana/models/webhook_filter.py | 196 -- asana/models/webhook_request.py | 170 - asana/models/webhook_request_filters.py | 196 -- asana/models/webhook_response.py | 362 -- asana/models/webhook_response_array.py | 137 - asana/models/webhook_response_data.py | 111 - asana/models/webhook_update_request.py | 112 - asana/models/webhooks_body.py | 110 - asana/models/webhooks_webhook_gid_body.py | 110 - asana/models/workspace_add_user_request.py | 112 - asana/models/workspace_base.py | 168 - asana/models/workspace_compact.py | 168 - asana/models/workspace_gid_add_user_body.py | 110 - asana/models/workspace_gid_projects_body.py | 110 - .../models/workspace_gid_remove_user_body.py | 110 - asana/models/workspace_gid_tags_body.py | 110 - asana/models/workspace_membership_base.py | 192 - asana/models/workspace_membership_compact.py | 192 - asana/models/workspace_membership_request.py | 192 - asana/models/workspace_membership_response.py | 356 -- .../workspace_membership_response_array.py | 137 - .../workspace_membership_response_data.py | 111 - ...pace_membership_response_user_task_list.py | 224 -- ...pace_membership_response_vacation_dates.py | 140 - asana/models/workspace_remove_user_request.py | 112 - asana/models/workspace_request.py | 168 - asana/models/workspace_response.py | 224 -- asana/models/workspace_response_array.py | 137 - asana/models/workspace_response_data.py | 111 - asana/models/workspaces_workspace_gid_body.py | 110 - asana/page_iterator.py | 134 + asana/resources/__init__.py | 35 + asana/resources/attachments.py | 36 + asana/resources/audit_log_api.py | 19 + asana/resources/batch_api.py | 6 + asana/resources/custom_field_settings.py | 26 + asana/resources/custom_fields.py | 140 + asana/resources/events.py | 22 + asana/resources/gen/__init__.py | 32 + asana/resources/gen/attachments.py | 49 + asana/resources/gen/audit_log_api.py | 25 + asana/resources/gen/batch_api.py | 18 + asana/resources/gen/custom_field_settings.py | 37 + asana/resources/gen/custom_fields.py | 122 + asana/resources/gen/events.py | 20 + asana/resources/gen/goal_relationships.py | 76 + asana/resources/gen/goals.py | 153 + asana/resources/gen/jobs.py | 19 + asana/resources/gen/memberships.py | 65 + asana/resources/gen/message.py | 19 + asana/resources/gen/organization_exports.py | 34 + asana/resources/gen/portfolio_memberships.py | 54 + asana/resources/gen/portfolios.py | 175 + asana/resources/gen/project_briefs.py | 61 + asana/resources/gen/project_memberships.py | 36 + asana/resources/gen/project_statuses.py | 63 + asana/resources/gen/project_templates.py | 66 + asana/resources/gen/projects.py | 282 ++ asana/resources/gen/sections.py | 105 + asana/resources/gen/status_updates.py | 65 + asana/resources/gen/stories.py | 79 + asana/resources/gen/tags.py | 128 + asana/resources/gen/tasks.py | 443 +++ asana/resources/gen/team_memberships.py | 70 + asana/resources/gen/teams.py | 112 + asana/resources/gen/time_periods.py | 37 + asana/resources/gen/typeahead.py | 23 + asana/resources/gen/user_task_lists.py | 34 + asana/resources/gen/users.py | 82 + asana/resources/gen/webhooks.py | 77 + asana/resources/gen/workspace_memberships.py | 52 + asana/resources/gen/workspaces.py | 76 + asana/resources/goal_relationships.py | 5 + asana/resources/goals.py | 6 + asana/resources/jobs.py | 15 + asana/resources/memberships.py | 5 + asana/resources/message.py | 6 + asana/resources/organization_exports.py | 30 + asana/resources/portfolio_memberships.py | 42 + asana/resources/portfolios.py | 184 + asana/resources/project_briefs.py | 6 + asana/resources/project_memberships.py | 29 + asana/resources/project_statuses.py | 56 + asana/resources/project_templates.py | 6 + asana/resources/projects.py | 258 ++ asana/resources/sections.py | 119 + asana/resources/status_updates.py | 6 + asana/resources/stories.py | 70 + asana/resources/tags.py | 118 + asana/resources/tasks.py | 472 +++ asana/resources/team_memberships.py | 6 + asana/resources/teams.py | 86 + asana/resources/time_periods.py | 6 + asana/resources/typeahead.py | 6 + asana/resources/user_task_lists.py | 60 + asana/resources/users.py | 68 + asana/resources/webhooks.py | 64 + asana/resources/workspace_memberships.py | 6 + asana/resources/workspaces.py | 97 + asana/rest.py | 317 -- asana/session.py | 20 + asana/version.py | 1 + codegen/swagger/README.md | 74 - codegen/swagger/pom.xml | 129 - .../com/asana/codegen/ExampleUtility.java | 27 - .../codegen/PythonClientCodegenGenerator.java | 69 - .../main/java/com/asana/codegen/ReadMe.java | 164 - .../io.swagger.codegen.v3.CodegenConfig | 1 - codegen/templates/README.mustache | 641 ---- codegen/templates/api.mustache | 236 -- codegen/templates/api_client.mustache | 657 ---- codegen/templates/api_doc.mustache | 52 - codegen/templates/code_sample.mustache | 48 - codegen/templates/code_samples.mustache | 11 - codegen/templates/setup.mustache | 52 - deploy.py | 54 + docs/AddCustomFieldSettingRequest.md | 12 - docs/AddFollowersRequest.md | 9 - docs/AddMembersRequest.md | 9 - docs/AllOfProjectResponseOwner.md | 8 - docs/AllOfProjectTemplateBaseOwner.md | 8 - docs/AllOfProjectTemplateResponseOwner.md | 8 - docs/AllOfStoryResponseNewDateValue.md | 8 - docs/AllOfStoryResponseOldDateValue.md | 8 - docs/AllOfTaskTemplateResponseCreatedBy.md | 8 - docs/AllOfTaskTemplateResponseProject.md | 8 - docs/AllOfTaskTemplateResponseTemplate.md | 8 - docs/AllOfUserTaskListBaseOwner.md | 8 - docs/AllOfUserTaskListBaseWorkspace.md | 8 - docs/AllOfUserTaskListCompactOwner.md | 8 - docs/AllOfUserTaskListCompactWorkspace.md | 8 - docs/AllOfUserTaskListRequestOwner.md | 8 - docs/AllOfUserTaskListRequestWorkspace.md | 8 - docs/AllOfUserTaskListResponseOwner.md | 8 - docs/AllOfUserTaskListResponseWorkspace.md | 8 - ...paceMembershipResponseUserTaskListOwner.md | 8 - ...MembershipResponseUserTaskListWorkspace.md | 8 - docs/AsanaNamedResource.md | 11 - docs/AsanaNamedResourceArray.md | 10 - docs/AsanaResource.md | 10 - docs/AttachmentBase.md | 12 - docs/AttachmentCompact.md | 12 - docs/AttachmentRequest.md | 14 - docs/AttachmentResponse.md | 20 - docs/AttachmentResponseArray.md | 10 - docs/AttachmentResponseData.md | 9 - docs/AttachmentResponseParent.md | 13 - docs/AttachmentResponseParentCreatedBy.md | 10 - docs/AttachmentsApi.md | 235 -- docs/AttachmentsApi.yaml | 91 - docs/AuditLogAPIApi.md | 75 - docs/AuditLogAPIApi.yaml | 29 - docs/AuditLogEvent.md | 16 - docs/AuditLogEventActor.md | 12 - docs/AuditLogEventArray.md | 10 - docs/AuditLogEventContext.md | 13 - docs/AuditLogEventDetails.md | 8 - docs/AuditLogEventResource.md | 13 - docs/BatchAPIApi.md | 61 - docs/BatchAPIApi.yaml | 22 - docs/BatchBody.md | 9 - docs/BatchRequest.md | 9 - docs/BatchRequestAction.md | 12 - docs/BatchRequestActions.md | 12 - docs/BatchRequestOptions.md | 11 - docs/BatchResponse.md | 11 - docs/BatchResponseArray.md | 10 - docs/CreateMembershipRequest.md | 11 - docs/CreateTimeTrackingEntryRequest.md | 10 - docs/CustomFieldBase.md | 31 - docs/CustomFieldBaseDateValue.md | 10 - docs/CustomFieldBaseEnumOptions.md | 13 - docs/CustomFieldBaseEnumValue.md | 13 - docs/CustomFieldCompact.md | 22 - docs/CustomFieldGidEnumOptionsBody.md | 9 - docs/CustomFieldRequest.md | 34 - docs/CustomFieldResponse.md | 34 - docs/CustomFieldResponseArray.md | 10 - docs/CustomFieldResponseCreatedBy.md | 11 - docs/CustomFieldResponseData.md | 9 - docs/CustomFieldResponsePeopleValue.md | 11 - docs/CustomFieldSettingBase.md | 10 - docs/CustomFieldSettingCompact.md | 10 - docs/CustomFieldSettingResponse.md | 14 - docs/CustomFieldSettingResponseArray.md | 10 - docs/CustomFieldSettingResponseCustomField.md | 34 - docs/CustomFieldSettingResponseData.md | 9 - docs/CustomFieldSettingResponseParent.md | 11 - docs/CustomFieldSettingResponseProject.md | 11 - docs/CustomFieldSettingsApi.md | 123 - docs/CustomFieldSettingsApi.yaml | 47 - docs/CustomFieldsApi.md | 449 --- docs/CustomFieldsApi.yaml | 174 - docs/CustomFieldsBody.md | 9 - docs/CustomFieldsCustomFieldGidBody.md | 9 - docs/DateVariableCompact.md | 11 - docs/DateVariableRequest.md | 10 - docs/EmptyResponse.md | 8 - docs/EmptyResponseData.md | 9 - docs/EnumOption.md | 13 - docs/EnumOptionBase.md | 13 - docs/EnumOptionData.md | 9 - docs/EnumOptionInsertRequest.md | 11 - docs/EnumOptionRequest.md | 15 - docs/EnumOptionsEnumOptionGidBody.md | 9 - docs/EnumOptionsInsertBody.md | 9 - docs/Error.md | 11 - docs/ErrorResponse.md | 9 - docs/ErrorResponseErrors.md | 11 - docs/EventResponse.md | 15 - docs/EventResponseArray.md | 10 - docs/EventResponseChange.md | 13 - docs/EventResponseParent.md | 11 - docs/EventResponseResource.md | 11 - docs/EventResponseUser.md | 11 - docs/EventsApi.md | 63 - docs/EventsApi.yaml | 23 - docs/GoalAddSubgoalRequest.md | 11 - docs/GoalAddSupportingRelationshipRequest.md | 12 - docs/GoalAddSupportingWorkRequest.md | 9 - docs/GoalBase.md | 17 - docs/GoalCompact.md | 12 - docs/GoalGidAddFollowersBody.md | 9 - docs/GoalGidAddSupportingRelationshipBody.md | 9 - docs/GoalGidRemoveFollowersBody.md | 9 - ...GoalGidRemoveSupportingRelationshipBody.md | 9 - docs/GoalGidSetMetricBody.md | 9 - docs/GoalGidSetMetricCurrentValueBody.md | 9 - docs/GoalMembershipBase.md | 15 - docs/GoalMembershipBaseGoal.md | 12 - docs/GoalMembershipCompact.md | 17 - docs/GoalMembershipResponse.md | 17 - docs/GoalMembershipResponseUser.md | 11 - docs/GoalMembershipResponseWorkspace.md | 11 - docs/GoalMetricBase.md | 19 - docs/GoalMetricCurrentValueRequest.md | 11 - docs/GoalMetricRequest.md | 19 - docs/GoalRelationshipBase.md | 14 - docs/GoalRelationshipBaseSupportedGoal.md | 12 - .../GoalRelationshipBaseSupportingResource.md | 11 - docs/GoalRelationshipCompact.md | 13 - docs/GoalRelationshipRequest.md | 14 - docs/GoalRelationshipResponse.md | 14 - docs/GoalRelationshipResponseArray.md | 10 - docs/GoalRelationshipResponseData.md | 9 - docs/GoalRelationshipsApi.md | 287 -- docs/GoalRelationshipsApi.yaml | 111 - ...oalRelationshipsGoalRelationshipGidBody.md | 9 - docs/GoalRemoveSubgoalRequest.md | 9 - ...GoalRemoveSupportingRelationshipRequest.md | 9 - docs/GoalRequest.md | 22 - docs/GoalRequestBase.md | 21 - docs/GoalResponse.md | 27 - docs/GoalResponseArray.md | 10 - docs/GoalResponseCurrentStatusUpdate.md | 12 - docs/GoalResponseData.md | 9 - docs/GoalResponseLikes.md | 10 - docs/GoalResponseMetric.md | 20 - docs/GoalResponseTeam.md | 11 - docs/GoalResponseTimePeriod.md | 14 - docs/GoalResponseWorkspace.md | 11 - docs/GoalUpdateRequest.md | 22 - docs/GoalsApi.md | 569 --- docs/GoalsApi.yaml | 222 -- docs/GoalsBody.md | 9 - docs/GoalsGoalGidBody.md | 9 - docs/InlineResponse412.md | 10 - docs/InlineResponse412Errors.md | 9 - docs/JobBase.md | 15 - docs/JobBaseNewProject.md | 11 - docs/JobBaseNewProjectTemplate.md | 11 - docs/JobBaseNewTask.md | 13 - docs/JobCompact.md | 15 - docs/JobResponse.md | 15 - docs/JobResponseData.md | 9 - docs/JobsApi.md | 61 - docs/JobsApi.yaml | 22 - docs/Like.md | 10 - docs/MemberCompact.md | 11 - docs/MembershipCompact.md | 8 - docs/MembershipCompactGoal.md | 12 - docs/MembershipCompactMember.md | 11 - docs/MembershipCompactParent.md | 12 - docs/MembershipRequest.md | 9 - docs/MembershipResponse.md | 8 - docs/MembershipResponseArray.md | 10 - docs/MembershipResponseData.md | 9 - docs/MembershipsApi.md | 225 -- docs/MembershipsApi.yaml | 86 - docs/MembershipsBody.md | 9 - docs/ModifyDependenciesRequest.md | 9 - docs/ModifyDependentsRequest.md | 9 - docs/NextPage.md | 11 - docs/OrganizationExportBase.md | 14 - docs/OrganizationExportCompact.md | 14 - docs/OrganizationExportRequest.md | 9 - docs/OrganizationExportResponse.md | 14 - docs/OrganizationExportResponseData.md | 9 - docs/OrganizationExportsApi.md | 115 - docs/OrganizationExportsApi.yaml | 43 - docs/OrganizationExportsBody.md | 9 - docs/PortfolioAddItemRequest.md | 11 - docs/PortfolioBase.md | 12 - docs/PortfolioCompact.md | 11 - docs/PortfolioGidAddCustomFieldSettingBody.md | 9 - docs/PortfolioGidAddItemBody.md | 9 - docs/PortfolioGidAddMembersBody.md | 9 - ...ortfolioGidRemoveCustomFieldSettingBody.md | 9 - docs/PortfolioGidRemoveItemBody.md | 9 - docs/PortfolioGidRemoveMembersBody.md | 9 - docs/PortfolioMembershipBase.md | 12 - docs/PortfolioMembershipBasePortfolio.md | 11 - docs/PortfolioMembershipCompact.md | 12 - docs/PortfolioMembershipResponse.md | 12 - docs/PortfolioMembershipResponseArray.md | 10 - docs/PortfolioMembershipResponseData.md | 9 - docs/PortfolioMembershipsApi.md | 183 - docs/PortfolioMembershipsApi.yaml | 71 - docs/PortfolioRemoveItemRequest.md | 9 - docs/PortfolioRequest.md | 15 - docs/PortfolioResponse.md | 25 - docs/PortfolioResponseArray.md | 10 - docs/PortfolioResponseCurrentStatusUpdate.md | 12 - docs/PortfolioResponseCustomFieldSettings.md | 14 - docs/PortfolioResponseCustomFields.md | 22 - docs/PortfolioResponseData.md | 9 - docs/PortfolioResponseWorkspace.md | 11 - docs/PortfoliosApi.md | 669 ---- docs/PortfoliosApi.yaml | 260 -- docs/PortfoliosBody.md | 9 - docs/PortfoliosPortfolioGidBody.md | 9 - docs/Preview.md | 16 - docs/ProjectBase.md | 29 - docs/ProjectBaseCurrentStatus.md | 18 - docs/ProjectBaseCurrentStatusUpdate.md | 12 - docs/ProjectBaseWorkspace.md | 11 - docs/ProjectBriefBase.md | 12 - docs/ProjectBriefCompact.md | 10 - docs/ProjectBriefRequest.md | 13 - docs/ProjectBriefResponse.md | 15 - docs/ProjectBriefResponseData.md | 9 - docs/ProjectBriefResponseProject.md | 11 - docs/ProjectBriefsApi.md | 225 -- docs/ProjectBriefsApi.yaml | 86 - docs/ProjectBriefsProjectBriefGidBody.md | 9 - docs/ProjectCompact.md | 11 - docs/ProjectDuplicateRequest.md | 12 - docs/ProjectDuplicateRequestScheduleDates.md | 11 - docs/ProjectGidAddCustomFieldSettingBody.md | 9 - docs/ProjectGidAddFollowersBody.md | 9 - docs/ProjectGidAddMembersBody.md | 9 - docs/ProjectGidDuplicateBody.md | 9 - docs/ProjectGidProjectBriefsBody.md | 9 - docs/ProjectGidProjectStatusesBody.md | 9 - .../ProjectGidRemoveCustomFieldSettingBody.md | 9 - docs/ProjectGidRemoveFollowersBody.md | 9 - docs/ProjectGidRemoveMembersBody.md | 9 - docs/ProjectGidSaveAsTemplateBody.md | 9 - docs/ProjectGidSectionsBody.md | 9 - docs/ProjectMembershipBase.md | 13 - docs/ProjectMembershipCompact.md | 13 - docs/ProjectMembershipCompactArray.md | 10 - docs/ProjectMembershipCompactResponse.md | 14 - docs/ProjectMembershipCompactResponseData.md | 9 - docs/ProjectMembershipNormalResponse.md | 16 - docs/ProjectMembershipNormalResponseData.md | 9 - docs/ProjectMembershipResponse.md | 15 - docs/ProjectMembershipResponseArray.md | 10 - docs/ProjectMembershipResponseData.md | 9 - docs/ProjectMembershipResponseMember.md | 11 - docs/ProjectMembershipsApi.md | 121 - docs/ProjectMembershipsApi.yaml | 46 - docs/ProjectRequest.md | 34 - docs/ProjectResponse.md | 41 - docs/ProjectResponseArray.md | 10 - docs/ProjectResponseCompletedBy.md | 11 - docs/ProjectResponseCreatedFromTemplate.md | 11 - docs/ProjectResponseData.md | 9 - docs/ProjectResponseProjectBrief.md | 10 - docs/ProjectResponseTeam.md | 11 - docs/ProjectResponseWorkspace.md | 11 - docs/ProjectSaveAsTemplateRequest.md | 12 - docs/ProjectSectionInsertRequest.md | 11 - docs/ProjectStatusBase.md | 14 - docs/ProjectStatusCompact.md | 11 - docs/ProjectStatusRequest.md | 14 - docs/ProjectStatusResponse.md | 18 - docs/ProjectStatusResponseArray.md | 10 - docs/ProjectStatusResponseData.md | 9 - docs/ProjectStatusesApi.md | 227 -- docs/ProjectStatusesApi.yaml | 87 - docs/ProjectTemplateBase.md | 19 - docs/ProjectTemplateBaseRequestedDates.md | 11 - docs/ProjectTemplateBaseRequestedRoles.md | 11 - docs/ProjectTemplateBaseTeam.md | 11 - docs/ProjectTemplateCompact.md | 11 - ...rojectTemplateGidInstantiateProjectBody.md | 9 - ...rojectTemplateInstantiateProjectRequest.md | 14 - ...InstantiateProjectRequestRequestedDates.md | 10 - ...InstantiateProjectRequestRequestedRoles.md | 10 - docs/ProjectTemplateResponse.md | 19 - docs/ProjectTemplateResponseArray.md | 10 - docs/ProjectTemplateResponseData.md | 9 - docs/ProjectTemplatesApi.md | 287 -- docs/ProjectTemplatesApi.yaml | 111 - docs/ProjectUpdateRequest.md | 33 - docs/ProjectsApi.md | 1073 ------ docs/ProjectsApi.yaml | 420 --- docs/ProjectsBody.md | 9 - docs/ProjectsProjectGidBody.md | 9 - docs/RemoveCustomFieldSettingRequest.md | 9 - docs/RemoveFollowersRequest.md | 9 - docs/RemoveMembersRequest.md | 9 - docs/RequestedRoleRequest.md | 10 - docs/RuleTriggerGidRunBody.md | 9 - docs/RuleTriggerRequest.md | 10 - docs/RuleTriggerResponse.md | 9 - docs/RuleTriggerResponseData.md | 9 - docs/RulesApi.md | 61 - docs/RulesApi.yaml | 22 - docs/SectionBase.md | 11 - docs/SectionCompact.md | 11 - docs/SectionGidAddTaskBody.md | 9 - docs/SectionRequest.md | 11 - docs/SectionResponse.md | 14 - docs/SectionResponseArray.md | 10 - docs/SectionResponseData.md | 9 - docs/SectionTaskInsertRequest.md | 11 - docs/SectionsApi.md | 391 --- docs/SectionsApi.yaml | 151 - docs/SectionsInsertBody.md | 9 - docs/SectionsSectionGidBody.md | 9 - docs/StatusUpdateBase.md | 15 - docs/StatusUpdateCompact.md | 12 - docs/StatusUpdateRequest.md | 16 - docs/StatusUpdateResponse.md | 26 - docs/StatusUpdateResponseArray.md | 10 - docs/StatusUpdateResponseData.md | 9 - docs/StatusUpdateResponseParent.md | 11 - docs/StatusUpdatesApi.md | 231 -- docs/StatusUpdatesApi.yaml | 89 - docs/StatusUpdatesBody.md | 9 - docs/StoriesApi.md | 283 -- docs/StoriesApi.yaml | 109 - docs/StoriesStoryGidBody.md | 9 - docs/StoryBase.md | 16 - docs/StoryCompact.md | 14 - docs/StoryRequest.md | 16 - docs/StoryResponse.md | 61 - docs/StoryResponseArray.md | 10 - docs/StoryResponseAssignee.md | 11 - docs/StoryResponseCustomField.md | 22 - docs/StoryResponseData.md | 9 - docs/StoryResponseDates.md | 11 - docs/StoryResponseOldDates.md | 11 - docs/StoryResponseOldEnumValue.md | 13 - docs/StoryResponseOldSection.md | 11 - docs/StoryResponsePreviews.md | 16 - docs/StoryResponseProject.md | 11 - docs/StoryResponseStory.md | 14 - docs/StoryResponseTag.md | 11 - docs/StoryResponseTarget.md | 13 - docs/StoryResponseTask.md | 13 - docs/TagBase.md | 13 - docs/TagCompact.md | 11 - docs/TagCreateTagForWorkspaceRequest.md | 14 - docs/TagRequest.md | 15 - docs/TagResponse.md | 17 - docs/TagResponseArray.md | 10 - docs/TagResponseData.md | 9 - docs/TagsApi.md | 451 --- docs/TagsApi.yaml | 175 - docs/TagsBody.md | 9 - docs/TaskAddFollowersRequest.md | 9 - docs/TaskAddProjectRequest.md | 12 - docs/TaskAddTagRequest.md | 9 - docs/TaskBase.md | 39 - docs/TaskBaseCompletedBy.md | 11 - docs/TaskBaseDependencies.md | 10 - docs/TaskBaseExternal.md | 10 - docs/TaskBaseMemberships.md | 10 - docs/TaskBaseSection.md | 11 - docs/TaskCompact.md | 13 - docs/TaskCountResponse.md | 14 - docs/TaskCountResponseData.md | 9 - docs/TaskDuplicateRequest.md | 10 - docs/TaskGidAddDependenciesBody.md | 9 - docs/TaskGidAddDependentsBody.md | 9 - docs/TaskGidAddFollowersBody.md | 9 - docs/TaskGidAddProjectBody.md | 9 - docs/TaskGidAddTagBody.md | 9 - docs/TaskGidDuplicateBody.md | 9 - docs/TaskGidRemoveDependenciesBody.md | 9 - docs/TaskGidRemoveDependentsBody.md | 9 - docs/TaskGidRemoveFollowersBody.md | 9 - docs/TaskGidRemoveProjectBody.md | 9 - docs/TaskGidRemoveTagBody.md | 9 - docs/TaskGidSetParentBody.md | 9 - docs/TaskGidStoriesBody.md | 9 - docs/TaskGidSubtasksBody.md | 9 - docs/TaskGidTimeTrackingEntriesBody.md | 9 - docs/TaskRemoveFollowersRequest.md | 9 - docs/TaskRemoveProjectRequest.md | 9 - docs/TaskRemoveTagRequest.md | 9 - docs/TaskRequest.md | 47 - docs/TaskResponse.md | 48 - docs/TaskResponseArray.md | 10 - docs/TaskResponseAssigneeSection.md | 11 - docs/TaskResponseCustomFields.md | 34 - docs/TaskResponseData.md | 9 - docs/TaskResponseParent.md | 13 - docs/TaskResponseTags.md | 11 - docs/TaskResponseWorkspace.md | 11 - docs/TaskSetParentRequest.md | 11 - docs/TaskTemplateBase.md | 11 - docs/TaskTemplateCompact.md | 11 - docs/TaskTemplateGidInstantiateTaskBody.md | 9 - docs/TaskTemplateInstantiateTaskRequest.md | 9 - docs/TaskTemplateRecipe.md | 22 - docs/TaskTemplateRecipeAttachments.md | 12 - docs/TaskTemplateRecipeCompact.md | 10 - docs/TaskTemplateRecipeDependencies.md | 10 - docs/TaskTemplateResponse.md | 15 - docs/TaskTemplateResponseArray.md | 10 - docs/TaskTemplateResponseData.md | 9 - docs/TaskTemplatesApi.md | 175 - docs/TaskTemplatesApi.yaml | 67 - docs/TasksApi.md | 1580 --------- docs/TasksApi.yaml | 635 ---- docs/TasksBody.md | 9 - docs/TasksTaskGidBody.md | 9 - docs/TeamAddUserRequest.md | 9 - docs/TeamBase.md | 11 - docs/TeamCompact.md | 11 - docs/TeamGidAddUserBody.md | 9 - docs/TeamGidProjectsBody.md | 9 - docs/TeamGidRemoveUserBody.md | 9 - docs/TeamMembershipBase.md | 15 - docs/TeamMembershipCompact.md | 15 - docs/TeamMembershipResponse.md | 15 - docs/TeamMembershipResponseArray.md | 10 - docs/TeamMembershipResponseData.md | 9 - docs/TeamMembershipsApi.md | 241 -- docs/TeamMembershipsApi.yaml | 94 - docs/TeamRemoveUserRequest.md | 9 - docs/TeamRequest.md | 21 - docs/TeamResponse.md | 22 - docs/TeamResponseArray.md | 10 - docs/TeamResponseData.md | 9 - docs/TeamResponseOrganization.md | 11 - docs/TeamsApi.md | 399 --- docs/TeamsApi.yaml | 155 - docs/TeamsBody.md | 9 - docs/TeamsTeamGidBody.md | 9 - docs/TemplateRole.md | 11 - docs/TimePeriodBase.md | 15 - docs/TimePeriodCompact.md | 14 - docs/TimePeriodResponse.md | 15 - docs/TimePeriodResponseArray.md | 10 - docs/TimePeriodResponseData.md | 9 - docs/TimePeriodsApi.md | 123 - docs/TimePeriodsApi.yaml | 47 - docs/TimeTrackingEntriesApi.md | 283 -- docs/TimeTrackingEntriesApi.yaml | 109 - ...TrackingEntriesTimeTrackingEntryGidBody.md | 9 - docs/TimeTrackingEntryBase.md | 15 - docs/TimeTrackingEntryBaseData.md | 9 - docs/TimeTrackingEntryCompact.md | 13 - docs/TimeTrackingEntryCompactArray.md | 10 - docs/TypeaheadApi.md | 69 - docs/TypeaheadApi.yaml | 26 - docs/UpdateTimeTrackingEntryRequest.md | 10 - docs/UserBase.md | 11 - docs/UserBaseResponse.md | 13 - docs/UserBaseResponseData.md | 9 - docs/UserBaseResponsePhoto.md | 14 - docs/UserCompact.md | 11 - docs/UserRequest.md | 11 - docs/UserResponse.md | 14 - docs/UserResponseArray.md | 10 - docs/UserResponseData.md | 9 - docs/UserTaskListBase.md | 13 - docs/UserTaskListCompact.md | 13 - docs/UserTaskListRequest.md | 13 - docs/UserTaskListResponse.md | 13 - docs/UserTaskListResponseData.md | 9 - docs/UserTaskListsApi.md | 117 - docs/UserTaskListsApi.yaml | 44 - docs/UsersApi.md | 295 -- docs/UsersApi.yaml | 115 - docs/WebhookCompact.md | 13 - docs/WebhookCompactResource.md | 11 - docs/WebhookFilter.md | 12 - docs/WebhookRequest.md | 11 - docs/WebhookRequestFilters.md | 12 - docs/WebhookResponse.md | 18 - docs/WebhookResponseArray.md | 10 - docs/WebhookResponseData.md | 9 - docs/WebhookUpdateRequest.md | 9 - docs/WebhooksApi.md | 283 -- docs/WebhooksApi.yaml | 109 - docs/WebhooksBody.md | 9 - docs/WebhooksWebhookGidBody.md | 9 - docs/WorkspaceAddUserRequest.md | 9 - docs/WorkspaceBase.md | 11 - docs/WorkspaceCompact.md | 11 - docs/WorkspaceGidAddUserBody.md | 9 - docs/WorkspaceGidProjectsBody.md | 9 - docs/WorkspaceGidRemoveUserBody.md | 9 - docs/WorkspaceGidTagsBody.md | 9 - docs/WorkspaceMembershipBase.md | 12 - docs/WorkspaceMembershipCompact.md | 12 - docs/WorkspaceMembershipRequest.md | 12 - docs/WorkspaceMembershipResponse.md | 18 - docs/WorkspaceMembershipResponseArray.md | 10 - docs/WorkspaceMembershipResponseData.md | 9 - ...WorkspaceMembershipResponseUserTaskList.md | 13 - ...orkspaceMembershipResponseVacationDates.md | 10 - docs/WorkspaceMembershipsApi.md | 179 - docs/WorkspaceMembershipsApi.yaml | 69 - docs/WorkspaceRemoveUserRequest.md | 9 - docs/WorkspaceRequest.md | 11 - docs/WorkspaceResponse.md | 13 - docs/WorkspaceResponseArray.md | 10 - docs/WorkspaceResponseData.md | 9 - docs/WorkspacesApi.md | 283 -- docs/WorkspacesApi.yaml | 109 - docs/WorkspacesWorkspaceGidBody.md | 9 - examples/example-create-task.py | 46 + examples/example-script.py | 85 + examples/example-server.py | 77 + examples/example-summary-task.py | 106 + git_push.sh | 52 - requirements.txt | 9 +- samples/attachments_sample.yaml | 33 + samples/audit_log_api_sample.yaml | 9 + samples/batch_api_sample.yaml | 9 + samples/custom_field_settings_sample.yaml | 17 + samples/custom_fields_sample.yaml | 65 + samples/events_sample.yaml | 9 + samples/goal_relationships_sample.yaml | 41 + samples/goals_sample.yaml | 81 + samples/jobs_sample.yaml | 9 + samples/memberships_sample.yaml | 33 + samples/message_sample.yaml | 9 + samples/organization_exports_sample.yaml | 17 + samples/portfolio_memberships_sample.yaml | 25 + samples/portfolios_sample.yaml | 97 + samples/project_briefs_sample.yaml | 33 + samples/project_memberships_sample.yaml | 17 + samples/project_statuses_sample.yaml | 33 + samples/project_templates_sample.yaml | 33 + samples/projects_sample.yaml | 153 + samples/sections_sample.yaml | 57 + samples/status_updates_sample.yaml | 33 + samples/stories_sample.yaml | 41 + samples/tags_sample.yaml | 65 + samples/tasks_sample.yaml | 209 ++ samples/team_memberships_sample.yaml | 33 + samples/teams_sample.yaml | 57 + samples/time_periods_sample.yaml | 17 + samples/typeahead_sample.yaml | 9 + samples/user_task_lists_sample.yaml | 17 + samples/users_sample.yaml | 41 + samples/webhooks_sample.yaml | 41 + samples/workspace_memberships_sample.yaml | 25 + samples/workspaces_sample.yaml | 41 + setup.cfg | 5 + setup.py | 72 +- swagger_templates/api.mustache | 27 + swagger_templates/api_doc.mustache | 10 + swagger_templates/python-config.json | 6 + test-requirements.txt | 5 - test/__init__.py | 1 - test/test_add_custom_field_setting_request.py | 39 - test/test_add_followers_request.py | 39 - test/test_add_members_request.py | 39 - test/test_all_of_project_response_owner.py | 39 - ...test_all_of_project_template_base_owner.py | 39 - ..._all_of_project_template_response_owner.py | 39 - ...st_all_of_story_response_new_date_value.py | 39 - ...st_all_of_story_response_old_date_value.py | 39 - ...ll_of_task_template_response_created_by.py | 39 - ...t_all_of_task_template_response_project.py | 39 - ..._all_of_task_template_response_template.py | 39 - test/test_all_of_user_task_list_base_owner.py | 39 - ...st_all_of_user_task_list_base_workspace.py | 39 - ...est_all_of_user_task_list_compact_owner.py | 39 - ...all_of_user_task_list_compact_workspace.py | 39 - ...est_all_of_user_task_list_request_owner.py | 39 - ...all_of_user_task_list_request_workspace.py | 39 - ...st_all_of_user_task_list_response_owner.py | 39 - ...ll_of_user_task_list_response_workspace.py | 39 - ...embership_response_user_task_list_owner.py | 39 - ...rship_response_user_task_list_workspace.py | 39 - test/test_asana_named_resource.py | 39 - test/test_asana_named_resource_array.py | 39 - test/test_asana_resource.py | 39 - test/test_attachment_base.py | 39 - test/test_attachment_compact.py | 39 - test/test_attachment_request.py | 39 - test/test_attachment_response.py | 39 - test/test_attachment_response_array.py | 39 - test/test_attachment_response_data.py | 39 - test/test_attachment_response_parent.py | 39 - ...t_attachment_response_parent_created_by.py | 39 - test/test_attachments_api.py | 61 - test/test_audit_log_api_api.py | 40 - test/test_audit_log_event.py | 39 - test/test_audit_log_event_actor.py | 39 - test/test_audit_log_event_array.py | 39 - test/test_audit_log_event_context.py | 39 - test/test_audit_log_event_details.py | 39 - test/test_audit_log_event_resource.py | 39 - test/test_batch_api_api.py | 40 - test/test_batch_body.py | 39 - test/test_batch_request.py | 39 - test/test_batch_request_action.py | 39 - test/test_batch_request_actions.py | 39 - test/test_batch_request_options.py | 39 - test/test_batch_response.py | 39 - test/test_batch_response_array.py | 39 - test/test_create_membership_request.py | 39 - ...test_create_time_tracking_entry_request.py | 39 - test/test_custom_field_base.py | 39 - test/test_custom_field_base_date_value.py | 39 - test/test_custom_field_base_enum_options.py | 39 - test/test_custom_field_base_enum_value.py | 39 - test/test_custom_field_compact.py | 39 - ...test_custom_field_gid_enum_options_body.py | 39 - test/test_custom_field_request.py | 39 - test/test_custom_field_response.py | 39 - test/test_custom_field_response_array.py | 39 - test/test_custom_field_response_created_by.py | 39 - test/test_custom_field_response_data.py | 39 - ...test_custom_field_response_people_value.py | 39 - test/test_custom_field_setting_base.py | 39 - test/test_custom_field_setting_compact.py | 39 - test/test_custom_field_setting_response.py | 39 - ...est_custom_field_setting_response_array.py | 39 - ...tom_field_setting_response_custom_field.py | 39 - ...test_custom_field_setting_response_data.py | 39 - ...st_custom_field_setting_response_parent.py | 39 - ...t_custom_field_setting_response_project.py | 39 - test/test_custom_field_settings_api.py | 47 - test/test_custom_fields_api.py | 89 - test/test_custom_fields_body.py | 39 - ...est_custom_fields_custom_field_gid_body.py | 39 - test/test_date_variable_compact.py | 39 - test/test_date_variable_request.py | 39 - test/test_empty_response.py | 39 - test/test_empty_response_data.py | 39 - test/test_enum_option.py | 39 - test/test_enum_option_base.py | 39 - test/test_enum_option_data.py | 39 - test/test_enum_option_insert_request.py | 39 - test/test_enum_option_request.py | 39 - .../test_enum_options_enum_option_gid_body.py | 39 - test/test_enum_options_insert_body.py | 39 - test/test_error.py | 39 - test/test_error_response.py | 39 - test/test_error_response_errors.py | 39 - test/test_event_response.py | 39 - test/test_event_response_array.py | 39 - test/test_event_response_change.py | 39 - test/test_event_response_parent.py | 39 - test/test_event_response_resource.py | 39 - test/test_event_response_user.py | 39 - test/test_events_api.py | 40 - test/test_goal_add_subgoal_request.py | 39 - ...oal_add_supporting_relationship_request.py | 39 - test/test_goal_add_supporting_work_request.py | 39 - test/test_goal_base.py | 39 - test/test_goal_compact.py | 39 - test/test_goal_gid_add_followers_body.py | 39 - ...al_gid_add_supporting_relationship_body.py | 39 - test/test_goal_gid_remove_followers_body.py | 39 - ...gid_remove_supporting_relationship_body.py | 39 - test/test_goal_gid_set_metric_body.py | 39 - ..._goal_gid_set_metric_current_value_body.py | 39 - test/test_goal_membership_base.py | 39 - test/test_goal_membership_base_goal.py | 39 - test/test_goal_membership_compact.py | 39 - test/test_goal_membership_response.py | 39 - test/test_goal_membership_response_user.py | 39 - ...test_goal_membership_response_workspace.py | 39 - test/test_goal_metric_base.py | 39 - .../test_goal_metric_current_value_request.py | 39 - test/test_goal_metric_request.py | 39 - test/test_goal_relationship_base.py | 39 - ...t_goal_relationship_base_supported_goal.py | 39 - ...l_relationship_base_supporting_resource.py | 39 - test/test_goal_relationship_compact.py | 39 - test/test_goal_relationship_request.py | 39 - test/test_goal_relationship_response.py | 39 - test/test_goal_relationship_response_array.py | 39 - test/test_goal_relationship_response_data.py | 39 - test/test_goal_relationships_api.py | 68 - ...elationships_goal_relationship_gid_body.py | 39 - test/test_goal_remove_subgoal_request.py | 39 - ..._remove_supporting_relationship_request.py | 39 - test/test_goal_request.py | 39 - test/test_goal_request_base.py | 39 - test/test_goal_response.py | 39 - test/test_goal_response_array.py | 39 - ...est_goal_response_current_status_update.py | 39 - test/test_goal_response_data.py | 39 - test/test_goal_response_likes.py | 39 - test/test_goal_response_metric.py | 39 - test/test_goal_response_team.py | 39 - test/test_goal_response_time_period.py | 39 - test/test_goal_response_workspace.py | 39 - test/test_goal_update_request.py | 39 - test/test_goals_api.py | 103 - test/test_goals_body.py | 39 - test/test_goals_goal_gid_body.py | 39 - test/test_inline_response412.py | 39 - test/test_inline_response412_errors.py | 39 - test/test_job_base.py | 39 - test/test_job_base_new_project.py | 39 - test/test_job_base_new_project_template.py | 39 - test/test_job_base_new_task.py | 39 - test/test_job_compact.py | 39 - test/test_job_response.py | 39 - test/test_job_response_data.py | 39 - test/test_jobs_api.py | 40 - test/test_like.py | 39 - test/test_member_compact.py | 39 - test/test_membership_compact.py | 39 - test/test_membership_compact_goal.py | 39 - test/test_membership_compact_member.py | 39 - test/test_membership_compact_parent.py | 39 - test/test_membership_request.py | 39 - test/test_membership_response.py | 39 - test/test_membership_response_array.py | 39 - test/test_membership_response_data.py | 39 - test/test_memberships_api.py | 54 - test/test_memberships_body.py | 39 - test/test_modify_dependencies_request.py | 39 - test/test_modify_dependents_request.py | 39 - test/test_next_page.py | 39 - test/test_organization_export_base.py | 39 - test/test_organization_export_compact.py | 39 - test/test_organization_export_request.py | 39 - test/test_organization_export_response.py | 39 - .../test_organization_export_response_data.py | 39 - test/test_organization_exports_api.py | 47 - test/test_organization_exports_body.py | 39 - test/test_portfolio_add_item_request.py | 39 - test/test_portfolio_base.py | 39 - test/test_portfolio_compact.py | 39 - ...folio_gid_add_custom_field_setting_body.py | 39 - test/test_portfolio_gid_add_item_body.py | 39 - test/test_portfolio_gid_add_members_body.py | 39 - ...io_gid_remove_custom_field_setting_body.py | 39 - test/test_portfolio_gid_remove_item_body.py | 39 - .../test_portfolio_gid_remove_members_body.py | 39 - test/test_portfolio_membership_base.py | 39 - ...est_portfolio_membership_base_portfolio.py | 39 - test/test_portfolio_membership_compact.py | 39 - test/test_portfolio_membership_response.py | 39 - ...est_portfolio_membership_response_array.py | 39 - ...test_portfolio_membership_response_data.py | 39 - test/test_portfolio_memberships_api.py | 54 - test/test_portfolio_remove_item_request.py | 39 - test/test_portfolio_request.py | 39 - test/test_portfolio_response.py | 39 - test/test_portfolio_response_array.py | 39 - ...ortfolio_response_current_status_update.py | 39 - ...ortfolio_response_custom_field_settings.py | 39 - test/test_portfolio_response_custom_fields.py | 39 - test/test_portfolio_response_data.py | 39 - test/test_portfolio_response_workspace.py | 39 - test/test_portfolios_api.py | 117 - test/test_portfolios_body.py | 39 - test/test_portfolios_portfolio_gid_body.py | 39 - test/test_preview.py | 39 - test/test_project_base.py | 39 - test/test_project_base_current_status.py | 39 - ...test_project_base_current_status_update.py | 39 - test/test_project_base_workspace.py | 39 - test/test_project_brief_base.py | 39 - test/test_project_brief_compact.py | 39 - test/test_project_brief_request.py | 39 - test/test_project_brief_response.py | 39 - test/test_project_brief_response_data.py | 39 - test/test_project_brief_response_project.py | 39 - test/test_project_briefs_api.py | 61 - ...t_project_briefs_project_brief_gid_body.py | 39 - test/test_project_compact.py | 39 - test/test_project_duplicate_request.py | 39 - ...roject_duplicate_request_schedule_dates.py | 39 - ...oject_gid_add_custom_field_setting_body.py | 39 - test/test_project_gid_add_followers_body.py | 39 - test/test_project_gid_add_members_body.py | 39 - test/test_project_gid_duplicate_body.py | 39 - test/test_project_gid_project_briefs_body.py | 39 - .../test_project_gid_project_statuses_body.py | 39 - ...ct_gid_remove_custom_field_setting_body.py | 39 - .../test_project_gid_remove_followers_body.py | 39 - test/test_project_gid_remove_members_body.py | 39 - .../test_project_gid_save_as_template_body.py | 39 - test/test_project_gid_sections_body.py | 39 - test/test_project_membership_base.py | 39 - test/test_project_membership_compact.py | 39 - test/test_project_membership_compact_array.py | 39 - ...est_project_membership_compact_response.py | 39 - ...roject_membership_compact_response_data.py | 39 - ...test_project_membership_normal_response.py | 39 - ...project_membership_normal_response_data.py | 39 - test/test_project_membership_response.py | 39 - .../test_project_membership_response_array.py | 39 - test/test_project_membership_response_data.py | 39 - ...test_project_membership_response_member.py | 39 - test/test_project_memberships_api.py | 47 - test/test_project_request.py | 39 - test/test_project_response.py | 39 - test/test_project_response_array.py | 39 - test/test_project_response_completed_by.py | 39 - ..._project_response_created_from_template.py | 39 - test/test_project_response_data.py | 39 - test/test_project_response_project_brief.py | 39 - test/test_project_response_team.py | 39 - test/test_project_response_workspace.py | 39 - test/test_project_save_as_template_request.py | 39 - test/test_project_section_insert_request.py | 39 - test/test_project_status_base.py | 39 - test/test_project_status_compact.py | 39 - test/test_project_status_request.py | 39 - test/test_project_status_response.py | 39 - test/test_project_status_response_array.py | 39 - test/test_project_status_response_data.py | 39 - test/test_project_statuses_api.py | 61 - test/test_project_template_base.py | 39 - ...t_project_template_base_requested_dates.py | 39 - ...t_project_template_base_requested_roles.py | 39 - test/test_project_template_base_team.py | 39 - test/test_project_template_compact.py | 39 - ...t_template_gid_instantiate_project_body.py | 39 - ...ct_template_instantiate_project_request.py | 39 - ...antiate_project_request_requested_dates.py | 39 - ...antiate_project_request_requested_roles.py | 39 - test/test_project_template_response.py | 39 - test/test_project_template_response_array.py | 39 - test/test_project_template_response_data.py | 39 - test/test_project_templates_api.py | 68 - test/test_project_update_request.py | 39 - test/test_projects_api.py | 166 - test/test_projects_body.py | 39 - test/test_projects_project_gid_body.py | 39 - ...est_remove_custom_field_setting_request.py | 39 - test/test_remove_followers_request.py | 39 - test/test_remove_members_request.py | 39 - test/test_requested_role_request.py | 39 - test/test_rule_trigger_gid_run_body.py | 39 - test/test_rule_trigger_request.py | 39 - test/test_rule_trigger_response.py | 39 - test/test_rule_trigger_response_data.py | 39 - test/test_rules_api.py | 40 - test/test_section_base.py | 39 - test/test_section_compact.py | 39 - test/test_section_gid_add_task_body.py | 39 - test/test_section_request.py | 39 - test/test_section_response.py | 39 - test/test_section_response_array.py | 39 - test/test_section_response_data.py | 39 - test/test_section_task_insert_request.py | 39 - test/test_sections_api.py | 82 - test/test_sections_insert_body.py | 39 - test/test_sections_section_gid_body.py | 39 - test/test_status_update_base.py | 39 - test/test_status_update_compact.py | 39 - test/test_status_update_request.py | 39 - test/test_status_update_response.py | 39 - test/test_status_update_response_array.py | 39 - test/test_status_update_response_data.py | 39 - test/test_status_update_response_parent.py | 39 - test/test_status_updates_api.py | 61 - test/test_status_updates_body.py | 39 - test/test_stories_api.py | 68 - test/test_stories_story_gid_body.py | 39 - test/test_story_base.py | 39 - test/test_story_compact.py | 39 - test/test_story_request.py | 39 - test/test_story_response.py | 39 - test/test_story_response_array.py | 39 - test/test_story_response_assignee.py | 39 - test/test_story_response_custom_field.py | 39 - test/test_story_response_data.py | 39 - test/test_story_response_dates.py | 39 - test/test_story_response_old_dates.py | 39 - test/test_story_response_old_enum_value.py | 39 - test/test_story_response_old_section.py | 39 - test/test_story_response_previews.py | 39 - test/test_story_response_project.py | 39 - test/test_story_response_story.py | 39 - test/test_story_response_tag.py | 39 - test/test_story_response_target.py | 39 - test/test_story_response_task.py | 39 - test/test_tag_base.py | 39 - test/test_tag_compact.py | 39 - ...st_tag_create_tag_for_workspace_request.py | 39 - test/test_tag_request.py | 39 - test/test_tag_response.py | 39 - test/test_tag_response_array.py | 39 - test/test_tag_response_data.py | 39 - test/test_tags_api.py | 89 - test/test_tags_body.py | 39 - test/test_task_add_followers_request.py | 39 - test/test_task_add_project_request.py | 39 - test/test_task_add_tag_request.py | 39 - test/test_task_base.py | 39 - test/test_task_base_completed_by.py | 39 - test/test_task_base_dependencies.py | 39 - test/test_task_base_external.py | 39 - test/test_task_base_memberships.py | 39 - test/test_task_base_section.py | 39 - test/test_task_compact.py | 39 - test/test_task_count_response.py | 39 - test/test_task_count_response_data.py | 39 - test/test_task_duplicate_request.py | 39 - test/test_task_gid_add_dependencies_body.py | 39 - test/test_task_gid_add_dependents_body.py | 39 - test/test_task_gid_add_followers_body.py | 39 - test/test_task_gid_add_project_body.py | 39 - test/test_task_gid_add_tag_body.py | 39 - test/test_task_gid_duplicate_body.py | 39 - .../test_task_gid_remove_dependencies_body.py | 39 - test/test_task_gid_remove_dependents_body.py | 39 - test/test_task_gid_remove_followers_body.py | 39 - test/test_task_gid_remove_project_body.py | 39 - test/test_task_gid_remove_tag_body.py | 39 - test/test_task_gid_set_parent_body.py | 39 - test/test_task_gid_stories_body.py | 39 - test/test_task_gid_subtasks_body.py | 39 - ...est_task_gid_time_tracking_entries_body.py | 39 - test/test_task_remove_followers_request.py | 39 - test/test_task_remove_project_request.py | 39 - test/test_task_remove_tag_request.py | 39 - test/test_task_request.py | 39 - test/test_task_response.py | 39 - test/test_task_response_array.py | 39 - test/test_task_response_assignee_section.py | 39 - test/test_task_response_custom_fields.py | 39 - test/test_task_response_data.py | 39 - test/test_task_response_parent.py | 39 - test/test_task_response_tags.py | 39 - test/test_task_response_workspace.py | 39 - test/test_task_set_parent_request.py | 39 - test/test_task_template_base.py | 39 - test/test_task_template_compact.py | 39 - ...task_template_gid_instantiate_task_body.py | 39 - ..._task_template_instantiate_task_request.py | 39 - test/test_task_template_recipe.py | 39 - test/test_task_template_recipe_attachments.py | 39 - test/test_task_template_recipe_compact.py | 39 - .../test_task_template_recipe_dependencies.py | 39 - test/test_task_template_response.py | 39 - test/test_task_template_response_array.py | 39 - test/test_task_template_response_data.py | 39 - test/test_task_templates_api.py | 54 - test/test_tasks_api.py | 215 -- test/test_tasks_body.py | 39 - test/test_tasks_task_gid_body.py | 39 - test/test_team_add_user_request.py | 39 - test/test_team_base.py | 39 - test/test_team_compact.py | 39 - test/test_team_gid_add_user_body.py | 39 - test/test_team_gid_projects_body.py | 39 - test/test_team_gid_remove_user_body.py | 39 - test/test_team_membership_base.py | 39 - test/test_team_membership_compact.py | 39 - test/test_team_membership_response.py | 39 - test/test_team_membership_response_array.py | 39 - test/test_team_membership_response_data.py | 39 - test/test_team_memberships_api.py | 61 - test/test_team_remove_user_request.py | 39 - test/test_team_request.py | 39 - test/test_team_response.py | 39 - test/test_team_response_array.py | 39 - test/test_team_response_data.py | 39 - test/test_team_response_organization.py | 39 - test/test_teams_api.py | 82 - test/test_teams_body.py | 39 - test/test_teams_team_gid_body.py | 39 - test/test_template_role.py | 39 - test/test_time_period_base.py | 39 - test/test_time_period_compact.py | 39 - test/test_time_period_response.py | 39 - test/test_time_period_response_array.py | 39 - test/test_time_period_response_data.py | 39 - test/test_time_periods_api.py | 47 - test/test_time_tracking_entries_api.py | 68 - ...ng_entries_time_tracking_entry_gid_body.py | 39 - test/test_time_tracking_entry_base.py | 39 - test/test_time_tracking_entry_base_data.py | 39 - test/test_time_tracking_entry_compact.py | 39 - .../test_time_tracking_entry_compact_array.py | 39 - test/test_typeahead_api.py | 40 - ...test_update_time_tracking_entry_request.py | 39 - test/test_user_base.py | 39 - test/test_user_base_response.py | 39 - test/test_user_base_response_data.py | 39 - test/test_user_base_response_photo.py | 39 - test/test_user_compact.py | 39 - test/test_user_request.py | 39 - test/test_user_response.py | 39 - test/test_user_response_array.py | 39 - test/test_user_response_data.py | 39 - test/test_user_task_list_base.py | 39 - test/test_user_task_list_compact.py | 39 - test/test_user_task_list_request.py | 39 - test/test_user_task_list_response.py | 39 - test/test_user_task_list_response_data.py | 39 - test/test_user_task_lists_api.py | 47 - test/test_users_api.py | 68 - test/test_webhook_compact.py | 39 - test/test_webhook_compact_resource.py | 39 - test/test_webhook_filter.py | 39 - test/test_webhook_request.py | 39 - test/test_webhook_request_filters.py | 39 - test/test_webhook_response.py | 39 - test/test_webhook_response_array.py | 39 - test/test_webhook_response_data.py | 39 - test/test_webhook_update_request.py | 39 - test/test_webhooks_api.py | 68 - test/test_webhooks_body.py | 39 - test/test_webhooks_webhook_gid_body.py | 39 - test/test_workspace_add_user_request.py | 39 - test/test_workspace_base.py | 39 - test/test_workspace_compact.py | 39 - test/test_workspace_gid_add_user_body.py | 39 - test/test_workspace_gid_projects_body.py | 39 - test/test_workspace_gid_remove_user_body.py | 39 - test/test_workspace_gid_tags_body.py | 39 - test/test_workspace_membership_base.py | 39 - test/test_workspace_membership_compact.py | 39 - test/test_workspace_membership_request.py | 39 - test/test_workspace_membership_response.py | 39 - ...est_workspace_membership_response_array.py | 39 - ...test_workspace_membership_response_data.py | 39 - ...pace_membership_response_user_task_list.py | 39 - ...pace_membership_response_vacation_dates.py | 39 - test/test_workspace_memberships_api.py | 54 - test/test_workspace_remove_user_request.py | 39 - test/test_workspace_request.py | 39 - test/test_workspace_response.py | 39 - test/test_workspace_response_array.py | 39 - test/test_workspace_response_data.py | 39 - test/test_workspaces_api.py | 68 - test/test_workspaces_workspace_gid_body.py | 39 - tests/__init__.py | 0 tests/helpers.py | 40 + tests/test_client.py | 407 +++ tests/test_client_attachments.py | 46 + tests/test_client_audit_log_api.py | 152 + tests/test_client_custom_field_settings.py | 43 + tests/test_client_custom_fields.py | 65 + tests/test_client_events.py | 78 + tests/test_client_jobs.py | 13 + tests/test_client_organization_exports.py | 40 + tests/test_client_portfolio_memberships.py | 34 + tests/test_client_portfolios.py | 95 + tests/test_client_projects.py | 104 + tests/test_client_sections.py | 114 + tests/test_client_stories.py | 57 + tests/test_client_tags.py | 37 + tests/test_client_tasks.py | 239 ++ tests/test_client_teams.py | 13 + tests/test_client_user_task_lists.py | 33 + tests/test_client_users.py | 42 + tests/test_client_webhooks.py | 38 + tests/test_client_workspaces.py | 20 + tests/test_errors.py | 24 + tox.ini | 10 - 1646 files changed, 9523 insertions(+), 153625 deletions(-) create mode 100644 .dockerignore create mode 100644 .github/workflows/build.yml create mode 100644 .github/workflows/publish-to-github-releases.yml create mode 100644 .github/workflows/publish-to-pypi.yml delete mode 100644 .github/workflows/publish.yaml create mode 100644 .github/workflows/publish.yml delete mode 100644 .swagger-codegen/VERSION delete mode 100644 .travis.yml create mode 100644 CHANGELOG create mode 100644 CONTRIBUTORS create mode 100644 Dockerfile create mode 100644 MANIFEST.in create mode 100644 TESTING create mode 100644 VERSION delete mode 100644 asana/api/__init__.py delete mode 100644 asana/api/attachments_api.py delete mode 100644 asana/api/audit_log_api_api.py delete mode 100644 asana/api/batch_api_api.py delete mode 100644 asana/api/custom_field_settings_api.py delete mode 100644 asana/api/custom_fields_api.py delete mode 100644 asana/api/events_api.py delete mode 100644 asana/api/goal_relationships_api.py delete mode 100644 asana/api/goals_api.py delete mode 100644 asana/api/jobs_api.py delete mode 100644 asana/api/memberships_api.py delete mode 100644 asana/api/organization_exports_api.py delete mode 100644 asana/api/portfolio_memberships_api.py delete mode 100644 asana/api/portfolios_api.py delete mode 100644 asana/api/project_briefs_api.py delete mode 100644 asana/api/project_memberships_api.py delete mode 100644 asana/api/project_statuses_api.py delete mode 100644 asana/api/project_templates_api.py delete mode 100644 asana/api/projects_api.py delete mode 100644 asana/api/rules_api.py delete mode 100644 asana/api/sections_api.py delete mode 100644 asana/api/status_updates_api.py delete mode 100644 asana/api/stories_api.py delete mode 100644 asana/api/tags_api.py delete mode 100644 asana/api/task_templates_api.py delete mode 100644 asana/api/tasks_api.py delete mode 100644 asana/api/team_memberships_api.py delete mode 100644 asana/api/teams_api.py delete mode 100644 asana/api/time_periods_api.py delete mode 100644 asana/api/time_tracking_entries_api.py delete mode 100644 asana/api/typeahead_api.py delete mode 100644 asana/api/user_task_lists_api.py delete mode 100644 asana/api/users_api.py delete mode 100644 asana/api/webhooks_api.py delete mode 100644 asana/api/workspace_memberships_api.py delete mode 100644 asana/api/workspaces_api.py delete mode 100644 asana/api_client.py create mode 100644 asana/client.py delete mode 100644 asana/configuration.py create mode 100644 asana/error.py delete mode 100644 asana/models/__init__.py delete mode 100644 asana/models/add_custom_field_setting_request.py delete mode 100644 asana/models/add_followers_request.py delete mode 100644 asana/models/add_members_request.py delete mode 100644 asana/models/all_of_project_response_owner.py delete mode 100644 asana/models/all_of_project_template_base_owner.py delete mode 100644 asana/models/all_of_project_template_response_owner.py delete mode 100644 asana/models/all_of_story_response_new_date_value.py delete mode 100644 asana/models/all_of_story_response_old_date_value.py delete mode 100644 asana/models/all_of_task_template_response_created_by.py delete mode 100644 asana/models/all_of_task_template_response_project.py delete mode 100644 asana/models/all_of_task_template_response_template.py delete mode 100644 asana/models/all_of_user_task_list_base_owner.py delete mode 100644 asana/models/all_of_user_task_list_base_workspace.py delete mode 100644 asana/models/all_of_user_task_list_compact_owner.py delete mode 100644 asana/models/all_of_user_task_list_compact_workspace.py delete mode 100644 asana/models/all_of_user_task_list_request_owner.py delete mode 100644 asana/models/all_of_user_task_list_request_workspace.py delete mode 100644 asana/models/all_of_user_task_list_response_owner.py delete mode 100644 asana/models/all_of_user_task_list_response_workspace.py delete mode 100644 asana/models/all_of_workspace_membership_response_user_task_list_owner.py delete mode 100644 asana/models/all_of_workspace_membership_response_user_task_list_workspace.py delete mode 100644 asana/models/asana_named_resource.py delete mode 100644 asana/models/asana_named_resource_array.py delete mode 100644 asana/models/asana_resource.py delete mode 100644 asana/models/attachment_base.py delete mode 100644 asana/models/attachment_compact.py delete mode 100644 asana/models/attachment_request.py delete mode 100644 asana/models/attachment_response.py delete mode 100644 asana/models/attachment_response_array.py delete mode 100644 asana/models/attachment_response_data.py delete mode 100644 asana/models/attachment_response_parent.py delete mode 100644 asana/models/attachment_response_parent_created_by.py delete mode 100644 asana/models/audit_log_event.py delete mode 100644 asana/models/audit_log_event_actor.py delete mode 100644 asana/models/audit_log_event_array.py delete mode 100644 asana/models/audit_log_event_context.py delete mode 100644 asana/models/audit_log_event_details.py delete mode 100644 asana/models/audit_log_event_resource.py delete mode 100644 asana/models/batch_body.py delete mode 100644 asana/models/batch_request.py delete mode 100644 asana/models/batch_request_action.py delete mode 100644 asana/models/batch_request_actions.py delete mode 100644 asana/models/batch_request_options.py delete mode 100644 asana/models/batch_response.py delete mode 100644 asana/models/batch_response_array.py delete mode 100644 asana/models/create_membership_request.py delete mode 100644 asana/models/create_time_tracking_entry_request.py delete mode 100644 asana/models/custom_field_base.py delete mode 100644 asana/models/custom_field_base_date_value.py delete mode 100644 asana/models/custom_field_base_enum_options.py delete mode 100644 asana/models/custom_field_base_enum_value.py delete mode 100644 asana/models/custom_field_compact.py delete mode 100644 asana/models/custom_field_gid_enum_options_body.py delete mode 100644 asana/models/custom_field_request.py delete mode 100644 asana/models/custom_field_response.py delete mode 100644 asana/models/custom_field_response_array.py delete mode 100644 asana/models/custom_field_response_created_by.py delete mode 100644 asana/models/custom_field_response_data.py delete mode 100644 asana/models/custom_field_response_people_value.py delete mode 100644 asana/models/custom_field_setting_base.py delete mode 100644 asana/models/custom_field_setting_compact.py delete mode 100644 asana/models/custom_field_setting_response.py delete mode 100644 asana/models/custom_field_setting_response_array.py delete mode 100644 asana/models/custom_field_setting_response_custom_field.py delete mode 100644 asana/models/custom_field_setting_response_data.py delete mode 100644 asana/models/custom_field_setting_response_parent.py delete mode 100644 asana/models/custom_field_setting_response_project.py delete mode 100644 asana/models/custom_fields_body.py delete mode 100644 asana/models/custom_fields_custom_field_gid_body.py delete mode 100644 asana/models/date_variable_compact.py delete mode 100644 asana/models/date_variable_request.py delete mode 100644 asana/models/empty_response.py delete mode 100644 asana/models/empty_response_data.py delete mode 100644 asana/models/enum_option.py delete mode 100644 asana/models/enum_option_base.py delete mode 100644 asana/models/enum_option_data.py delete mode 100644 asana/models/enum_option_insert_request.py delete mode 100644 asana/models/enum_option_request.py delete mode 100644 asana/models/enum_options_enum_option_gid_body.py delete mode 100644 asana/models/enum_options_insert_body.py delete mode 100644 asana/models/error.py delete mode 100644 asana/models/error_response.py delete mode 100644 asana/models/error_response_errors.py delete mode 100644 asana/models/event_response.py delete mode 100644 asana/models/event_response_array.py delete mode 100644 asana/models/event_response_change.py delete mode 100644 asana/models/event_response_parent.py delete mode 100644 asana/models/event_response_resource.py delete mode 100644 asana/models/event_response_user.py delete mode 100644 asana/models/goal_add_subgoal_request.py delete mode 100644 asana/models/goal_add_supporting_relationship_request.py delete mode 100644 asana/models/goal_add_supporting_work_request.py delete mode 100644 asana/models/goal_base.py delete mode 100644 asana/models/goal_compact.py delete mode 100644 asana/models/goal_gid_add_followers_body.py delete mode 100644 asana/models/goal_gid_add_supporting_relationship_body.py delete mode 100644 asana/models/goal_gid_remove_followers_body.py delete mode 100644 asana/models/goal_gid_remove_supporting_relationship_body.py delete mode 100644 asana/models/goal_gid_set_metric_body.py delete mode 100644 asana/models/goal_gid_set_metric_current_value_body.py delete mode 100644 asana/models/goal_membership_base.py delete mode 100644 asana/models/goal_membership_base_goal.py delete mode 100644 asana/models/goal_membership_compact.py delete mode 100644 asana/models/goal_membership_response.py delete mode 100644 asana/models/goal_membership_response_user.py delete mode 100644 asana/models/goal_membership_response_workspace.py delete mode 100644 asana/models/goal_metric_base.py delete mode 100644 asana/models/goal_metric_current_value_request.py delete mode 100644 asana/models/goal_metric_request.py delete mode 100644 asana/models/goal_relationship_base.py delete mode 100644 asana/models/goal_relationship_base_supported_goal.py delete mode 100644 asana/models/goal_relationship_base_supporting_resource.py delete mode 100644 asana/models/goal_relationship_compact.py delete mode 100644 asana/models/goal_relationship_request.py delete mode 100644 asana/models/goal_relationship_response.py delete mode 100644 asana/models/goal_relationship_response_array.py delete mode 100644 asana/models/goal_relationship_response_data.py delete mode 100644 asana/models/goal_relationships_goal_relationship_gid_body.py delete mode 100644 asana/models/goal_remove_subgoal_request.py delete mode 100644 asana/models/goal_remove_supporting_relationship_request.py delete mode 100644 asana/models/goal_request.py delete mode 100644 asana/models/goal_request_base.py delete mode 100644 asana/models/goal_response.py delete mode 100644 asana/models/goal_response_array.py delete mode 100644 asana/models/goal_response_current_status_update.py delete mode 100644 asana/models/goal_response_data.py delete mode 100644 asana/models/goal_response_likes.py delete mode 100644 asana/models/goal_response_metric.py delete mode 100644 asana/models/goal_response_team.py delete mode 100644 asana/models/goal_response_time_period.py delete mode 100644 asana/models/goal_response_workspace.py delete mode 100644 asana/models/goal_update_request.py delete mode 100644 asana/models/goals_body.py delete mode 100644 asana/models/goals_goal_gid_body.py delete mode 100644 asana/models/inline_response412.py delete mode 100644 asana/models/inline_response412_errors.py delete mode 100644 asana/models/job_base.py delete mode 100644 asana/models/job_base_new_project.py delete mode 100644 asana/models/job_base_new_project_template.py delete mode 100644 asana/models/job_base_new_task.py delete mode 100644 asana/models/job_compact.py delete mode 100644 asana/models/job_response.py delete mode 100644 asana/models/job_response_data.py delete mode 100644 asana/models/like.py delete mode 100644 asana/models/member_compact.py delete mode 100644 asana/models/membership_compact.py delete mode 100644 asana/models/membership_compact_goal.py delete mode 100644 asana/models/membership_compact_member.py delete mode 100644 asana/models/membership_compact_parent.py delete mode 100644 asana/models/membership_request.py delete mode 100644 asana/models/membership_response.py delete mode 100644 asana/models/membership_response_array.py delete mode 100644 asana/models/membership_response_data.py delete mode 100644 asana/models/memberships_body.py delete mode 100644 asana/models/modify_dependencies_request.py delete mode 100644 asana/models/modify_dependents_request.py delete mode 100644 asana/models/next_page.py delete mode 100644 asana/models/organization_export_base.py delete mode 100644 asana/models/organization_export_compact.py delete mode 100644 asana/models/organization_export_request.py delete mode 100644 asana/models/organization_export_response.py delete mode 100644 asana/models/organization_export_response_data.py delete mode 100644 asana/models/organization_exports_body.py delete mode 100644 asana/models/portfolio_add_item_request.py delete mode 100644 asana/models/portfolio_base.py delete mode 100644 asana/models/portfolio_compact.py delete mode 100644 asana/models/portfolio_gid_add_custom_field_setting_body.py delete mode 100644 asana/models/portfolio_gid_add_item_body.py delete mode 100644 asana/models/portfolio_gid_add_members_body.py delete mode 100644 asana/models/portfolio_gid_remove_custom_field_setting_body.py delete mode 100644 asana/models/portfolio_gid_remove_item_body.py delete mode 100644 asana/models/portfolio_gid_remove_members_body.py delete mode 100644 asana/models/portfolio_membership_base.py delete mode 100644 asana/models/portfolio_membership_base_portfolio.py delete mode 100644 asana/models/portfolio_membership_compact.py delete mode 100644 asana/models/portfolio_membership_response.py delete mode 100644 asana/models/portfolio_membership_response_array.py delete mode 100644 asana/models/portfolio_membership_response_data.py delete mode 100644 asana/models/portfolio_remove_item_request.py delete mode 100644 asana/models/portfolio_request.py delete mode 100644 asana/models/portfolio_response.py delete mode 100644 asana/models/portfolio_response_array.py delete mode 100644 asana/models/portfolio_response_current_status_update.py delete mode 100644 asana/models/portfolio_response_custom_field_settings.py delete mode 100644 asana/models/portfolio_response_custom_fields.py delete mode 100644 asana/models/portfolio_response_data.py delete mode 100644 asana/models/portfolio_response_workspace.py delete mode 100644 asana/models/portfolios_body.py delete mode 100644 asana/models/portfolios_portfolio_gid_body.py delete mode 100644 asana/models/preview.py delete mode 100644 asana/models/project_base.py delete mode 100644 asana/models/project_base_current_status.py delete mode 100644 asana/models/project_base_current_status_update.py delete mode 100644 asana/models/project_base_workspace.py delete mode 100644 asana/models/project_brief_base.py delete mode 100644 asana/models/project_brief_compact.py delete mode 100644 asana/models/project_brief_request.py delete mode 100644 asana/models/project_brief_response.py delete mode 100644 asana/models/project_brief_response_data.py delete mode 100644 asana/models/project_brief_response_project.py delete mode 100644 asana/models/project_briefs_project_brief_gid_body.py delete mode 100644 asana/models/project_compact.py delete mode 100644 asana/models/project_duplicate_request.py delete mode 100644 asana/models/project_duplicate_request_schedule_dates.py delete mode 100644 asana/models/project_gid_add_custom_field_setting_body.py delete mode 100644 asana/models/project_gid_add_followers_body.py delete mode 100644 asana/models/project_gid_add_members_body.py delete mode 100644 asana/models/project_gid_duplicate_body.py delete mode 100644 asana/models/project_gid_project_briefs_body.py delete mode 100644 asana/models/project_gid_project_statuses_body.py delete mode 100644 asana/models/project_gid_remove_custom_field_setting_body.py delete mode 100644 asana/models/project_gid_remove_followers_body.py delete mode 100644 asana/models/project_gid_remove_members_body.py delete mode 100644 asana/models/project_gid_save_as_template_body.py delete mode 100644 asana/models/project_gid_sections_body.py delete mode 100644 asana/models/project_membership_base.py delete mode 100644 asana/models/project_membership_compact.py delete mode 100644 asana/models/project_membership_compact_array.py delete mode 100644 asana/models/project_membership_compact_response.py delete mode 100644 asana/models/project_membership_compact_response_data.py delete mode 100644 asana/models/project_membership_normal_response.py delete mode 100644 asana/models/project_membership_normal_response_data.py delete mode 100644 asana/models/project_membership_response.py delete mode 100644 asana/models/project_membership_response_array.py delete mode 100644 asana/models/project_membership_response_data.py delete mode 100644 asana/models/project_membership_response_member.py delete mode 100644 asana/models/project_request.py delete mode 100644 asana/models/project_response.py delete mode 100644 asana/models/project_response_array.py delete mode 100644 asana/models/project_response_completed_by.py delete mode 100644 asana/models/project_response_created_from_template.py delete mode 100644 asana/models/project_response_data.py delete mode 100644 asana/models/project_response_project_brief.py delete mode 100644 asana/models/project_response_team.py delete mode 100644 asana/models/project_response_workspace.py delete mode 100644 asana/models/project_save_as_template_request.py delete mode 100644 asana/models/project_section_insert_request.py delete mode 100644 asana/models/project_status_base.py delete mode 100644 asana/models/project_status_compact.py delete mode 100644 asana/models/project_status_request.py delete mode 100644 asana/models/project_status_response.py delete mode 100644 asana/models/project_status_response_array.py delete mode 100644 asana/models/project_status_response_data.py delete mode 100644 asana/models/project_template_base.py delete mode 100644 asana/models/project_template_base_requested_dates.py delete mode 100644 asana/models/project_template_base_requested_roles.py delete mode 100644 asana/models/project_template_base_team.py delete mode 100644 asana/models/project_template_compact.py delete mode 100644 asana/models/project_template_gid_instantiate_project_body.py delete mode 100644 asana/models/project_template_instantiate_project_request.py delete mode 100644 asana/models/project_template_instantiate_project_request_requested_dates.py delete mode 100644 asana/models/project_template_instantiate_project_request_requested_roles.py delete mode 100644 asana/models/project_template_response.py delete mode 100644 asana/models/project_template_response_array.py delete mode 100644 asana/models/project_template_response_data.py delete mode 100644 asana/models/project_update_request.py delete mode 100644 asana/models/projects_body.py delete mode 100644 asana/models/projects_project_gid_body.py delete mode 100644 asana/models/remove_custom_field_setting_request.py delete mode 100644 asana/models/remove_followers_request.py delete mode 100644 asana/models/remove_members_request.py delete mode 100644 asana/models/requested_role_request.py delete mode 100644 asana/models/rule_trigger_gid_run_body.py delete mode 100644 asana/models/rule_trigger_request.py delete mode 100644 asana/models/rule_trigger_response.py delete mode 100644 asana/models/rule_trigger_response_data.py delete mode 100644 asana/models/section_base.py delete mode 100644 asana/models/section_compact.py delete mode 100644 asana/models/section_gid_add_task_body.py delete mode 100644 asana/models/section_request.py delete mode 100644 asana/models/section_response.py delete mode 100644 asana/models/section_response_array.py delete mode 100644 asana/models/section_response_data.py delete mode 100644 asana/models/section_task_insert_request.py delete mode 100644 asana/models/sections_insert_body.py delete mode 100644 asana/models/sections_section_gid_body.py delete mode 100644 asana/models/status_update_base.py delete mode 100644 asana/models/status_update_compact.py delete mode 100644 asana/models/status_update_request.py delete mode 100644 asana/models/status_update_response.py delete mode 100644 asana/models/status_update_response_array.py delete mode 100644 asana/models/status_update_response_data.py delete mode 100644 asana/models/status_update_response_parent.py delete mode 100644 asana/models/status_updates_body.py delete mode 100644 asana/models/stories_story_gid_body.py delete mode 100644 asana/models/story_base.py delete mode 100644 asana/models/story_compact.py delete mode 100644 asana/models/story_request.py delete mode 100644 asana/models/story_response.py delete mode 100644 asana/models/story_response_array.py delete mode 100644 asana/models/story_response_assignee.py delete mode 100644 asana/models/story_response_custom_field.py delete mode 100644 asana/models/story_response_data.py delete mode 100644 asana/models/story_response_dates.py delete mode 100644 asana/models/story_response_old_dates.py delete mode 100644 asana/models/story_response_old_enum_value.py delete mode 100644 asana/models/story_response_old_section.py delete mode 100644 asana/models/story_response_previews.py delete mode 100644 asana/models/story_response_project.py delete mode 100644 asana/models/story_response_story.py delete mode 100644 asana/models/story_response_tag.py delete mode 100644 asana/models/story_response_target.py delete mode 100644 asana/models/story_response_task.py delete mode 100644 asana/models/tag_base.py delete mode 100644 asana/models/tag_compact.py delete mode 100644 asana/models/tag_create_tag_for_workspace_request.py delete mode 100644 asana/models/tag_request.py delete mode 100644 asana/models/tag_response.py delete mode 100644 asana/models/tag_response_array.py delete mode 100644 asana/models/tag_response_data.py delete mode 100644 asana/models/tags_body.py delete mode 100644 asana/models/task_add_followers_request.py delete mode 100644 asana/models/task_add_project_request.py delete mode 100644 asana/models/task_add_tag_request.py delete mode 100644 asana/models/task_base.py delete mode 100644 asana/models/task_base_completed_by.py delete mode 100644 asana/models/task_base_dependencies.py delete mode 100644 asana/models/task_base_external.py delete mode 100644 asana/models/task_base_memberships.py delete mode 100644 asana/models/task_base_section.py delete mode 100644 asana/models/task_compact.py delete mode 100644 asana/models/task_count_response.py delete mode 100644 asana/models/task_count_response_data.py delete mode 100644 asana/models/task_duplicate_request.py delete mode 100644 asana/models/task_gid_add_dependencies_body.py delete mode 100644 asana/models/task_gid_add_dependents_body.py delete mode 100644 asana/models/task_gid_add_followers_body.py delete mode 100644 asana/models/task_gid_add_project_body.py delete mode 100644 asana/models/task_gid_add_tag_body.py delete mode 100644 asana/models/task_gid_duplicate_body.py delete mode 100644 asana/models/task_gid_remove_dependencies_body.py delete mode 100644 asana/models/task_gid_remove_dependents_body.py delete mode 100644 asana/models/task_gid_remove_followers_body.py delete mode 100644 asana/models/task_gid_remove_project_body.py delete mode 100644 asana/models/task_gid_remove_tag_body.py delete mode 100644 asana/models/task_gid_set_parent_body.py delete mode 100644 asana/models/task_gid_stories_body.py delete mode 100644 asana/models/task_gid_subtasks_body.py delete mode 100644 asana/models/task_gid_time_tracking_entries_body.py delete mode 100644 asana/models/task_remove_followers_request.py delete mode 100644 asana/models/task_remove_project_request.py delete mode 100644 asana/models/task_remove_tag_request.py delete mode 100644 asana/models/task_request.py delete mode 100644 asana/models/task_response.py delete mode 100644 asana/models/task_response_array.py delete mode 100644 asana/models/task_response_assignee_section.py delete mode 100644 asana/models/task_response_custom_fields.py delete mode 100644 asana/models/task_response_data.py delete mode 100644 asana/models/task_response_parent.py delete mode 100644 asana/models/task_response_tags.py delete mode 100644 asana/models/task_response_workspace.py delete mode 100644 asana/models/task_set_parent_request.py delete mode 100644 asana/models/task_template_base.py delete mode 100644 asana/models/task_template_compact.py delete mode 100644 asana/models/task_template_gid_instantiate_task_body.py delete mode 100644 asana/models/task_template_instantiate_task_request.py delete mode 100644 asana/models/task_template_recipe.py delete mode 100644 asana/models/task_template_recipe_attachments.py delete mode 100644 asana/models/task_template_recipe_compact.py delete mode 100644 asana/models/task_template_recipe_dependencies.py delete mode 100644 asana/models/task_template_response.py delete mode 100644 asana/models/task_template_response_array.py delete mode 100644 asana/models/task_template_response_data.py delete mode 100644 asana/models/tasks_body.py delete mode 100644 asana/models/tasks_task_gid_body.py delete mode 100644 asana/models/team_add_user_request.py delete mode 100644 asana/models/team_base.py delete mode 100644 asana/models/team_compact.py delete mode 100644 asana/models/team_gid_add_user_body.py delete mode 100644 asana/models/team_gid_projects_body.py delete mode 100644 asana/models/team_gid_remove_user_body.py delete mode 100644 asana/models/team_membership_base.py delete mode 100644 asana/models/team_membership_compact.py delete mode 100644 asana/models/team_membership_response.py delete mode 100644 asana/models/team_membership_response_array.py delete mode 100644 asana/models/team_membership_response_data.py delete mode 100644 asana/models/team_remove_user_request.py delete mode 100644 asana/models/team_request.py delete mode 100644 asana/models/team_response.py delete mode 100644 asana/models/team_response_array.py delete mode 100644 asana/models/team_response_data.py delete mode 100644 asana/models/team_response_organization.py delete mode 100644 asana/models/teams_body.py delete mode 100644 asana/models/teams_team_gid_body.py delete mode 100644 asana/models/template_role.py delete mode 100644 asana/models/time_period_base.py delete mode 100644 asana/models/time_period_compact.py delete mode 100644 asana/models/time_period_response.py delete mode 100644 asana/models/time_period_response_array.py delete mode 100644 asana/models/time_period_response_data.py delete mode 100644 asana/models/time_tracking_entries_time_tracking_entry_gid_body.py delete mode 100644 asana/models/time_tracking_entry_base.py delete mode 100644 asana/models/time_tracking_entry_base_data.py delete mode 100644 asana/models/time_tracking_entry_compact.py delete mode 100644 asana/models/time_tracking_entry_compact_array.py delete mode 100644 asana/models/update_time_tracking_entry_request.py delete mode 100644 asana/models/user_base.py delete mode 100644 asana/models/user_base_response.py delete mode 100644 asana/models/user_base_response_data.py delete mode 100644 asana/models/user_base_response_photo.py delete mode 100644 asana/models/user_compact.py delete mode 100644 asana/models/user_request.py delete mode 100644 asana/models/user_response.py delete mode 100644 asana/models/user_response_array.py delete mode 100644 asana/models/user_response_data.py delete mode 100644 asana/models/user_task_list_base.py delete mode 100644 asana/models/user_task_list_compact.py delete mode 100644 asana/models/user_task_list_request.py delete mode 100644 asana/models/user_task_list_response.py delete mode 100644 asana/models/user_task_list_response_data.py delete mode 100644 asana/models/webhook_compact.py delete mode 100644 asana/models/webhook_compact_resource.py delete mode 100644 asana/models/webhook_filter.py delete mode 100644 asana/models/webhook_request.py delete mode 100644 asana/models/webhook_request_filters.py delete mode 100644 asana/models/webhook_response.py delete mode 100644 asana/models/webhook_response_array.py delete mode 100644 asana/models/webhook_response_data.py delete mode 100644 asana/models/webhook_update_request.py delete mode 100644 asana/models/webhooks_body.py delete mode 100644 asana/models/webhooks_webhook_gid_body.py delete mode 100644 asana/models/workspace_add_user_request.py delete mode 100644 asana/models/workspace_base.py delete mode 100644 asana/models/workspace_compact.py delete mode 100644 asana/models/workspace_gid_add_user_body.py delete mode 100644 asana/models/workspace_gid_projects_body.py delete mode 100644 asana/models/workspace_gid_remove_user_body.py delete mode 100644 asana/models/workspace_gid_tags_body.py delete mode 100644 asana/models/workspace_membership_base.py delete mode 100644 asana/models/workspace_membership_compact.py delete mode 100644 asana/models/workspace_membership_request.py delete mode 100644 asana/models/workspace_membership_response.py delete mode 100644 asana/models/workspace_membership_response_array.py delete mode 100644 asana/models/workspace_membership_response_data.py delete mode 100644 asana/models/workspace_membership_response_user_task_list.py delete mode 100644 asana/models/workspace_membership_response_vacation_dates.py delete mode 100644 asana/models/workspace_remove_user_request.py delete mode 100644 asana/models/workspace_request.py delete mode 100644 asana/models/workspace_response.py delete mode 100644 asana/models/workspace_response_array.py delete mode 100644 asana/models/workspace_response_data.py delete mode 100644 asana/models/workspaces_workspace_gid_body.py create mode 100644 asana/page_iterator.py create mode 100644 asana/resources/__init__.py create mode 100644 asana/resources/attachments.py create mode 100644 asana/resources/audit_log_api.py create mode 100644 asana/resources/batch_api.py create mode 100644 asana/resources/custom_field_settings.py create mode 100644 asana/resources/custom_fields.py create mode 100644 asana/resources/events.py create mode 100644 asana/resources/gen/__init__.py create mode 100644 asana/resources/gen/attachments.py create mode 100644 asana/resources/gen/audit_log_api.py create mode 100644 asana/resources/gen/batch_api.py create mode 100644 asana/resources/gen/custom_field_settings.py create mode 100644 asana/resources/gen/custom_fields.py create mode 100644 asana/resources/gen/events.py create mode 100644 asana/resources/gen/goal_relationships.py create mode 100644 asana/resources/gen/goals.py create mode 100644 asana/resources/gen/jobs.py create mode 100644 asana/resources/gen/memberships.py create mode 100644 asana/resources/gen/message.py create mode 100644 asana/resources/gen/organization_exports.py create mode 100644 asana/resources/gen/portfolio_memberships.py create mode 100644 asana/resources/gen/portfolios.py create mode 100644 asana/resources/gen/project_briefs.py create mode 100644 asana/resources/gen/project_memberships.py create mode 100644 asana/resources/gen/project_statuses.py create mode 100644 asana/resources/gen/project_templates.py create mode 100644 asana/resources/gen/projects.py create mode 100644 asana/resources/gen/sections.py create mode 100644 asana/resources/gen/status_updates.py create mode 100644 asana/resources/gen/stories.py create mode 100644 asana/resources/gen/tags.py create mode 100644 asana/resources/gen/tasks.py create mode 100644 asana/resources/gen/team_memberships.py create mode 100644 asana/resources/gen/teams.py create mode 100644 asana/resources/gen/time_periods.py create mode 100644 asana/resources/gen/typeahead.py create mode 100644 asana/resources/gen/user_task_lists.py create mode 100644 asana/resources/gen/users.py create mode 100644 asana/resources/gen/webhooks.py create mode 100644 asana/resources/gen/workspace_memberships.py create mode 100644 asana/resources/gen/workspaces.py create mode 100644 asana/resources/goal_relationships.py create mode 100644 asana/resources/goals.py create mode 100644 asana/resources/jobs.py create mode 100644 asana/resources/memberships.py create mode 100644 asana/resources/message.py create mode 100644 asana/resources/organization_exports.py create mode 100644 asana/resources/portfolio_memberships.py create mode 100644 asana/resources/portfolios.py create mode 100644 asana/resources/project_briefs.py create mode 100644 asana/resources/project_memberships.py create mode 100644 asana/resources/project_statuses.py create mode 100644 asana/resources/project_templates.py create mode 100644 asana/resources/projects.py create mode 100644 asana/resources/sections.py create mode 100644 asana/resources/status_updates.py create mode 100644 asana/resources/stories.py create mode 100644 asana/resources/tags.py create mode 100644 asana/resources/tasks.py create mode 100644 asana/resources/team_memberships.py create mode 100644 asana/resources/teams.py create mode 100644 asana/resources/time_periods.py create mode 100644 asana/resources/typeahead.py create mode 100644 asana/resources/user_task_lists.py create mode 100644 asana/resources/users.py create mode 100644 asana/resources/webhooks.py create mode 100644 asana/resources/workspace_memberships.py create mode 100644 asana/resources/workspaces.py delete mode 100644 asana/rest.py create mode 100644 asana/session.py create mode 100644 asana/version.py delete mode 100644 codegen/swagger/README.md delete mode 100644 codegen/swagger/pom.xml delete mode 100644 codegen/swagger/src/main/java/com/asana/codegen/ExampleUtility.java delete mode 100644 codegen/swagger/src/main/java/com/asana/codegen/PythonClientCodegenGenerator.java delete mode 100644 codegen/swagger/src/main/java/com/asana/codegen/ReadMe.java delete mode 100644 codegen/swagger/src/main/resources/META-INF/services/io.swagger.codegen.v3.CodegenConfig delete mode 100644 codegen/templates/README.mustache delete mode 100644 codegen/templates/api.mustache delete mode 100644 codegen/templates/api_client.mustache delete mode 100644 codegen/templates/api_doc.mustache delete mode 100644 codegen/templates/code_sample.mustache delete mode 100644 codegen/templates/code_samples.mustache delete mode 100644 codegen/templates/setup.mustache create mode 100755 deploy.py delete mode 100644 docs/AddCustomFieldSettingRequest.md delete mode 100644 docs/AddFollowersRequest.md delete mode 100644 docs/AddMembersRequest.md delete mode 100644 docs/AllOfProjectResponseOwner.md delete mode 100644 docs/AllOfProjectTemplateBaseOwner.md delete mode 100644 docs/AllOfProjectTemplateResponseOwner.md delete mode 100644 docs/AllOfStoryResponseNewDateValue.md delete mode 100644 docs/AllOfStoryResponseOldDateValue.md delete mode 100644 docs/AllOfTaskTemplateResponseCreatedBy.md delete mode 100644 docs/AllOfTaskTemplateResponseProject.md delete mode 100644 docs/AllOfTaskTemplateResponseTemplate.md delete mode 100644 docs/AllOfUserTaskListBaseOwner.md delete mode 100644 docs/AllOfUserTaskListBaseWorkspace.md delete mode 100644 docs/AllOfUserTaskListCompactOwner.md delete mode 100644 docs/AllOfUserTaskListCompactWorkspace.md delete mode 100644 docs/AllOfUserTaskListRequestOwner.md delete mode 100644 docs/AllOfUserTaskListRequestWorkspace.md delete mode 100644 docs/AllOfUserTaskListResponseOwner.md delete mode 100644 docs/AllOfUserTaskListResponseWorkspace.md delete mode 100644 docs/AllOfWorkspaceMembershipResponseUserTaskListOwner.md delete mode 100644 docs/AllOfWorkspaceMembershipResponseUserTaskListWorkspace.md delete mode 100644 docs/AsanaNamedResource.md delete mode 100644 docs/AsanaNamedResourceArray.md delete mode 100644 docs/AsanaResource.md delete mode 100644 docs/AttachmentBase.md delete mode 100644 docs/AttachmentCompact.md delete mode 100644 docs/AttachmentRequest.md delete mode 100644 docs/AttachmentResponse.md delete mode 100644 docs/AttachmentResponseArray.md delete mode 100644 docs/AttachmentResponseData.md delete mode 100644 docs/AttachmentResponseParent.md delete mode 100644 docs/AttachmentResponseParentCreatedBy.md delete mode 100644 docs/AttachmentsApi.md delete mode 100644 docs/AttachmentsApi.yaml delete mode 100644 docs/AuditLogAPIApi.md delete mode 100644 docs/AuditLogAPIApi.yaml delete mode 100644 docs/AuditLogEvent.md delete mode 100644 docs/AuditLogEventActor.md delete mode 100644 docs/AuditLogEventArray.md delete mode 100644 docs/AuditLogEventContext.md delete mode 100644 docs/AuditLogEventDetails.md delete mode 100644 docs/AuditLogEventResource.md delete mode 100644 docs/BatchAPIApi.md delete mode 100644 docs/BatchAPIApi.yaml delete mode 100644 docs/BatchBody.md delete mode 100644 docs/BatchRequest.md delete mode 100644 docs/BatchRequestAction.md delete mode 100644 docs/BatchRequestActions.md delete mode 100644 docs/BatchRequestOptions.md delete mode 100644 docs/BatchResponse.md delete mode 100644 docs/BatchResponseArray.md delete mode 100644 docs/CreateMembershipRequest.md delete mode 100644 docs/CreateTimeTrackingEntryRequest.md delete mode 100644 docs/CustomFieldBase.md delete mode 100644 docs/CustomFieldBaseDateValue.md delete mode 100644 docs/CustomFieldBaseEnumOptions.md delete mode 100644 docs/CustomFieldBaseEnumValue.md delete mode 100644 docs/CustomFieldCompact.md delete mode 100644 docs/CustomFieldGidEnumOptionsBody.md delete mode 100644 docs/CustomFieldRequest.md delete mode 100644 docs/CustomFieldResponse.md delete mode 100644 docs/CustomFieldResponseArray.md delete mode 100644 docs/CustomFieldResponseCreatedBy.md delete mode 100644 docs/CustomFieldResponseData.md delete mode 100644 docs/CustomFieldResponsePeopleValue.md delete mode 100644 docs/CustomFieldSettingBase.md delete mode 100644 docs/CustomFieldSettingCompact.md delete mode 100644 docs/CustomFieldSettingResponse.md delete mode 100644 docs/CustomFieldSettingResponseArray.md delete mode 100644 docs/CustomFieldSettingResponseCustomField.md delete mode 100644 docs/CustomFieldSettingResponseData.md delete mode 100644 docs/CustomFieldSettingResponseParent.md delete mode 100644 docs/CustomFieldSettingResponseProject.md delete mode 100644 docs/CustomFieldSettingsApi.md delete mode 100644 docs/CustomFieldSettingsApi.yaml delete mode 100644 docs/CustomFieldsApi.md delete mode 100644 docs/CustomFieldsApi.yaml delete mode 100644 docs/CustomFieldsBody.md delete mode 100644 docs/CustomFieldsCustomFieldGidBody.md delete mode 100644 docs/DateVariableCompact.md delete mode 100644 docs/DateVariableRequest.md delete mode 100644 docs/EmptyResponse.md delete mode 100644 docs/EmptyResponseData.md delete mode 100644 docs/EnumOption.md delete mode 100644 docs/EnumOptionBase.md delete mode 100644 docs/EnumOptionData.md delete mode 100644 docs/EnumOptionInsertRequest.md delete mode 100644 docs/EnumOptionRequest.md delete mode 100644 docs/EnumOptionsEnumOptionGidBody.md delete mode 100644 docs/EnumOptionsInsertBody.md delete mode 100644 docs/Error.md delete mode 100644 docs/ErrorResponse.md delete mode 100644 docs/ErrorResponseErrors.md delete mode 100644 docs/EventResponse.md delete mode 100644 docs/EventResponseArray.md delete mode 100644 docs/EventResponseChange.md delete mode 100644 docs/EventResponseParent.md delete mode 100644 docs/EventResponseResource.md delete mode 100644 docs/EventResponseUser.md delete mode 100644 docs/EventsApi.md delete mode 100644 docs/EventsApi.yaml delete mode 100644 docs/GoalAddSubgoalRequest.md delete mode 100644 docs/GoalAddSupportingRelationshipRequest.md delete mode 100644 docs/GoalAddSupportingWorkRequest.md delete mode 100644 docs/GoalBase.md delete mode 100644 docs/GoalCompact.md delete mode 100644 docs/GoalGidAddFollowersBody.md delete mode 100644 docs/GoalGidAddSupportingRelationshipBody.md delete mode 100644 docs/GoalGidRemoveFollowersBody.md delete mode 100644 docs/GoalGidRemoveSupportingRelationshipBody.md delete mode 100644 docs/GoalGidSetMetricBody.md delete mode 100644 docs/GoalGidSetMetricCurrentValueBody.md delete mode 100644 docs/GoalMembershipBase.md delete mode 100644 docs/GoalMembershipBaseGoal.md delete mode 100644 docs/GoalMembershipCompact.md delete mode 100644 docs/GoalMembershipResponse.md delete mode 100644 docs/GoalMembershipResponseUser.md delete mode 100644 docs/GoalMembershipResponseWorkspace.md delete mode 100644 docs/GoalMetricBase.md delete mode 100644 docs/GoalMetricCurrentValueRequest.md delete mode 100644 docs/GoalMetricRequest.md delete mode 100644 docs/GoalRelationshipBase.md delete mode 100644 docs/GoalRelationshipBaseSupportedGoal.md delete mode 100644 docs/GoalRelationshipBaseSupportingResource.md delete mode 100644 docs/GoalRelationshipCompact.md delete mode 100644 docs/GoalRelationshipRequest.md delete mode 100644 docs/GoalRelationshipResponse.md delete mode 100644 docs/GoalRelationshipResponseArray.md delete mode 100644 docs/GoalRelationshipResponseData.md delete mode 100644 docs/GoalRelationshipsApi.md delete mode 100644 docs/GoalRelationshipsApi.yaml delete mode 100644 docs/GoalRelationshipsGoalRelationshipGidBody.md delete mode 100644 docs/GoalRemoveSubgoalRequest.md delete mode 100644 docs/GoalRemoveSupportingRelationshipRequest.md delete mode 100644 docs/GoalRequest.md delete mode 100644 docs/GoalRequestBase.md delete mode 100644 docs/GoalResponse.md delete mode 100644 docs/GoalResponseArray.md delete mode 100644 docs/GoalResponseCurrentStatusUpdate.md delete mode 100644 docs/GoalResponseData.md delete mode 100644 docs/GoalResponseLikes.md delete mode 100644 docs/GoalResponseMetric.md delete mode 100644 docs/GoalResponseTeam.md delete mode 100644 docs/GoalResponseTimePeriod.md delete mode 100644 docs/GoalResponseWorkspace.md delete mode 100644 docs/GoalUpdateRequest.md delete mode 100644 docs/GoalsApi.md delete mode 100644 docs/GoalsApi.yaml delete mode 100644 docs/GoalsBody.md delete mode 100644 docs/GoalsGoalGidBody.md delete mode 100644 docs/InlineResponse412.md delete mode 100644 docs/InlineResponse412Errors.md delete mode 100644 docs/JobBase.md delete mode 100644 docs/JobBaseNewProject.md delete mode 100644 docs/JobBaseNewProjectTemplate.md delete mode 100644 docs/JobBaseNewTask.md delete mode 100644 docs/JobCompact.md delete mode 100644 docs/JobResponse.md delete mode 100644 docs/JobResponseData.md delete mode 100644 docs/JobsApi.md delete mode 100644 docs/JobsApi.yaml delete mode 100644 docs/Like.md delete mode 100644 docs/MemberCompact.md delete mode 100644 docs/MembershipCompact.md delete mode 100644 docs/MembershipCompactGoal.md delete mode 100644 docs/MembershipCompactMember.md delete mode 100644 docs/MembershipCompactParent.md delete mode 100644 docs/MembershipRequest.md delete mode 100644 docs/MembershipResponse.md delete mode 100644 docs/MembershipResponseArray.md delete mode 100644 docs/MembershipResponseData.md delete mode 100644 docs/MembershipsApi.md delete mode 100644 docs/MembershipsApi.yaml delete mode 100644 docs/MembershipsBody.md delete mode 100644 docs/ModifyDependenciesRequest.md delete mode 100644 docs/ModifyDependentsRequest.md delete mode 100644 docs/NextPage.md delete mode 100644 docs/OrganizationExportBase.md delete mode 100644 docs/OrganizationExportCompact.md delete mode 100644 docs/OrganizationExportRequest.md delete mode 100644 docs/OrganizationExportResponse.md delete mode 100644 docs/OrganizationExportResponseData.md delete mode 100644 docs/OrganizationExportsApi.md delete mode 100644 docs/OrganizationExportsApi.yaml delete mode 100644 docs/OrganizationExportsBody.md delete mode 100644 docs/PortfolioAddItemRequest.md delete mode 100644 docs/PortfolioBase.md delete mode 100644 docs/PortfolioCompact.md delete mode 100644 docs/PortfolioGidAddCustomFieldSettingBody.md delete mode 100644 docs/PortfolioGidAddItemBody.md delete mode 100644 docs/PortfolioGidAddMembersBody.md delete mode 100644 docs/PortfolioGidRemoveCustomFieldSettingBody.md delete mode 100644 docs/PortfolioGidRemoveItemBody.md delete mode 100644 docs/PortfolioGidRemoveMembersBody.md delete mode 100644 docs/PortfolioMembershipBase.md delete mode 100644 docs/PortfolioMembershipBasePortfolio.md delete mode 100644 docs/PortfolioMembershipCompact.md delete mode 100644 docs/PortfolioMembershipResponse.md delete mode 100644 docs/PortfolioMembershipResponseArray.md delete mode 100644 docs/PortfolioMembershipResponseData.md delete mode 100644 docs/PortfolioMembershipsApi.md delete mode 100644 docs/PortfolioMembershipsApi.yaml delete mode 100644 docs/PortfolioRemoveItemRequest.md delete mode 100644 docs/PortfolioRequest.md delete mode 100644 docs/PortfolioResponse.md delete mode 100644 docs/PortfolioResponseArray.md delete mode 100644 docs/PortfolioResponseCurrentStatusUpdate.md delete mode 100644 docs/PortfolioResponseCustomFieldSettings.md delete mode 100644 docs/PortfolioResponseCustomFields.md delete mode 100644 docs/PortfolioResponseData.md delete mode 100644 docs/PortfolioResponseWorkspace.md delete mode 100644 docs/PortfoliosApi.md delete mode 100644 docs/PortfoliosApi.yaml delete mode 100644 docs/PortfoliosBody.md delete mode 100644 docs/PortfoliosPortfolioGidBody.md delete mode 100644 docs/Preview.md delete mode 100644 docs/ProjectBase.md delete mode 100644 docs/ProjectBaseCurrentStatus.md delete mode 100644 docs/ProjectBaseCurrentStatusUpdate.md delete mode 100644 docs/ProjectBaseWorkspace.md delete mode 100644 docs/ProjectBriefBase.md delete mode 100644 docs/ProjectBriefCompact.md delete mode 100644 docs/ProjectBriefRequest.md delete mode 100644 docs/ProjectBriefResponse.md delete mode 100644 docs/ProjectBriefResponseData.md delete mode 100644 docs/ProjectBriefResponseProject.md delete mode 100644 docs/ProjectBriefsApi.md delete mode 100644 docs/ProjectBriefsApi.yaml delete mode 100644 docs/ProjectBriefsProjectBriefGidBody.md delete mode 100644 docs/ProjectCompact.md delete mode 100644 docs/ProjectDuplicateRequest.md delete mode 100644 docs/ProjectDuplicateRequestScheduleDates.md delete mode 100644 docs/ProjectGidAddCustomFieldSettingBody.md delete mode 100644 docs/ProjectGidAddFollowersBody.md delete mode 100644 docs/ProjectGidAddMembersBody.md delete mode 100644 docs/ProjectGidDuplicateBody.md delete mode 100644 docs/ProjectGidProjectBriefsBody.md delete mode 100644 docs/ProjectGidProjectStatusesBody.md delete mode 100644 docs/ProjectGidRemoveCustomFieldSettingBody.md delete mode 100644 docs/ProjectGidRemoveFollowersBody.md delete mode 100644 docs/ProjectGidRemoveMembersBody.md delete mode 100644 docs/ProjectGidSaveAsTemplateBody.md delete mode 100644 docs/ProjectGidSectionsBody.md delete mode 100644 docs/ProjectMembershipBase.md delete mode 100644 docs/ProjectMembershipCompact.md delete mode 100644 docs/ProjectMembershipCompactArray.md delete mode 100644 docs/ProjectMembershipCompactResponse.md delete mode 100644 docs/ProjectMembershipCompactResponseData.md delete mode 100644 docs/ProjectMembershipNormalResponse.md delete mode 100644 docs/ProjectMembershipNormalResponseData.md delete mode 100644 docs/ProjectMembershipResponse.md delete mode 100644 docs/ProjectMembershipResponseArray.md delete mode 100644 docs/ProjectMembershipResponseData.md delete mode 100644 docs/ProjectMembershipResponseMember.md delete mode 100644 docs/ProjectMembershipsApi.md delete mode 100644 docs/ProjectMembershipsApi.yaml delete mode 100644 docs/ProjectRequest.md delete mode 100644 docs/ProjectResponse.md delete mode 100644 docs/ProjectResponseArray.md delete mode 100644 docs/ProjectResponseCompletedBy.md delete mode 100644 docs/ProjectResponseCreatedFromTemplate.md delete mode 100644 docs/ProjectResponseData.md delete mode 100644 docs/ProjectResponseProjectBrief.md delete mode 100644 docs/ProjectResponseTeam.md delete mode 100644 docs/ProjectResponseWorkspace.md delete mode 100644 docs/ProjectSaveAsTemplateRequest.md delete mode 100644 docs/ProjectSectionInsertRequest.md delete mode 100644 docs/ProjectStatusBase.md delete mode 100644 docs/ProjectStatusCompact.md delete mode 100644 docs/ProjectStatusRequest.md delete mode 100644 docs/ProjectStatusResponse.md delete mode 100644 docs/ProjectStatusResponseArray.md delete mode 100644 docs/ProjectStatusResponseData.md delete mode 100644 docs/ProjectStatusesApi.md delete mode 100644 docs/ProjectStatusesApi.yaml delete mode 100644 docs/ProjectTemplateBase.md delete mode 100644 docs/ProjectTemplateBaseRequestedDates.md delete mode 100644 docs/ProjectTemplateBaseRequestedRoles.md delete mode 100644 docs/ProjectTemplateBaseTeam.md delete mode 100644 docs/ProjectTemplateCompact.md delete mode 100644 docs/ProjectTemplateGidInstantiateProjectBody.md delete mode 100644 docs/ProjectTemplateInstantiateProjectRequest.md delete mode 100644 docs/ProjectTemplateInstantiateProjectRequestRequestedDates.md delete mode 100644 docs/ProjectTemplateInstantiateProjectRequestRequestedRoles.md delete mode 100644 docs/ProjectTemplateResponse.md delete mode 100644 docs/ProjectTemplateResponseArray.md delete mode 100644 docs/ProjectTemplateResponseData.md delete mode 100644 docs/ProjectTemplatesApi.md delete mode 100644 docs/ProjectTemplatesApi.yaml delete mode 100644 docs/ProjectUpdateRequest.md delete mode 100644 docs/ProjectsApi.md delete mode 100644 docs/ProjectsApi.yaml delete mode 100644 docs/ProjectsBody.md delete mode 100644 docs/ProjectsProjectGidBody.md delete mode 100644 docs/RemoveCustomFieldSettingRequest.md delete mode 100644 docs/RemoveFollowersRequest.md delete mode 100644 docs/RemoveMembersRequest.md delete mode 100644 docs/RequestedRoleRequest.md delete mode 100644 docs/RuleTriggerGidRunBody.md delete mode 100644 docs/RuleTriggerRequest.md delete mode 100644 docs/RuleTriggerResponse.md delete mode 100644 docs/RuleTriggerResponseData.md delete mode 100644 docs/RulesApi.md delete mode 100644 docs/RulesApi.yaml delete mode 100644 docs/SectionBase.md delete mode 100644 docs/SectionCompact.md delete mode 100644 docs/SectionGidAddTaskBody.md delete mode 100644 docs/SectionRequest.md delete mode 100644 docs/SectionResponse.md delete mode 100644 docs/SectionResponseArray.md delete mode 100644 docs/SectionResponseData.md delete mode 100644 docs/SectionTaskInsertRequest.md delete mode 100644 docs/SectionsApi.md delete mode 100644 docs/SectionsApi.yaml delete mode 100644 docs/SectionsInsertBody.md delete mode 100644 docs/SectionsSectionGidBody.md delete mode 100644 docs/StatusUpdateBase.md delete mode 100644 docs/StatusUpdateCompact.md delete mode 100644 docs/StatusUpdateRequest.md delete mode 100644 docs/StatusUpdateResponse.md delete mode 100644 docs/StatusUpdateResponseArray.md delete mode 100644 docs/StatusUpdateResponseData.md delete mode 100644 docs/StatusUpdateResponseParent.md delete mode 100644 docs/StatusUpdatesApi.md delete mode 100644 docs/StatusUpdatesApi.yaml delete mode 100644 docs/StatusUpdatesBody.md delete mode 100644 docs/StoriesApi.md delete mode 100644 docs/StoriesApi.yaml delete mode 100644 docs/StoriesStoryGidBody.md delete mode 100644 docs/StoryBase.md delete mode 100644 docs/StoryCompact.md delete mode 100644 docs/StoryRequest.md delete mode 100644 docs/StoryResponse.md delete mode 100644 docs/StoryResponseArray.md delete mode 100644 docs/StoryResponseAssignee.md delete mode 100644 docs/StoryResponseCustomField.md delete mode 100644 docs/StoryResponseData.md delete mode 100644 docs/StoryResponseDates.md delete mode 100644 docs/StoryResponseOldDates.md delete mode 100644 docs/StoryResponseOldEnumValue.md delete mode 100644 docs/StoryResponseOldSection.md delete mode 100644 docs/StoryResponsePreviews.md delete mode 100644 docs/StoryResponseProject.md delete mode 100644 docs/StoryResponseStory.md delete mode 100644 docs/StoryResponseTag.md delete mode 100644 docs/StoryResponseTarget.md delete mode 100644 docs/StoryResponseTask.md delete mode 100644 docs/TagBase.md delete mode 100644 docs/TagCompact.md delete mode 100644 docs/TagCreateTagForWorkspaceRequest.md delete mode 100644 docs/TagRequest.md delete mode 100644 docs/TagResponse.md delete mode 100644 docs/TagResponseArray.md delete mode 100644 docs/TagResponseData.md delete mode 100644 docs/TagsApi.md delete mode 100644 docs/TagsApi.yaml delete mode 100644 docs/TagsBody.md delete mode 100644 docs/TaskAddFollowersRequest.md delete mode 100644 docs/TaskAddProjectRequest.md delete mode 100644 docs/TaskAddTagRequest.md delete mode 100644 docs/TaskBase.md delete mode 100644 docs/TaskBaseCompletedBy.md delete mode 100644 docs/TaskBaseDependencies.md delete mode 100644 docs/TaskBaseExternal.md delete mode 100644 docs/TaskBaseMemberships.md delete mode 100644 docs/TaskBaseSection.md delete mode 100644 docs/TaskCompact.md delete mode 100644 docs/TaskCountResponse.md delete mode 100644 docs/TaskCountResponseData.md delete mode 100644 docs/TaskDuplicateRequest.md delete mode 100644 docs/TaskGidAddDependenciesBody.md delete mode 100644 docs/TaskGidAddDependentsBody.md delete mode 100644 docs/TaskGidAddFollowersBody.md delete mode 100644 docs/TaskGidAddProjectBody.md delete mode 100644 docs/TaskGidAddTagBody.md delete mode 100644 docs/TaskGidDuplicateBody.md delete mode 100644 docs/TaskGidRemoveDependenciesBody.md delete mode 100644 docs/TaskGidRemoveDependentsBody.md delete mode 100644 docs/TaskGidRemoveFollowersBody.md delete mode 100644 docs/TaskGidRemoveProjectBody.md delete mode 100644 docs/TaskGidRemoveTagBody.md delete mode 100644 docs/TaskGidSetParentBody.md delete mode 100644 docs/TaskGidStoriesBody.md delete mode 100644 docs/TaskGidSubtasksBody.md delete mode 100644 docs/TaskGidTimeTrackingEntriesBody.md delete mode 100644 docs/TaskRemoveFollowersRequest.md delete mode 100644 docs/TaskRemoveProjectRequest.md delete mode 100644 docs/TaskRemoveTagRequest.md delete mode 100644 docs/TaskRequest.md delete mode 100644 docs/TaskResponse.md delete mode 100644 docs/TaskResponseArray.md delete mode 100644 docs/TaskResponseAssigneeSection.md delete mode 100644 docs/TaskResponseCustomFields.md delete mode 100644 docs/TaskResponseData.md delete mode 100644 docs/TaskResponseParent.md delete mode 100644 docs/TaskResponseTags.md delete mode 100644 docs/TaskResponseWorkspace.md delete mode 100644 docs/TaskSetParentRequest.md delete mode 100644 docs/TaskTemplateBase.md delete mode 100644 docs/TaskTemplateCompact.md delete mode 100644 docs/TaskTemplateGidInstantiateTaskBody.md delete mode 100644 docs/TaskTemplateInstantiateTaskRequest.md delete mode 100644 docs/TaskTemplateRecipe.md delete mode 100644 docs/TaskTemplateRecipeAttachments.md delete mode 100644 docs/TaskTemplateRecipeCompact.md delete mode 100644 docs/TaskTemplateRecipeDependencies.md delete mode 100644 docs/TaskTemplateResponse.md delete mode 100644 docs/TaskTemplateResponseArray.md delete mode 100644 docs/TaskTemplateResponseData.md delete mode 100644 docs/TaskTemplatesApi.md delete mode 100644 docs/TaskTemplatesApi.yaml delete mode 100644 docs/TasksApi.md delete mode 100644 docs/TasksApi.yaml delete mode 100644 docs/TasksBody.md delete mode 100644 docs/TasksTaskGidBody.md delete mode 100644 docs/TeamAddUserRequest.md delete mode 100644 docs/TeamBase.md delete mode 100644 docs/TeamCompact.md delete mode 100644 docs/TeamGidAddUserBody.md delete mode 100644 docs/TeamGidProjectsBody.md delete mode 100644 docs/TeamGidRemoveUserBody.md delete mode 100644 docs/TeamMembershipBase.md delete mode 100644 docs/TeamMembershipCompact.md delete mode 100644 docs/TeamMembershipResponse.md delete mode 100644 docs/TeamMembershipResponseArray.md delete mode 100644 docs/TeamMembershipResponseData.md delete mode 100644 docs/TeamMembershipsApi.md delete mode 100644 docs/TeamMembershipsApi.yaml delete mode 100644 docs/TeamRemoveUserRequest.md delete mode 100644 docs/TeamRequest.md delete mode 100644 docs/TeamResponse.md delete mode 100644 docs/TeamResponseArray.md delete mode 100644 docs/TeamResponseData.md delete mode 100644 docs/TeamResponseOrganization.md delete mode 100644 docs/TeamsApi.md delete mode 100644 docs/TeamsApi.yaml delete mode 100644 docs/TeamsBody.md delete mode 100644 docs/TeamsTeamGidBody.md delete mode 100644 docs/TemplateRole.md delete mode 100644 docs/TimePeriodBase.md delete mode 100644 docs/TimePeriodCompact.md delete mode 100644 docs/TimePeriodResponse.md delete mode 100644 docs/TimePeriodResponseArray.md delete mode 100644 docs/TimePeriodResponseData.md delete mode 100644 docs/TimePeriodsApi.md delete mode 100644 docs/TimePeriodsApi.yaml delete mode 100644 docs/TimeTrackingEntriesApi.md delete mode 100644 docs/TimeTrackingEntriesApi.yaml delete mode 100644 docs/TimeTrackingEntriesTimeTrackingEntryGidBody.md delete mode 100644 docs/TimeTrackingEntryBase.md delete mode 100644 docs/TimeTrackingEntryBaseData.md delete mode 100644 docs/TimeTrackingEntryCompact.md delete mode 100644 docs/TimeTrackingEntryCompactArray.md delete mode 100644 docs/TypeaheadApi.md delete mode 100644 docs/TypeaheadApi.yaml delete mode 100644 docs/UpdateTimeTrackingEntryRequest.md delete mode 100644 docs/UserBase.md delete mode 100644 docs/UserBaseResponse.md delete mode 100644 docs/UserBaseResponseData.md delete mode 100644 docs/UserBaseResponsePhoto.md delete mode 100644 docs/UserCompact.md delete mode 100644 docs/UserRequest.md delete mode 100644 docs/UserResponse.md delete mode 100644 docs/UserResponseArray.md delete mode 100644 docs/UserResponseData.md delete mode 100644 docs/UserTaskListBase.md delete mode 100644 docs/UserTaskListCompact.md delete mode 100644 docs/UserTaskListRequest.md delete mode 100644 docs/UserTaskListResponse.md delete mode 100644 docs/UserTaskListResponseData.md delete mode 100644 docs/UserTaskListsApi.md delete mode 100644 docs/UserTaskListsApi.yaml delete mode 100644 docs/UsersApi.md delete mode 100644 docs/UsersApi.yaml delete mode 100644 docs/WebhookCompact.md delete mode 100644 docs/WebhookCompactResource.md delete mode 100644 docs/WebhookFilter.md delete mode 100644 docs/WebhookRequest.md delete mode 100644 docs/WebhookRequestFilters.md delete mode 100644 docs/WebhookResponse.md delete mode 100644 docs/WebhookResponseArray.md delete mode 100644 docs/WebhookResponseData.md delete mode 100644 docs/WebhookUpdateRequest.md delete mode 100644 docs/WebhooksApi.md delete mode 100644 docs/WebhooksApi.yaml delete mode 100644 docs/WebhooksBody.md delete mode 100644 docs/WebhooksWebhookGidBody.md delete mode 100644 docs/WorkspaceAddUserRequest.md delete mode 100644 docs/WorkspaceBase.md delete mode 100644 docs/WorkspaceCompact.md delete mode 100644 docs/WorkspaceGidAddUserBody.md delete mode 100644 docs/WorkspaceGidProjectsBody.md delete mode 100644 docs/WorkspaceGidRemoveUserBody.md delete mode 100644 docs/WorkspaceGidTagsBody.md delete mode 100644 docs/WorkspaceMembershipBase.md delete mode 100644 docs/WorkspaceMembershipCompact.md delete mode 100644 docs/WorkspaceMembershipRequest.md delete mode 100644 docs/WorkspaceMembershipResponse.md delete mode 100644 docs/WorkspaceMembershipResponseArray.md delete mode 100644 docs/WorkspaceMembershipResponseData.md delete mode 100644 docs/WorkspaceMembershipResponseUserTaskList.md delete mode 100644 docs/WorkspaceMembershipResponseVacationDates.md delete mode 100644 docs/WorkspaceMembershipsApi.md delete mode 100644 docs/WorkspaceMembershipsApi.yaml delete mode 100644 docs/WorkspaceRemoveUserRequest.md delete mode 100644 docs/WorkspaceRequest.md delete mode 100644 docs/WorkspaceResponse.md delete mode 100644 docs/WorkspaceResponseArray.md delete mode 100644 docs/WorkspaceResponseData.md delete mode 100644 docs/WorkspacesApi.md delete mode 100644 docs/WorkspacesApi.yaml delete mode 100644 docs/WorkspacesWorkspaceGidBody.md create mode 100644 examples/example-create-task.py create mode 100644 examples/example-script.py create mode 100644 examples/example-server.py create mode 100755 examples/example-summary-task.py delete mode 100644 git_push.sh create mode 100644 samples/attachments_sample.yaml create mode 100644 samples/audit_log_api_sample.yaml create mode 100644 samples/batch_api_sample.yaml create mode 100644 samples/custom_field_settings_sample.yaml create mode 100644 samples/custom_fields_sample.yaml create mode 100644 samples/events_sample.yaml create mode 100644 samples/goal_relationships_sample.yaml create mode 100644 samples/goals_sample.yaml create mode 100644 samples/jobs_sample.yaml create mode 100644 samples/memberships_sample.yaml create mode 100644 samples/message_sample.yaml create mode 100644 samples/organization_exports_sample.yaml create mode 100644 samples/portfolio_memberships_sample.yaml create mode 100644 samples/portfolios_sample.yaml create mode 100644 samples/project_briefs_sample.yaml create mode 100644 samples/project_memberships_sample.yaml create mode 100644 samples/project_statuses_sample.yaml create mode 100644 samples/project_templates_sample.yaml create mode 100644 samples/projects_sample.yaml create mode 100644 samples/sections_sample.yaml create mode 100644 samples/status_updates_sample.yaml create mode 100644 samples/stories_sample.yaml create mode 100644 samples/tags_sample.yaml create mode 100644 samples/tasks_sample.yaml create mode 100644 samples/team_memberships_sample.yaml create mode 100644 samples/teams_sample.yaml create mode 100644 samples/time_periods_sample.yaml create mode 100644 samples/typeahead_sample.yaml create mode 100644 samples/user_task_lists_sample.yaml create mode 100644 samples/users_sample.yaml create mode 100644 samples/webhooks_sample.yaml create mode 100644 samples/workspace_memberships_sample.yaml create mode 100644 samples/workspaces_sample.yaml create mode 100644 setup.cfg mode change 100644 => 100755 setup.py create mode 100644 swagger_templates/api.mustache create mode 100644 swagger_templates/api_doc.mustache create mode 100644 swagger_templates/python-config.json delete mode 100644 test-requirements.txt delete mode 100644 test/__init__.py delete mode 100644 test/test_add_custom_field_setting_request.py delete mode 100644 test/test_add_followers_request.py delete mode 100644 test/test_add_members_request.py delete mode 100644 test/test_all_of_project_response_owner.py delete mode 100644 test/test_all_of_project_template_base_owner.py delete mode 100644 test/test_all_of_project_template_response_owner.py delete mode 100644 test/test_all_of_story_response_new_date_value.py delete mode 100644 test/test_all_of_story_response_old_date_value.py delete mode 100644 test/test_all_of_task_template_response_created_by.py delete mode 100644 test/test_all_of_task_template_response_project.py delete mode 100644 test/test_all_of_task_template_response_template.py delete mode 100644 test/test_all_of_user_task_list_base_owner.py delete mode 100644 test/test_all_of_user_task_list_base_workspace.py delete mode 100644 test/test_all_of_user_task_list_compact_owner.py delete mode 100644 test/test_all_of_user_task_list_compact_workspace.py delete mode 100644 test/test_all_of_user_task_list_request_owner.py delete mode 100644 test/test_all_of_user_task_list_request_workspace.py delete mode 100644 test/test_all_of_user_task_list_response_owner.py delete mode 100644 test/test_all_of_user_task_list_response_workspace.py delete mode 100644 test/test_all_of_workspace_membership_response_user_task_list_owner.py delete mode 100644 test/test_all_of_workspace_membership_response_user_task_list_workspace.py delete mode 100644 test/test_asana_named_resource.py delete mode 100644 test/test_asana_named_resource_array.py delete mode 100644 test/test_asana_resource.py delete mode 100644 test/test_attachment_base.py delete mode 100644 test/test_attachment_compact.py delete mode 100644 test/test_attachment_request.py delete mode 100644 test/test_attachment_response.py delete mode 100644 test/test_attachment_response_array.py delete mode 100644 test/test_attachment_response_data.py delete mode 100644 test/test_attachment_response_parent.py delete mode 100644 test/test_attachment_response_parent_created_by.py delete mode 100644 test/test_attachments_api.py delete mode 100644 test/test_audit_log_api_api.py delete mode 100644 test/test_audit_log_event.py delete mode 100644 test/test_audit_log_event_actor.py delete mode 100644 test/test_audit_log_event_array.py delete mode 100644 test/test_audit_log_event_context.py delete mode 100644 test/test_audit_log_event_details.py delete mode 100644 test/test_audit_log_event_resource.py delete mode 100644 test/test_batch_api_api.py delete mode 100644 test/test_batch_body.py delete mode 100644 test/test_batch_request.py delete mode 100644 test/test_batch_request_action.py delete mode 100644 test/test_batch_request_actions.py delete mode 100644 test/test_batch_request_options.py delete mode 100644 test/test_batch_response.py delete mode 100644 test/test_batch_response_array.py delete mode 100644 test/test_create_membership_request.py delete mode 100644 test/test_create_time_tracking_entry_request.py delete mode 100644 test/test_custom_field_base.py delete mode 100644 test/test_custom_field_base_date_value.py delete mode 100644 test/test_custom_field_base_enum_options.py delete mode 100644 test/test_custom_field_base_enum_value.py delete mode 100644 test/test_custom_field_compact.py delete mode 100644 test/test_custom_field_gid_enum_options_body.py delete mode 100644 test/test_custom_field_request.py delete mode 100644 test/test_custom_field_response.py delete mode 100644 test/test_custom_field_response_array.py delete mode 100644 test/test_custom_field_response_created_by.py delete mode 100644 test/test_custom_field_response_data.py delete mode 100644 test/test_custom_field_response_people_value.py delete mode 100644 test/test_custom_field_setting_base.py delete mode 100644 test/test_custom_field_setting_compact.py delete mode 100644 test/test_custom_field_setting_response.py delete mode 100644 test/test_custom_field_setting_response_array.py delete mode 100644 test/test_custom_field_setting_response_custom_field.py delete mode 100644 test/test_custom_field_setting_response_data.py delete mode 100644 test/test_custom_field_setting_response_parent.py delete mode 100644 test/test_custom_field_setting_response_project.py delete mode 100644 test/test_custom_field_settings_api.py delete mode 100644 test/test_custom_fields_api.py delete mode 100644 test/test_custom_fields_body.py delete mode 100644 test/test_custom_fields_custom_field_gid_body.py delete mode 100644 test/test_date_variable_compact.py delete mode 100644 test/test_date_variable_request.py delete mode 100644 test/test_empty_response.py delete mode 100644 test/test_empty_response_data.py delete mode 100644 test/test_enum_option.py delete mode 100644 test/test_enum_option_base.py delete mode 100644 test/test_enum_option_data.py delete mode 100644 test/test_enum_option_insert_request.py delete mode 100644 test/test_enum_option_request.py delete mode 100644 test/test_enum_options_enum_option_gid_body.py delete mode 100644 test/test_enum_options_insert_body.py delete mode 100644 test/test_error.py delete mode 100644 test/test_error_response.py delete mode 100644 test/test_error_response_errors.py delete mode 100644 test/test_event_response.py delete mode 100644 test/test_event_response_array.py delete mode 100644 test/test_event_response_change.py delete mode 100644 test/test_event_response_parent.py delete mode 100644 test/test_event_response_resource.py delete mode 100644 test/test_event_response_user.py delete mode 100644 test/test_events_api.py delete mode 100644 test/test_goal_add_subgoal_request.py delete mode 100644 test/test_goal_add_supporting_relationship_request.py delete mode 100644 test/test_goal_add_supporting_work_request.py delete mode 100644 test/test_goal_base.py delete mode 100644 test/test_goal_compact.py delete mode 100644 test/test_goal_gid_add_followers_body.py delete mode 100644 test/test_goal_gid_add_supporting_relationship_body.py delete mode 100644 test/test_goal_gid_remove_followers_body.py delete mode 100644 test/test_goal_gid_remove_supporting_relationship_body.py delete mode 100644 test/test_goal_gid_set_metric_body.py delete mode 100644 test/test_goal_gid_set_metric_current_value_body.py delete mode 100644 test/test_goal_membership_base.py delete mode 100644 test/test_goal_membership_base_goal.py delete mode 100644 test/test_goal_membership_compact.py delete mode 100644 test/test_goal_membership_response.py delete mode 100644 test/test_goal_membership_response_user.py delete mode 100644 test/test_goal_membership_response_workspace.py delete mode 100644 test/test_goal_metric_base.py delete mode 100644 test/test_goal_metric_current_value_request.py delete mode 100644 test/test_goal_metric_request.py delete mode 100644 test/test_goal_relationship_base.py delete mode 100644 test/test_goal_relationship_base_supported_goal.py delete mode 100644 test/test_goal_relationship_base_supporting_resource.py delete mode 100644 test/test_goal_relationship_compact.py delete mode 100644 test/test_goal_relationship_request.py delete mode 100644 test/test_goal_relationship_response.py delete mode 100644 test/test_goal_relationship_response_array.py delete mode 100644 test/test_goal_relationship_response_data.py delete mode 100644 test/test_goal_relationships_api.py delete mode 100644 test/test_goal_relationships_goal_relationship_gid_body.py delete mode 100644 test/test_goal_remove_subgoal_request.py delete mode 100644 test/test_goal_remove_supporting_relationship_request.py delete mode 100644 test/test_goal_request.py delete mode 100644 test/test_goal_request_base.py delete mode 100644 test/test_goal_response.py delete mode 100644 test/test_goal_response_array.py delete mode 100644 test/test_goal_response_current_status_update.py delete mode 100644 test/test_goal_response_data.py delete mode 100644 test/test_goal_response_likes.py delete mode 100644 test/test_goal_response_metric.py delete mode 100644 test/test_goal_response_team.py delete mode 100644 test/test_goal_response_time_period.py delete mode 100644 test/test_goal_response_workspace.py delete mode 100644 test/test_goal_update_request.py delete mode 100644 test/test_goals_api.py delete mode 100644 test/test_goals_body.py delete mode 100644 test/test_goals_goal_gid_body.py delete mode 100644 test/test_inline_response412.py delete mode 100644 test/test_inline_response412_errors.py delete mode 100644 test/test_job_base.py delete mode 100644 test/test_job_base_new_project.py delete mode 100644 test/test_job_base_new_project_template.py delete mode 100644 test/test_job_base_new_task.py delete mode 100644 test/test_job_compact.py delete mode 100644 test/test_job_response.py delete mode 100644 test/test_job_response_data.py delete mode 100644 test/test_jobs_api.py delete mode 100644 test/test_like.py delete mode 100644 test/test_member_compact.py delete mode 100644 test/test_membership_compact.py delete mode 100644 test/test_membership_compact_goal.py delete mode 100644 test/test_membership_compact_member.py delete mode 100644 test/test_membership_compact_parent.py delete mode 100644 test/test_membership_request.py delete mode 100644 test/test_membership_response.py delete mode 100644 test/test_membership_response_array.py delete mode 100644 test/test_membership_response_data.py delete mode 100644 test/test_memberships_api.py delete mode 100644 test/test_memberships_body.py delete mode 100644 test/test_modify_dependencies_request.py delete mode 100644 test/test_modify_dependents_request.py delete mode 100644 test/test_next_page.py delete mode 100644 test/test_organization_export_base.py delete mode 100644 test/test_organization_export_compact.py delete mode 100644 test/test_organization_export_request.py delete mode 100644 test/test_organization_export_response.py delete mode 100644 test/test_organization_export_response_data.py delete mode 100644 test/test_organization_exports_api.py delete mode 100644 test/test_organization_exports_body.py delete mode 100644 test/test_portfolio_add_item_request.py delete mode 100644 test/test_portfolio_base.py delete mode 100644 test/test_portfolio_compact.py delete mode 100644 test/test_portfolio_gid_add_custom_field_setting_body.py delete mode 100644 test/test_portfolio_gid_add_item_body.py delete mode 100644 test/test_portfolio_gid_add_members_body.py delete mode 100644 test/test_portfolio_gid_remove_custom_field_setting_body.py delete mode 100644 test/test_portfolio_gid_remove_item_body.py delete mode 100644 test/test_portfolio_gid_remove_members_body.py delete mode 100644 test/test_portfolio_membership_base.py delete mode 100644 test/test_portfolio_membership_base_portfolio.py delete mode 100644 test/test_portfolio_membership_compact.py delete mode 100644 test/test_portfolio_membership_response.py delete mode 100644 test/test_portfolio_membership_response_array.py delete mode 100644 test/test_portfolio_membership_response_data.py delete mode 100644 test/test_portfolio_memberships_api.py delete mode 100644 test/test_portfolio_remove_item_request.py delete mode 100644 test/test_portfolio_request.py delete mode 100644 test/test_portfolio_response.py delete mode 100644 test/test_portfolio_response_array.py delete mode 100644 test/test_portfolio_response_current_status_update.py delete mode 100644 test/test_portfolio_response_custom_field_settings.py delete mode 100644 test/test_portfolio_response_custom_fields.py delete mode 100644 test/test_portfolio_response_data.py delete mode 100644 test/test_portfolio_response_workspace.py delete mode 100644 test/test_portfolios_api.py delete mode 100644 test/test_portfolios_body.py delete mode 100644 test/test_portfolios_portfolio_gid_body.py delete mode 100644 test/test_preview.py delete mode 100644 test/test_project_base.py delete mode 100644 test/test_project_base_current_status.py delete mode 100644 test/test_project_base_current_status_update.py delete mode 100644 test/test_project_base_workspace.py delete mode 100644 test/test_project_brief_base.py delete mode 100644 test/test_project_brief_compact.py delete mode 100644 test/test_project_brief_request.py delete mode 100644 test/test_project_brief_response.py delete mode 100644 test/test_project_brief_response_data.py delete mode 100644 test/test_project_brief_response_project.py delete mode 100644 test/test_project_briefs_api.py delete mode 100644 test/test_project_briefs_project_brief_gid_body.py delete mode 100644 test/test_project_compact.py delete mode 100644 test/test_project_duplicate_request.py delete mode 100644 test/test_project_duplicate_request_schedule_dates.py delete mode 100644 test/test_project_gid_add_custom_field_setting_body.py delete mode 100644 test/test_project_gid_add_followers_body.py delete mode 100644 test/test_project_gid_add_members_body.py delete mode 100644 test/test_project_gid_duplicate_body.py delete mode 100644 test/test_project_gid_project_briefs_body.py delete mode 100644 test/test_project_gid_project_statuses_body.py delete mode 100644 test/test_project_gid_remove_custom_field_setting_body.py delete mode 100644 test/test_project_gid_remove_followers_body.py delete mode 100644 test/test_project_gid_remove_members_body.py delete mode 100644 test/test_project_gid_save_as_template_body.py delete mode 100644 test/test_project_gid_sections_body.py delete mode 100644 test/test_project_membership_base.py delete mode 100644 test/test_project_membership_compact.py delete mode 100644 test/test_project_membership_compact_array.py delete mode 100644 test/test_project_membership_compact_response.py delete mode 100644 test/test_project_membership_compact_response_data.py delete mode 100644 test/test_project_membership_normal_response.py delete mode 100644 test/test_project_membership_normal_response_data.py delete mode 100644 test/test_project_membership_response.py delete mode 100644 test/test_project_membership_response_array.py delete mode 100644 test/test_project_membership_response_data.py delete mode 100644 test/test_project_membership_response_member.py delete mode 100644 test/test_project_memberships_api.py delete mode 100644 test/test_project_request.py delete mode 100644 test/test_project_response.py delete mode 100644 test/test_project_response_array.py delete mode 100644 test/test_project_response_completed_by.py delete mode 100644 test/test_project_response_created_from_template.py delete mode 100644 test/test_project_response_data.py delete mode 100644 test/test_project_response_project_brief.py delete mode 100644 test/test_project_response_team.py delete mode 100644 test/test_project_response_workspace.py delete mode 100644 test/test_project_save_as_template_request.py delete mode 100644 test/test_project_section_insert_request.py delete mode 100644 test/test_project_status_base.py delete mode 100644 test/test_project_status_compact.py delete mode 100644 test/test_project_status_request.py delete mode 100644 test/test_project_status_response.py delete mode 100644 test/test_project_status_response_array.py delete mode 100644 test/test_project_status_response_data.py delete mode 100644 test/test_project_statuses_api.py delete mode 100644 test/test_project_template_base.py delete mode 100644 test/test_project_template_base_requested_dates.py delete mode 100644 test/test_project_template_base_requested_roles.py delete mode 100644 test/test_project_template_base_team.py delete mode 100644 test/test_project_template_compact.py delete mode 100644 test/test_project_template_gid_instantiate_project_body.py delete mode 100644 test/test_project_template_instantiate_project_request.py delete mode 100644 test/test_project_template_instantiate_project_request_requested_dates.py delete mode 100644 test/test_project_template_instantiate_project_request_requested_roles.py delete mode 100644 test/test_project_template_response.py delete mode 100644 test/test_project_template_response_array.py delete mode 100644 test/test_project_template_response_data.py delete mode 100644 test/test_project_templates_api.py delete mode 100644 test/test_project_update_request.py delete mode 100644 test/test_projects_api.py delete mode 100644 test/test_projects_body.py delete mode 100644 test/test_projects_project_gid_body.py delete mode 100644 test/test_remove_custom_field_setting_request.py delete mode 100644 test/test_remove_followers_request.py delete mode 100644 test/test_remove_members_request.py delete mode 100644 test/test_requested_role_request.py delete mode 100644 test/test_rule_trigger_gid_run_body.py delete mode 100644 test/test_rule_trigger_request.py delete mode 100644 test/test_rule_trigger_response.py delete mode 100644 test/test_rule_trigger_response_data.py delete mode 100644 test/test_rules_api.py delete mode 100644 test/test_section_base.py delete mode 100644 test/test_section_compact.py delete mode 100644 test/test_section_gid_add_task_body.py delete mode 100644 test/test_section_request.py delete mode 100644 test/test_section_response.py delete mode 100644 test/test_section_response_array.py delete mode 100644 test/test_section_response_data.py delete mode 100644 test/test_section_task_insert_request.py delete mode 100644 test/test_sections_api.py delete mode 100644 test/test_sections_insert_body.py delete mode 100644 test/test_sections_section_gid_body.py delete mode 100644 test/test_status_update_base.py delete mode 100644 test/test_status_update_compact.py delete mode 100644 test/test_status_update_request.py delete mode 100644 test/test_status_update_response.py delete mode 100644 test/test_status_update_response_array.py delete mode 100644 test/test_status_update_response_data.py delete mode 100644 test/test_status_update_response_parent.py delete mode 100644 test/test_status_updates_api.py delete mode 100644 test/test_status_updates_body.py delete mode 100644 test/test_stories_api.py delete mode 100644 test/test_stories_story_gid_body.py delete mode 100644 test/test_story_base.py delete mode 100644 test/test_story_compact.py delete mode 100644 test/test_story_request.py delete mode 100644 test/test_story_response.py delete mode 100644 test/test_story_response_array.py delete mode 100644 test/test_story_response_assignee.py delete mode 100644 test/test_story_response_custom_field.py delete mode 100644 test/test_story_response_data.py delete mode 100644 test/test_story_response_dates.py delete mode 100644 test/test_story_response_old_dates.py delete mode 100644 test/test_story_response_old_enum_value.py delete mode 100644 test/test_story_response_old_section.py delete mode 100644 test/test_story_response_previews.py delete mode 100644 test/test_story_response_project.py delete mode 100644 test/test_story_response_story.py delete mode 100644 test/test_story_response_tag.py delete mode 100644 test/test_story_response_target.py delete mode 100644 test/test_story_response_task.py delete mode 100644 test/test_tag_base.py delete mode 100644 test/test_tag_compact.py delete mode 100644 test/test_tag_create_tag_for_workspace_request.py delete mode 100644 test/test_tag_request.py delete mode 100644 test/test_tag_response.py delete mode 100644 test/test_tag_response_array.py delete mode 100644 test/test_tag_response_data.py delete mode 100644 test/test_tags_api.py delete mode 100644 test/test_tags_body.py delete mode 100644 test/test_task_add_followers_request.py delete mode 100644 test/test_task_add_project_request.py delete mode 100644 test/test_task_add_tag_request.py delete mode 100644 test/test_task_base.py delete mode 100644 test/test_task_base_completed_by.py delete mode 100644 test/test_task_base_dependencies.py delete mode 100644 test/test_task_base_external.py delete mode 100644 test/test_task_base_memberships.py delete mode 100644 test/test_task_base_section.py delete mode 100644 test/test_task_compact.py delete mode 100644 test/test_task_count_response.py delete mode 100644 test/test_task_count_response_data.py delete mode 100644 test/test_task_duplicate_request.py delete mode 100644 test/test_task_gid_add_dependencies_body.py delete mode 100644 test/test_task_gid_add_dependents_body.py delete mode 100644 test/test_task_gid_add_followers_body.py delete mode 100644 test/test_task_gid_add_project_body.py delete mode 100644 test/test_task_gid_add_tag_body.py delete mode 100644 test/test_task_gid_duplicate_body.py delete mode 100644 test/test_task_gid_remove_dependencies_body.py delete mode 100644 test/test_task_gid_remove_dependents_body.py delete mode 100644 test/test_task_gid_remove_followers_body.py delete mode 100644 test/test_task_gid_remove_project_body.py delete mode 100644 test/test_task_gid_remove_tag_body.py delete mode 100644 test/test_task_gid_set_parent_body.py delete mode 100644 test/test_task_gid_stories_body.py delete mode 100644 test/test_task_gid_subtasks_body.py delete mode 100644 test/test_task_gid_time_tracking_entries_body.py delete mode 100644 test/test_task_remove_followers_request.py delete mode 100644 test/test_task_remove_project_request.py delete mode 100644 test/test_task_remove_tag_request.py delete mode 100644 test/test_task_request.py delete mode 100644 test/test_task_response.py delete mode 100644 test/test_task_response_array.py delete mode 100644 test/test_task_response_assignee_section.py delete mode 100644 test/test_task_response_custom_fields.py delete mode 100644 test/test_task_response_data.py delete mode 100644 test/test_task_response_parent.py delete mode 100644 test/test_task_response_tags.py delete mode 100644 test/test_task_response_workspace.py delete mode 100644 test/test_task_set_parent_request.py delete mode 100644 test/test_task_template_base.py delete mode 100644 test/test_task_template_compact.py delete mode 100644 test/test_task_template_gid_instantiate_task_body.py delete mode 100644 test/test_task_template_instantiate_task_request.py delete mode 100644 test/test_task_template_recipe.py delete mode 100644 test/test_task_template_recipe_attachments.py delete mode 100644 test/test_task_template_recipe_compact.py delete mode 100644 test/test_task_template_recipe_dependencies.py delete mode 100644 test/test_task_template_response.py delete mode 100644 test/test_task_template_response_array.py delete mode 100644 test/test_task_template_response_data.py delete mode 100644 test/test_task_templates_api.py delete mode 100644 test/test_tasks_api.py delete mode 100644 test/test_tasks_body.py delete mode 100644 test/test_tasks_task_gid_body.py delete mode 100644 test/test_team_add_user_request.py delete mode 100644 test/test_team_base.py delete mode 100644 test/test_team_compact.py delete mode 100644 test/test_team_gid_add_user_body.py delete mode 100644 test/test_team_gid_projects_body.py delete mode 100644 test/test_team_gid_remove_user_body.py delete mode 100644 test/test_team_membership_base.py delete mode 100644 test/test_team_membership_compact.py delete mode 100644 test/test_team_membership_response.py delete mode 100644 test/test_team_membership_response_array.py delete mode 100644 test/test_team_membership_response_data.py delete mode 100644 test/test_team_memberships_api.py delete mode 100644 test/test_team_remove_user_request.py delete mode 100644 test/test_team_request.py delete mode 100644 test/test_team_response.py delete mode 100644 test/test_team_response_array.py delete mode 100644 test/test_team_response_data.py delete mode 100644 test/test_team_response_organization.py delete mode 100644 test/test_teams_api.py delete mode 100644 test/test_teams_body.py delete mode 100644 test/test_teams_team_gid_body.py delete mode 100644 test/test_template_role.py delete mode 100644 test/test_time_period_base.py delete mode 100644 test/test_time_period_compact.py delete mode 100644 test/test_time_period_response.py delete mode 100644 test/test_time_period_response_array.py delete mode 100644 test/test_time_period_response_data.py delete mode 100644 test/test_time_periods_api.py delete mode 100644 test/test_time_tracking_entries_api.py delete mode 100644 test/test_time_tracking_entries_time_tracking_entry_gid_body.py delete mode 100644 test/test_time_tracking_entry_base.py delete mode 100644 test/test_time_tracking_entry_base_data.py delete mode 100644 test/test_time_tracking_entry_compact.py delete mode 100644 test/test_time_tracking_entry_compact_array.py delete mode 100644 test/test_typeahead_api.py delete mode 100644 test/test_update_time_tracking_entry_request.py delete mode 100644 test/test_user_base.py delete mode 100644 test/test_user_base_response.py delete mode 100644 test/test_user_base_response_data.py delete mode 100644 test/test_user_base_response_photo.py delete mode 100644 test/test_user_compact.py delete mode 100644 test/test_user_request.py delete mode 100644 test/test_user_response.py delete mode 100644 test/test_user_response_array.py delete mode 100644 test/test_user_response_data.py delete mode 100644 test/test_user_task_list_base.py delete mode 100644 test/test_user_task_list_compact.py delete mode 100644 test/test_user_task_list_request.py delete mode 100644 test/test_user_task_list_response.py delete mode 100644 test/test_user_task_list_response_data.py delete mode 100644 test/test_user_task_lists_api.py delete mode 100644 test/test_users_api.py delete mode 100644 test/test_webhook_compact.py delete mode 100644 test/test_webhook_compact_resource.py delete mode 100644 test/test_webhook_filter.py delete mode 100644 test/test_webhook_request.py delete mode 100644 test/test_webhook_request_filters.py delete mode 100644 test/test_webhook_response.py delete mode 100644 test/test_webhook_response_array.py delete mode 100644 test/test_webhook_response_data.py delete mode 100644 test/test_webhook_update_request.py delete mode 100644 test/test_webhooks_api.py delete mode 100644 test/test_webhooks_body.py delete mode 100644 test/test_webhooks_webhook_gid_body.py delete mode 100644 test/test_workspace_add_user_request.py delete mode 100644 test/test_workspace_base.py delete mode 100644 test/test_workspace_compact.py delete mode 100644 test/test_workspace_gid_add_user_body.py delete mode 100644 test/test_workspace_gid_projects_body.py delete mode 100644 test/test_workspace_gid_remove_user_body.py delete mode 100644 test/test_workspace_gid_tags_body.py delete mode 100644 test/test_workspace_membership_base.py delete mode 100644 test/test_workspace_membership_compact.py delete mode 100644 test/test_workspace_membership_request.py delete mode 100644 test/test_workspace_membership_response.py delete mode 100644 test/test_workspace_membership_response_array.py delete mode 100644 test/test_workspace_membership_response_data.py delete mode 100644 test/test_workspace_membership_response_user_task_list.py delete mode 100644 test/test_workspace_membership_response_vacation_dates.py delete mode 100644 test/test_workspace_memberships_api.py delete mode 100644 test/test_workspace_remove_user_request.py delete mode 100644 test/test_workspace_request.py delete mode 100644 test/test_workspace_response.py delete mode 100644 test/test_workspace_response_array.py delete mode 100644 test/test_workspace_response_data.py delete mode 100644 test/test_workspaces_api.py delete mode 100644 test/test_workspaces_workspace_gid_body.py create mode 100644 tests/__init__.py create mode 100644 tests/helpers.py create mode 100644 tests/test_client.py create mode 100644 tests/test_client_attachments.py create mode 100644 tests/test_client_audit_log_api.py create mode 100644 tests/test_client_custom_field_settings.py create mode 100644 tests/test_client_custom_fields.py create mode 100644 tests/test_client_events.py create mode 100644 tests/test_client_jobs.py create mode 100644 tests/test_client_organization_exports.py create mode 100644 tests/test_client_portfolio_memberships.py create mode 100644 tests/test_client_portfolios.py create mode 100644 tests/test_client_projects.py create mode 100644 tests/test_client_sections.py create mode 100644 tests/test_client_stories.py create mode 100644 tests/test_client_tags.py create mode 100644 tests/test_client_tasks.py create mode 100644 tests/test_client_teams.py create mode 100644 tests/test_client_user_task_lists.py create mode 100644 tests/test_client_users.py create mode 100644 tests/test_client_webhooks.py create mode 100644 tests/test_client_workspaces.py create mode 100644 tests/test_errors.py delete mode 100644 tox.ini diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 00000000..196a84ec --- /dev/null +++ b/.dockerignore @@ -0,0 +1,3 @@ +.git +*.pyc +__pycache__ diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 00000000..a7a2389d --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,32 @@ +name: Build + +on: + push: + branches: + - master + pull_request: + branches: + - master + +defaults: + run: + shell: bash + +jobs: + test: + name: pytest + runs-on: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest] + python-version: ['3.7', '3.8', '3.9', '3.10', '3.11'] + steps: + - uses: actions/checkout@v3 + - name: Set up Python + uses: actions/setup-python@v3 + with: + python-version: ${{ matrix.python-version }} + - run: pip install -r requirements.txt + - run: pytest + \ No newline at end of file diff --git a/.github/workflows/publish-to-github-releases.yml b/.github/workflows/publish-to-github-releases.yml new file mode 100644 index 00000000..5e4f6450 --- /dev/null +++ b/.github/workflows/publish-to-github-releases.yml @@ -0,0 +1,17 @@ +name: Publish to GitHub Releases + +on: + push: + tags: + - "v*.*.*" + +jobs: + build-n-publish-to-github: + name: Build and publish to GitHub Releases + runs-on: ubuntu-latest + steps: + - name: Publish to GitHub Releases + uses: softprops/action-gh-release@v1 + with: + # Use the newest commit message as the release description + body: ${{ github.event.head_commit.message }} diff --git a/.github/workflows/publish-to-pypi.yml b/.github/workflows/publish-to-pypi.yml new file mode 100644 index 00000000..c6aa1548 --- /dev/null +++ b/.github/workflows/publish-to-pypi.yml @@ -0,0 +1,42 @@ +name: Publish Python 🐍 distributions 📦 to PyPI and TestPyPI + +on: + release: + types: [published] + push: + tags: + - "v*.*.*" + +jobs: + build-n-publish-to-pypi: + name: Build and publish Python 🐍 distributions 📦 to PyPI and TestPyPI + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Set up Python 3.7 + uses: actions/setup-python@v3 + with: + python-version: 3.7 + - name: Install pypa/build + run: >- + python -m + pip install + build + --user + - name: Build a binary wheel and a source tarball + run: >- + python -m + build + --sdist + --wheel + --outdir dist/ + . + - name: Publish distribution 📦 to Test PyPI + uses: pypa/gh-action-pypi-publish@master + with: + password: ${{ secrets.TEST_PYPI_API_TOKEN }} + repository_url: https://test.pypi.org/legacy/ + - name: Publish distribution 📦 to PyPI + uses: pypa/gh-action-pypi-publish@master + with: + password: ${{ secrets.PYPI_API_TOKEN }} diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml deleted file mode 100644 index 8daf0ba8..00000000 --- a/.github/workflows/publish.yaml +++ /dev/null @@ -1,104 +0,0 @@ -name: Generate client library + Publish 📦 to PyPI + Publish to GitHub Releases - -on: - workflow_dispatch: - inputs: - version: - required: true - -jobs: - generate-python-library: - name: Generate python client library - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-java@v3 - with: - distribution: "temurin" - java-version: "17" - - name: Setup environment variables - run: | - echo "generator_version=3.0.46" >> "$GITHUB_ENV" - echo "generator_name=swagger-codegen-cli.jar" >> "$GITHUB_ENV" - echo "jar_asana=codegen/swagger/target/AsanaClientCodegen-swagger-codegen-1.0.0.jar" >> "$GITHUB_ENV" - echo "actual_lang=com.asana.codegen.PythonClientCodegenGenerator" >> "$GITHUB_ENV" - echo "name=asana" >> "$GITHUB_ENV" - - name: Download generator - run: | - wget -q -O $generator_name https://repo1.maven.org/maven2/io/swagger/codegen/v3/swagger-codegen-cli/${{ env.generator_version }}/swagger-codegen-cli-${{ env.generator_version }}.jar - - name: Build custom code - run: | - pushd codegen/swagger >/dev/null - mvn package - popd >/dev/null - - name: Generate library - run: >- - java -cp "${{ env.jar_asana }}:${{ env.generator_name }}" - io.swagger.codegen.v3.cli.SwaggerCodegen - generate - --input-spec https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_sdk_oas.yaml - --template-dir "codegen/templates" - --lang "${{ env.actual_lang }}" - -DpackageName=${{ env.name }} - --additional-properties "packageVersion=${{ inputs.version }},projectName=${{ env.name }},packageName=${{ env.name }}" - - name: Clean up generator - run: rm -rf codegen/swagger/target ${{ env.generator_name }} - - name: Push changes to master branch - uses: EndBug/add-and-commit@v9 - with: - message: 'Updated Python SDK: v${{ inputs.version }}' - committer_name: GitHub Actions - committer_email: actions@github.com - tag: 'v${{ inputs.version }} --force' - tag_push: '--force' - build-n-publish-to-pypi: - needs: generate-python-library - name: Build and publish Python 🐍 distributions 📦 to PyPI - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - with: - fetch-depth: 0 - ref: master - - name: Set up Python 3.7 - uses: actions/setup-python@v4 - with: - python-version: 3.7 - - name: Install pypa/build - run: >- - python -m - pip install - build - --user - - name: Build a binary wheel and a source tarball - run: >- - python -m - build - --sdist - --wheel - --outdir dist/ - . - - name: Publish distribution 📦 to Test PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - password: ${{ secrets.TEST_PYPI_API_TOKEN }} - repository-url: https://test.pypi.org/legacy/ - - name: Publish distribution 📦 to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - password: ${{ secrets.PYPI_API_TOKEN }} - publish-to-github: - needs: build-n-publish-to-pypi - name: Publish to GitHub Releases - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - with: - fetch-depth: 0 - ref: master - - name: Publish to GitHub Releases - uses: softprops/action-gh-release@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - tag_name: ${{ inputs.version }} diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 00000000..c4fa9d5f --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,87 @@ +name: Bump Version and Publish + +on: + workflow_dispatch: + inputs: + bumpVersion: + description: Choose a version number to bump + required: true + type: choice + options: + - patch + - minor + - major + +jobs: + bump-semantic-versioning: + name: Bump the semantic versioning for the package + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Set up Python 3.7 + uses: actions/setup-python@v4 + with: + python-version: 3.7 + - name: Run deploy script + run: | + git config user.name github-actions + git config user.email github-actions@github.com + python deploy.py ${{ inputs.bumpVersion }} + publish-to-github: + needs: bump-semantic-versioning + name: Publish to GitHub Releases + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + fetch-depth: 0 + ref: master + - name: Get version tag + id: tag + run: echo "version=v$(cat VERSION)" >> $GITHUB_OUTPUT + - name: Print version tag + run: echo ${{ steps.tag.outputs.version }} + - name: Publish to GitHub Releases + uses: softprops/action-gh-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ steps.tag.outputs.version }} + # Use the newest commit message as the release description + body: ${{ github.event.head_commit.message }} + build-n-publish-to-pypi: + needs: [bump-semantic-versioning, publish-to-github] + name: Build and publish Python 🐍 distributions 📦 to PyPI and TestPyPI + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + fetch-depth: 0 + ref: master + - name: Set up Python 3.7 + uses: actions/setup-python@v4 + with: + python-version: 3.7 + - name: Install pypa/build + run: >- + python -m + pip install + build + --user + - name: Build a binary wheel and a source tarball + run: >- + python -m + build + --sdist + --wheel + --outdir dist/ + . + - name: Publish distribution 📦 to Test PyPI + uses: pypa/gh-action-pypi-publish@release/v1 + with: + password: ${{ secrets.TEST_PYPI_API_TOKEN }} + repository_url: https://test.pypi.org/legacy/ + - name: Publish distribution 📦 to PyPI + uses: pypa/gh-action-pypi-publish@master + with: + password: ${{ secrets.PYPI_API_TOKEN }} diff --git a/.gitignore b/.gitignore index a655050c..f6d87f8d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,64 +1,8 @@ -# Byte-compiled / optimized / DLL files -__pycache__/ -*.py[cod] -*$py.class +.idea +/build +/dist +/*.egg-info -# C extensions -*.so - -# Distribution / packaging -.Python -env/ -build/ -develop-eggs/ -dist/ -downloads/ -eggs/ -.eggs/ -lib/ -lib64/ -parts/ -sdist/ -var/ -*.egg-info/ -.installed.cfg -*.egg - -# PyInstaller -# Usually these files are written by a python script from a template -# before PyInstaller builds the exe, so as to inject date/other infos into it. -*.manifest -*.spec - -# Installer logs -pip-log.txt -pip-delete-this-directory.txt - -# Unit test / coverage reports -htmlcov/ -.tox/ -.coverage -.coverage.* +__pycache__ +*.pyc .cache -nosetests.xml -coverage.xml -*,cover -.hypothesis/ -venv/ -.python-version - -# Translations -*.mo -*.pot - -# Django stuff: -*.log - -# Sphinx documentation -docs/_build/ - -# PyBuilder -target/ - -#Ipython Notebook -.ipynb_checkpoints diff --git a/.swagger-codegen-ignore b/.swagger-codegen-ignore index c5fa491b..b0c534d4 100644 --- a/.swagger-codegen-ignore +++ b/.swagger-codegen-ignore @@ -1,23 +1,3 @@ # Swagger Codegen Ignore -# Generated by swagger-codegen https://github.com/swagger-api/swagger-codegen -# Use this file to prevent files from being overwritten by the generator. -# The patterns follow closely to .gitignore or .dockerignore. - -# As an example, the C# client generator defines ApiClient.cs. -# You can make changes and tell Swagger Codgen to ignore just this file by uncommenting the following line: -#ApiClient.cs - -# You can match any string of characters against a directory, file or extension with a single asterisk (*): -#foo/*/qux -# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux - -# You can recursively match patterns against a directory, file or extension with a double asterisk (**): -#foo/**/qux -# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux - -# You can also negate patterns with an exclamation (!). -# For example, you can ignore all files in a docs folder with the file extension .md: -#docs/*.md -# Then explicitly reverse the ignore rule for a single file: -#!docs/README.md +test/* diff --git a/.swagger-codegen/VERSION b/.swagger-codegen/VERSION deleted file mode 100644 index 16176176..00000000 --- a/.swagger-codegen/VERSION +++ /dev/null @@ -1 +0,0 @@ -3.0.46 \ No newline at end of file diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index dd6c4450..00000000 --- a/.travis.yml +++ /dev/null @@ -1,13 +0,0 @@ -# ref: https://docs.travis-ci.com/user/languages/python -language: python -python: - - "3.2" - - "3.3" - - "3.4" - - "3.5" - #- "3.5-dev" # 3.5 development branch - #- "nightly" # points to the latest development branch e.g. 3.6-dev -# command to install dependencies -install: "pip install -r requirements.txt" -# command to run tests -script: nosetests diff --git a/CHANGELOG b/CHANGELOG new file mode 100644 index 00000000..e69de29b diff --git a/CONTRIBUTORS b/CONTRIBUTORS new file mode 100644 index 00000000..e69de29b diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 00000000..345ea0f7 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,20 @@ +FROM python:3 + +WORKDIR /app + +ADD requirements.txt /app/requirements.txt + +RUN pip install -r requirements.txt + +ADD asana /app/asana +ADD examples /app/examples +ADD tests /app/tests +ADD setup.py /app/setup.py +ADD README.md /app/README.md + +RUN find . -name '*.pyc' -delete + +RUN python --version +RUN python -m pytest + +RUN python setup.py bdist_egg diff --git a/MANIFEST.in b/MANIFEST.in new file mode 100644 index 00000000..c83102bf --- /dev/null +++ b/MANIFEST.in @@ -0,0 +1,4 @@ +include LICENSE +include CONTRIBUTORS +include CHANGELOG +include README.md diff --git a/README.md b/README.md index 8c2f0659..e1b215b7 100644 --- a/README.md +++ b/README.md @@ -1,1243 +1,183 @@ -# asana [![GitHub release][release-image]]() [![Build][github-actions-image]][github-actions-url] [![PyPi Version][pypi-image]][pypi-url] - -Python client library for Asana - -- API version: 1.0 -- Package version: 4.0.11 - -## Requirements. - -Python 3.4+ - -## Installation & Usage -### pip install from [PyPI](https://pypi.org/project/asana/) - -```sh -pip install asana -``` - -Then import the package: -```python -import asana -``` - -### Setuptools - -Install via [Setuptools](http://pypi.python.org/pypi/setuptools). - -```sh -python setup.py install --user -``` -(or `sudo python setup.py install` to install the package for all users) - -Then import the package: -```python -import asana -``` - -## Getting Started - -Please follow the [installation procedure](#installation--usage) and then run the following: - -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -users_api_instance = asana.UsersApi(api_client) -user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. -opt_fields = ["email","name","photo","photo.image_1024x1024","photo.image_128x128","photo.image_21x21","photo.image_27x27","photo.image_36x36","photo.image_60x60","workspaces","workspaces.name"] # list[str] | Properties to include in the response. Set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a user - api_response = users_api_instance.get_user(user_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling UsersApi->get_user: %s\n" % e) -``` - -### Example: GET, POST, PUT, DELETE on tasks - -#### GET - get multiple tasks -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -tasks_api_instance = asana.TasksApi(api_client) -limit = 50 -project = "" -opt_fields = [ - "assignee_section", - "due_at", - "name", - "completed_at", - "completed_by", - "tags", - "dependents", - "hearts", - "liked", - "projects", - "completed", - "num_hearts", - "permalink_url", - "parent", - "assignee", - "assignee_status", - "num_subtasks", - "start_on", - "dependencies", - "is_rendered_as_separator", - "modified_at", - "approval_status", - "notes", - "memberships", - "workspace", - "due_on", - "hearted", - "created_at", - "likes", - "num_likes", - "custom_fields", - "external", - "html_notes", - "followers", - "start_at", - "resource_subtype", - "actual_time_minutes", -] - -try: - # GET - get multiple tasks - api_response = tasks_api_instance.get_tasks( - limit=limit, project=project, opt_fields=opt_fields +# asana [![Build][github-actions-image]][github-actions-url] [![PyPi Version][pypi-image]][pypi-url] + +> **Warning** +> Python client library version `>4.X.X` is currently in BETA and subject to change. Please use v3.2.X for stable / production environments `pip install asana` or `pip install asana==3.2.2`. If you have feedback on the new version, please your feedback [here](https://form.asana.com/?k=C4sELCq6hAUsoWEY0kJwAA&d=15793206719). + +> You can try out our new python beta by installing version [v4.0.11](https://github.com/Asana/python-asana/tree/v4.0.11) (`pip install asana==4.0.11`) + +Python client library for Asana. + +Authentication +-------------- + +### Personal Access Token + +Create a client using your Asana Personal Access Token: + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + +### OAuth 2 + +Asana supports OAuth 2. `asana` handles some of the details of the OAuth flow for you. + +Create a client using your OAuth Client ID and secret: + + client = asana.Client.oauth( + client_id='ASANA_CLIENT_ID', + client_secret='ASANA_CLIENT_SECRET', + redirect_uri='https://yourapp.com/auth/asana/callback' ) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->get_tasks: %s\n" % e) -``` - -#### POST - create a task -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -tasks_api_instance = asana.TasksApi(api_client) -body = asana.TasksBody( - { - "name": "New Task", - "projects": [""], - } -) - -try: - # POST - create a task - api_response = tasks_api_instance.create_task(body) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->create_task: %s\n" % e) -``` - -#### PUT - update a task -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -tasks_api_instance = asana.TasksApi(api_client) -task_gid = "" -body = asana.TasksBody( - { - "name": "Updated Task", - } -) - -try: - # PUT - update a task - api_response = tasks_api_instance.update_task(body, task_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->update_task: %s\n" % e) -``` - -#### DELETE - delete a task -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -tasks_api_instance = asana.TasksApi(api_client) -task_gid = "" - -try: - # DELETE - delete a task - api_response = tasks_api_instance.delete_task(task_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->delete_task: %s\n" % e) -``` - -## Documentation for API Endpoints - -All URIs are relative to *https://app.asana.com/api/1.0* - -Class | Method | HTTP request | Description ------------- | ------------- | ------------- | ------------- -*AttachmentsApi* | [**create_attachment_for_object**](docs/AttachmentsApi.md#create_attachment_for_object) | **POST** /attachments | Upload an attachment -*AttachmentsApi* | [**delete_attachment**](docs/AttachmentsApi.md#delete_attachment) | **DELETE** /attachments/{attachment_gid} | Delete an attachment -*AttachmentsApi* | [**get_attachment**](docs/AttachmentsApi.md#get_attachment) | **GET** /attachments/{attachment_gid} | Get an attachment -*AttachmentsApi* | [**get_attachments_for_object**](docs/AttachmentsApi.md#get_attachments_for_object) | **GET** /attachments | Get attachments from an object -*AuditLogAPIApi* | [**get_audit_log_events**](docs/AuditLogAPIApi.md#get_audit_log_events) | **GET** /workspaces/{workspace_gid}/audit_log_events | Get audit log events -*BatchAPIApi* | [**create_batch_request**](docs/BatchAPIApi.md#create_batch_request) | **POST** /batch | Submit parallel requests -*CustomFieldSettingsApi* | [**get_custom_field_settings_for_portfolio**](docs/CustomFieldSettingsApi.md#get_custom_field_settings_for_portfolio) | **GET** /portfolios/{portfolio_gid}/custom_field_settings | Get a portfolio's custom fields -*CustomFieldSettingsApi* | [**get_custom_field_settings_for_project**](docs/CustomFieldSettingsApi.md#get_custom_field_settings_for_project) | **GET** /projects/{project_gid}/custom_field_settings | Get a project's custom fields -*CustomFieldsApi* | [**create_custom_field**](docs/CustomFieldsApi.md#create_custom_field) | **POST** /custom_fields | Create a custom field -*CustomFieldsApi* | [**create_enum_option_for_custom_field**](docs/CustomFieldsApi.md#create_enum_option_for_custom_field) | **POST** /custom_fields/{custom_field_gid}/enum_options | Create an enum option -*CustomFieldsApi* | [**delete_custom_field**](docs/CustomFieldsApi.md#delete_custom_field) | **DELETE** /custom_fields/{custom_field_gid} | Delete a custom field -*CustomFieldsApi* | [**get_custom_field**](docs/CustomFieldsApi.md#get_custom_field) | **GET** /custom_fields/{custom_field_gid} | Get a custom field -*CustomFieldsApi* | [**get_custom_fields_for_workspace**](docs/CustomFieldsApi.md#get_custom_fields_for_workspace) | **GET** /workspaces/{workspace_gid}/custom_fields | Get a workspace's custom fields -*CustomFieldsApi* | [**insert_enum_option_for_custom_field**](docs/CustomFieldsApi.md#insert_enum_option_for_custom_field) | **POST** /custom_fields/{custom_field_gid}/enum_options/insert | Reorder a custom field's enum -*CustomFieldsApi* | [**update_custom_field**](docs/CustomFieldsApi.md#update_custom_field) | **PUT** /custom_fields/{custom_field_gid} | Update a custom field -*CustomFieldsApi* | [**update_enum_option**](docs/CustomFieldsApi.md#update_enum_option) | **PUT** /enum_options/{enum_option_gid} | Update an enum option -*EventsApi* | [**get_events**](docs/EventsApi.md#get_events) | **GET** /events | Get events on a resource -*GoalRelationshipsApi* | [**add_supporting_relationship**](docs/GoalRelationshipsApi.md#add_supporting_relationship) | **POST** /goals/{goal_gid}/addSupportingRelationship | Add a supporting goal relationship -*GoalRelationshipsApi* | [**get_goal_relationship**](docs/GoalRelationshipsApi.md#get_goal_relationship) | **GET** /goal_relationships/{goal_relationship_gid} | Get a goal relationship -*GoalRelationshipsApi* | [**get_goal_relationships**](docs/GoalRelationshipsApi.md#get_goal_relationships) | **GET** /goal_relationships | Get goal relationships -*GoalRelationshipsApi* | [**remove_supporting_relationship**](docs/GoalRelationshipsApi.md#remove_supporting_relationship) | **POST** /goals/{goal_gid}/removeSupportingRelationship | Removes a supporting goal relationship -*GoalRelationshipsApi* | [**update_goal_relationship**](docs/GoalRelationshipsApi.md#update_goal_relationship) | **PUT** /goal_relationships/{goal_relationship_gid} | Update a goal relationship -*GoalsApi* | [**add_followers**](docs/GoalsApi.md#add_followers) | **POST** /goals/{goal_gid}/addFollowers | Add a collaborator to a goal -*GoalsApi* | [**create_goal**](docs/GoalsApi.md#create_goal) | **POST** /goals | Create a goal -*GoalsApi* | [**create_goal_metric**](docs/GoalsApi.md#create_goal_metric) | **POST** /goals/{goal_gid}/setMetric | Create a goal metric -*GoalsApi* | [**delete_goal**](docs/GoalsApi.md#delete_goal) | **DELETE** /goals/{goal_gid} | Delete a goal -*GoalsApi* | [**get_goal**](docs/GoalsApi.md#get_goal) | **GET** /goals/{goal_gid} | Get a goal -*GoalsApi* | [**get_goals**](docs/GoalsApi.md#get_goals) | **GET** /goals | Get goals -*GoalsApi* | [**get_parent_goals_for_goal**](docs/GoalsApi.md#get_parent_goals_for_goal) | **GET** /goals/{goal_gid}/parentGoals | Get parent goals from a goal -*GoalsApi* | [**remove_followers**](docs/GoalsApi.md#remove_followers) | **POST** /goals/{goal_gid}/removeFollowers | Remove a collaborator from a goal -*GoalsApi* | [**update_goal**](docs/GoalsApi.md#update_goal) | **PUT** /goals/{goal_gid} | Update a goal -*GoalsApi* | [**update_goal_metric**](docs/GoalsApi.md#update_goal_metric) | **POST** /goals/{goal_gid}/setMetricCurrentValue | Update a goal metric -*JobsApi* | [**get_job**](docs/JobsApi.md#get_job) | **GET** /jobs/{job_gid} | Get a job by id -*MembershipsApi* | [**create_membership**](docs/MembershipsApi.md#create_membership) | **POST** /memberships | Create a membership -*MembershipsApi* | [**delete_membership**](docs/MembershipsApi.md#delete_membership) | **DELETE** /memberships/{membership_gid} | Delete a membership -*MembershipsApi* | [**get_membership**](docs/MembershipsApi.md#get_membership) | **GET** /memberships/{membership_gid} | Get a membership -*MembershipsApi* | [**get_memberships**](docs/MembershipsApi.md#get_memberships) | **GET** /memberships | Get multiple memberships -*OrganizationExportsApi* | [**create_organization_export**](docs/OrganizationExportsApi.md#create_organization_export) | **POST** /organization_exports | Create an organization export request -*OrganizationExportsApi* | [**get_organization_export**](docs/OrganizationExportsApi.md#get_organization_export) | **GET** /organization_exports/{organization_export_gid} | Get details on an org export request -*PortfolioMembershipsApi* | [**get_portfolio_membership**](docs/PortfolioMembershipsApi.md#get_portfolio_membership) | **GET** /portfolio_memberships/{portfolio_membership_gid} | Get a portfolio membership -*PortfolioMembershipsApi* | [**get_portfolio_memberships**](docs/PortfolioMembershipsApi.md#get_portfolio_memberships) | **GET** /portfolio_memberships | Get multiple portfolio memberships -*PortfolioMembershipsApi* | [**get_portfolio_memberships_for_portfolio**](docs/PortfolioMembershipsApi.md#get_portfolio_memberships_for_portfolio) | **GET** /portfolios/{portfolio_gid}/portfolio_memberships | Get memberships from a portfolio -*PortfoliosApi* | [**add_custom_field_setting_for_portfolio**](docs/PortfoliosApi.md#add_custom_field_setting_for_portfolio) | **POST** /portfolios/{portfolio_gid}/addCustomFieldSetting | Add a custom field to a portfolio -*PortfoliosApi* | [**add_item_for_portfolio**](docs/PortfoliosApi.md#add_item_for_portfolio) | **POST** /portfolios/{portfolio_gid}/addItem | Add a portfolio item -*PortfoliosApi* | [**add_members_for_portfolio**](docs/PortfoliosApi.md#add_members_for_portfolio) | **POST** /portfolios/{portfolio_gid}/addMembers | Add users to a portfolio -*PortfoliosApi* | [**create_portfolio**](docs/PortfoliosApi.md#create_portfolio) | **POST** /portfolios | Create a portfolio -*PortfoliosApi* | [**delete_portfolio**](docs/PortfoliosApi.md#delete_portfolio) | **DELETE** /portfolios/{portfolio_gid} | Delete a portfolio -*PortfoliosApi* | [**get_items_for_portfolio**](docs/PortfoliosApi.md#get_items_for_portfolio) | **GET** /portfolios/{portfolio_gid}/items | Get portfolio items -*PortfoliosApi* | [**get_portfolio**](docs/PortfoliosApi.md#get_portfolio) | **GET** /portfolios/{portfolio_gid} | Get a portfolio -*PortfoliosApi* | [**get_portfolios**](docs/PortfoliosApi.md#get_portfolios) | **GET** /portfolios | Get multiple portfolios -*PortfoliosApi* | [**remove_custom_field_setting_for_portfolio**](docs/PortfoliosApi.md#remove_custom_field_setting_for_portfolio) | **POST** /portfolios/{portfolio_gid}/removeCustomFieldSetting | Remove a custom field from a portfolio -*PortfoliosApi* | [**remove_item_for_portfolio**](docs/PortfoliosApi.md#remove_item_for_portfolio) | **POST** /portfolios/{portfolio_gid}/removeItem | Remove a portfolio item -*PortfoliosApi* | [**remove_members_for_portfolio**](docs/PortfoliosApi.md#remove_members_for_portfolio) | **POST** /portfolios/{portfolio_gid}/removeMembers | Remove users from a portfolio -*PortfoliosApi* | [**update_portfolio**](docs/PortfoliosApi.md#update_portfolio) | **PUT** /portfolios/{portfolio_gid} | Update a portfolio -*ProjectBriefsApi* | [**create_project_brief**](docs/ProjectBriefsApi.md#create_project_brief) | **POST** /projects/{project_gid}/project_briefs | Create a project brief -*ProjectBriefsApi* | [**delete_project_brief**](docs/ProjectBriefsApi.md#delete_project_brief) | **DELETE** /project_briefs/{project_brief_gid} | Delete a project brief -*ProjectBriefsApi* | [**get_project_brief**](docs/ProjectBriefsApi.md#get_project_brief) | **GET** /project_briefs/{project_brief_gid} | Get a project brief -*ProjectBriefsApi* | [**update_project_brief**](docs/ProjectBriefsApi.md#update_project_brief) | **PUT** /project_briefs/{project_brief_gid} | Update a project brief -*ProjectMembershipsApi* | [**get_project_membership**](docs/ProjectMembershipsApi.md#get_project_membership) | **GET** /project_memberships/{project_membership_gid} | Get a project membership -*ProjectMembershipsApi* | [**get_project_memberships_for_project**](docs/ProjectMembershipsApi.md#get_project_memberships_for_project) | **GET** /projects/{project_gid}/project_memberships | Get memberships from a project -*ProjectStatusesApi* | [**create_project_status_for_project**](docs/ProjectStatusesApi.md#create_project_status_for_project) | **POST** /projects/{project_gid}/project_statuses | Create a project status -*ProjectStatusesApi* | [**delete_project_status**](docs/ProjectStatusesApi.md#delete_project_status) | **DELETE** /project_statuses/{project_status_gid} | Delete a project status -*ProjectStatusesApi* | [**get_project_status**](docs/ProjectStatusesApi.md#get_project_status) | **GET** /project_statuses/{project_status_gid} | Get a project status -*ProjectStatusesApi* | [**get_project_statuses_for_project**](docs/ProjectStatusesApi.md#get_project_statuses_for_project) | **GET** /projects/{project_gid}/project_statuses | Get statuses from a project -*ProjectTemplatesApi* | [**delete_project_template**](docs/ProjectTemplatesApi.md#delete_project_template) | **DELETE** /project_templates/{project_template_gid} | Delete a project template -*ProjectTemplatesApi* | [**get_project_template**](docs/ProjectTemplatesApi.md#get_project_template) | **GET** /project_templates/{project_template_gid} | Get a project template -*ProjectTemplatesApi* | [**get_project_templates**](docs/ProjectTemplatesApi.md#get_project_templates) | **GET** /project_templates | Get multiple project templates -*ProjectTemplatesApi* | [**get_project_templates_for_team**](docs/ProjectTemplatesApi.md#get_project_templates_for_team) | **GET** /teams/{team_gid}/project_templates | Get a team's project templates -*ProjectTemplatesApi* | [**instantiate_project**](docs/ProjectTemplatesApi.md#instantiate_project) | **POST** /project_templates/{project_template_gid}/instantiateProject | Instantiate a project from a project template -*ProjectsApi* | [**add_custom_field_setting_for_project**](docs/ProjectsApi.md#add_custom_field_setting_for_project) | **POST** /projects/{project_gid}/addCustomFieldSetting | Add a custom field to a project -*ProjectsApi* | [**add_followers_for_project**](docs/ProjectsApi.md#add_followers_for_project) | **POST** /projects/{project_gid}/addFollowers | Add followers to a project -*ProjectsApi* | [**add_members_for_project**](docs/ProjectsApi.md#add_members_for_project) | **POST** /projects/{project_gid}/addMembers | Add users to a project -*ProjectsApi* | [**create_project**](docs/ProjectsApi.md#create_project) | **POST** /projects | Create a project -*ProjectsApi* | [**create_project_for_team**](docs/ProjectsApi.md#create_project_for_team) | **POST** /teams/{team_gid}/projects | Create a project in a team -*ProjectsApi* | [**create_project_for_workspace**](docs/ProjectsApi.md#create_project_for_workspace) | **POST** /workspaces/{workspace_gid}/projects | Create a project in a workspace -*ProjectsApi* | [**delete_project**](docs/ProjectsApi.md#delete_project) | **DELETE** /projects/{project_gid} | Delete a project -*ProjectsApi* | [**duplicate_project**](docs/ProjectsApi.md#duplicate_project) | **POST** /projects/{project_gid}/duplicate | Duplicate a project -*ProjectsApi* | [**get_project**](docs/ProjectsApi.md#get_project) | **GET** /projects/{project_gid} | Get a project -*ProjectsApi* | [**get_projects**](docs/ProjectsApi.md#get_projects) | **GET** /projects | Get multiple projects -*ProjectsApi* | [**get_projects_for_task**](docs/ProjectsApi.md#get_projects_for_task) | **GET** /tasks/{task_gid}/projects | Get projects a task is in -*ProjectsApi* | [**get_projects_for_team**](docs/ProjectsApi.md#get_projects_for_team) | **GET** /teams/{team_gid}/projects | Get a team's projects -*ProjectsApi* | [**get_projects_for_workspace**](docs/ProjectsApi.md#get_projects_for_workspace) | **GET** /workspaces/{workspace_gid}/projects | Get all projects in a workspace -*ProjectsApi* | [**get_task_counts_for_project**](docs/ProjectsApi.md#get_task_counts_for_project) | **GET** /projects/{project_gid}/task_counts | Get task count of a project -*ProjectsApi* | [**project_save_as_template**](docs/ProjectsApi.md#project_save_as_template) | **POST** /projects/{project_gid}/saveAsTemplate | Create a project template from a project -*ProjectsApi* | [**remove_custom_field_setting_for_project**](docs/ProjectsApi.md#remove_custom_field_setting_for_project) | **POST** /projects/{project_gid}/removeCustomFieldSetting | Remove a custom field from a project -*ProjectsApi* | [**remove_followers_for_project**](docs/ProjectsApi.md#remove_followers_for_project) | **POST** /projects/{project_gid}/removeFollowers | Remove followers from a project -*ProjectsApi* | [**remove_members_for_project**](docs/ProjectsApi.md#remove_members_for_project) | **POST** /projects/{project_gid}/removeMembers | Remove users from a project -*ProjectsApi* | [**update_project**](docs/ProjectsApi.md#update_project) | **PUT** /projects/{project_gid} | Update a project -*RulesApi* | [**trigger_rule**](docs/RulesApi.md#trigger_rule) | **POST** /rule_triggers/{rule_trigger_gid}/run | Trigger a rule -*SectionsApi* | [**add_task_for_section**](docs/SectionsApi.md#add_task_for_section) | **POST** /sections/{section_gid}/addTask | Add task to section -*SectionsApi* | [**create_section_for_project**](docs/SectionsApi.md#create_section_for_project) | **POST** /projects/{project_gid}/sections | Create a section in a project -*SectionsApi* | [**delete_section**](docs/SectionsApi.md#delete_section) | **DELETE** /sections/{section_gid} | Delete a section -*SectionsApi* | [**get_section**](docs/SectionsApi.md#get_section) | **GET** /sections/{section_gid} | Get a section -*SectionsApi* | [**get_sections_for_project**](docs/SectionsApi.md#get_sections_for_project) | **GET** /projects/{project_gid}/sections | Get sections in a project -*SectionsApi* | [**insert_section_for_project**](docs/SectionsApi.md#insert_section_for_project) | **POST** /projects/{project_gid}/sections/insert | Move or Insert sections -*SectionsApi* | [**update_section**](docs/SectionsApi.md#update_section) | **PUT** /sections/{section_gid} | Update a section -*StatusUpdatesApi* | [**create_status_for_object**](docs/StatusUpdatesApi.md#create_status_for_object) | **POST** /status_updates | Create a status update -*StatusUpdatesApi* | [**delete_status**](docs/StatusUpdatesApi.md#delete_status) | **DELETE** /status_updates/{status_update_gid} | Delete a status update -*StatusUpdatesApi* | [**get_status**](docs/StatusUpdatesApi.md#get_status) | **GET** /status_updates/{status_update_gid} | Get a status update -*StatusUpdatesApi* | [**get_statuses_for_object**](docs/StatusUpdatesApi.md#get_statuses_for_object) | **GET** /status_updates | Get status updates from an object -*StoriesApi* | [**create_story_for_task**](docs/StoriesApi.md#create_story_for_task) | **POST** /tasks/{task_gid}/stories | Create a story on a task -*StoriesApi* | [**delete_story**](docs/StoriesApi.md#delete_story) | **DELETE** /stories/{story_gid} | Delete a story -*StoriesApi* | [**get_stories_for_task**](docs/StoriesApi.md#get_stories_for_task) | **GET** /tasks/{task_gid}/stories | Get stories from a task -*StoriesApi* | [**get_story**](docs/StoriesApi.md#get_story) | **GET** /stories/{story_gid} | Get a story -*StoriesApi* | [**update_story**](docs/StoriesApi.md#update_story) | **PUT** /stories/{story_gid} | Update a story -*TagsApi* | [**create_tag**](docs/TagsApi.md#create_tag) | **POST** /tags | Create a tag -*TagsApi* | [**create_tag_for_workspace**](docs/TagsApi.md#create_tag_for_workspace) | **POST** /workspaces/{workspace_gid}/tags | Create a tag in a workspace -*TagsApi* | [**delete_tag**](docs/TagsApi.md#delete_tag) | **DELETE** /tags/{tag_gid} | Delete a tag -*TagsApi* | [**get_tag**](docs/TagsApi.md#get_tag) | **GET** /tags/{tag_gid} | Get a tag -*TagsApi* | [**get_tags**](docs/TagsApi.md#get_tags) | **GET** /tags | Get multiple tags -*TagsApi* | [**get_tags_for_task**](docs/TagsApi.md#get_tags_for_task) | **GET** /tasks/{task_gid}/tags | Get a task's tags -*TagsApi* | [**get_tags_for_workspace**](docs/TagsApi.md#get_tags_for_workspace) | **GET** /workspaces/{workspace_gid}/tags | Get tags in a workspace -*TagsApi* | [**update_tag**](docs/TagsApi.md#update_tag) | **PUT** /tags/{tag_gid} | Update a tag -*TaskTemplatesApi* | [**get_task_template**](docs/TaskTemplatesApi.md#get_task_template) | **GET** /task_templates/{task_template_gid} | Get a task template -*TaskTemplatesApi* | [**get_task_templates**](docs/TaskTemplatesApi.md#get_task_templates) | **GET** /task_templates | Get multiple task templates -*TaskTemplatesApi* | [**instantiate_task**](docs/TaskTemplatesApi.md#instantiate_task) | **POST** /task_templates/{task_template_gid}/instantiateTask | Instantiate a task from a task template -*TasksApi* | [**add_dependencies_for_task**](docs/TasksApi.md#add_dependencies_for_task) | **POST** /tasks/{task_gid}/addDependencies | Set dependencies for a task -*TasksApi* | [**add_dependents_for_task**](docs/TasksApi.md#add_dependents_for_task) | **POST** /tasks/{task_gid}/addDependents | Set dependents for a task -*TasksApi* | [**add_followers_for_task**](docs/TasksApi.md#add_followers_for_task) | **POST** /tasks/{task_gid}/addFollowers | Add followers to a task -*TasksApi* | [**add_project_for_task**](docs/TasksApi.md#add_project_for_task) | **POST** /tasks/{task_gid}/addProject | Add a project to a task -*TasksApi* | [**add_tag_for_task**](docs/TasksApi.md#add_tag_for_task) | **POST** /tasks/{task_gid}/addTag | Add a tag to a task -*TasksApi* | [**create_subtask_for_task**](docs/TasksApi.md#create_subtask_for_task) | **POST** /tasks/{task_gid}/subtasks | Create a subtask -*TasksApi* | [**create_task**](docs/TasksApi.md#create_task) | **POST** /tasks | Create a task -*TasksApi* | [**delete_task**](docs/TasksApi.md#delete_task) | **DELETE** /tasks/{task_gid} | Delete a task -*TasksApi* | [**duplicate_task**](docs/TasksApi.md#duplicate_task) | **POST** /tasks/{task_gid}/duplicate | Duplicate a task -*TasksApi* | [**get_dependencies_for_task**](docs/TasksApi.md#get_dependencies_for_task) | **GET** /tasks/{task_gid}/dependencies | Get dependencies from a task -*TasksApi* | [**get_dependents_for_task**](docs/TasksApi.md#get_dependents_for_task) | **GET** /tasks/{task_gid}/dependents | Get dependents from a task -*TasksApi* | [**get_subtasks_for_task**](docs/TasksApi.md#get_subtasks_for_task) | **GET** /tasks/{task_gid}/subtasks | Get subtasks from a task -*TasksApi* | [**get_task**](docs/TasksApi.md#get_task) | **GET** /tasks/{task_gid} | Get a task -*TasksApi* | [**get_tasks**](docs/TasksApi.md#get_tasks) | **GET** /tasks | Get multiple tasks -*TasksApi* | [**get_tasks_for_project**](docs/TasksApi.md#get_tasks_for_project) | **GET** /projects/{project_gid}/tasks | Get tasks from a project -*TasksApi* | [**get_tasks_for_section**](docs/TasksApi.md#get_tasks_for_section) | **GET** /sections/{section_gid}/tasks | Get tasks from a section -*TasksApi* | [**get_tasks_for_tag**](docs/TasksApi.md#get_tasks_for_tag) | **GET** /tags/{tag_gid}/tasks | Get tasks from a tag -*TasksApi* | [**get_tasks_for_user_task_list**](docs/TasksApi.md#get_tasks_for_user_task_list) | **GET** /user_task_lists/{user_task_list_gid}/tasks | Get tasks from a user task list -*TasksApi* | [**remove_dependencies_for_task**](docs/TasksApi.md#remove_dependencies_for_task) | **POST** /tasks/{task_gid}/removeDependencies | Unlink dependencies from a task -*TasksApi* | [**remove_dependents_for_task**](docs/TasksApi.md#remove_dependents_for_task) | **POST** /tasks/{task_gid}/removeDependents | Unlink dependents from a task -*TasksApi* | [**remove_follower_for_task**](docs/TasksApi.md#remove_follower_for_task) | **POST** /tasks/{task_gid}/removeFollowers | Remove followers from a task -*TasksApi* | [**remove_project_for_task**](docs/TasksApi.md#remove_project_for_task) | **POST** /tasks/{task_gid}/removeProject | Remove a project from a task -*TasksApi* | [**remove_tag_for_task**](docs/TasksApi.md#remove_tag_for_task) | **POST** /tasks/{task_gid}/removeTag | Remove a tag from a task -*TasksApi* | [**search_tasks_for_workspace**](docs/TasksApi.md#search_tasks_for_workspace) | **GET** /workspaces/{workspace_gid}/tasks/search | Search tasks in a workspace -*TasksApi* | [**set_parent_for_task**](docs/TasksApi.md#set_parent_for_task) | **POST** /tasks/{task_gid}/setParent | Set the parent of a task -*TasksApi* | [**update_task**](docs/TasksApi.md#update_task) | **PUT** /tasks/{task_gid} | Update a task -*TeamMembershipsApi* | [**get_team_membership**](docs/TeamMembershipsApi.md#get_team_membership) | **GET** /team_memberships/{team_membership_gid} | Get a team membership -*TeamMembershipsApi* | [**get_team_memberships**](docs/TeamMembershipsApi.md#get_team_memberships) | **GET** /team_memberships | Get team memberships -*TeamMembershipsApi* | [**get_team_memberships_for_team**](docs/TeamMembershipsApi.md#get_team_memberships_for_team) | **GET** /teams/{team_gid}/team_memberships | Get memberships from a team -*TeamMembershipsApi* | [**get_team_memberships_for_user**](docs/TeamMembershipsApi.md#get_team_memberships_for_user) | **GET** /users/{user_gid}/team_memberships | Get memberships from a user -*TeamsApi* | [**add_user_for_team**](docs/TeamsApi.md#add_user_for_team) | **POST** /teams/{team_gid}/addUser | Add a user to a team -*TeamsApi* | [**create_team**](docs/TeamsApi.md#create_team) | **POST** /teams | Create a team -*TeamsApi* | [**get_team**](docs/TeamsApi.md#get_team) | **GET** /teams/{team_gid} | Get a team -*TeamsApi* | [**get_teams_for_user**](docs/TeamsApi.md#get_teams_for_user) | **GET** /users/{user_gid}/teams | Get teams for a user -*TeamsApi* | [**get_teams_for_workspace**](docs/TeamsApi.md#get_teams_for_workspace) | **GET** /workspaces/{workspace_gid}/teams | Get teams in a workspace -*TeamsApi* | [**remove_user_for_team**](docs/TeamsApi.md#remove_user_for_team) | **POST** /teams/{team_gid}/removeUser | Remove a user from a team -*TeamsApi* | [**update_team**](docs/TeamsApi.md#update_team) | **PUT** /teams/{team_gid} | Update a team -*TimePeriodsApi* | [**get_time_period**](docs/TimePeriodsApi.md#get_time_period) | **GET** /time_periods/{time_period_gid} | Get a time period -*TimePeriodsApi* | [**get_time_periods**](docs/TimePeriodsApi.md#get_time_periods) | **GET** /time_periods | Get time periods -*TimeTrackingEntriesApi* | [**create_time_tracking_entry**](docs/TimeTrackingEntriesApi.md#create_time_tracking_entry) | **POST** /tasks/{task_gid}/time_tracking_entries | Create a time tracking entry -*TimeTrackingEntriesApi* | [**delete_time_tracking_entry**](docs/TimeTrackingEntriesApi.md#delete_time_tracking_entry) | **DELETE** /time_tracking_entries/{time_tracking_entry_gid} | Delete a time tracking entry -*TimeTrackingEntriesApi* | [**get_time_tracking_entries_for_task**](docs/TimeTrackingEntriesApi.md#get_time_tracking_entries_for_task) | **GET** /tasks/{task_gid}/time_tracking_entries | Get time tracking entries for a task -*TimeTrackingEntriesApi* | [**get_time_tracking_entry**](docs/TimeTrackingEntriesApi.md#get_time_tracking_entry) | **GET** /time_tracking_entries/{time_tracking_entry_gid} | Get a time tracking entry -*TimeTrackingEntriesApi* | [**update_time_tracking_entry**](docs/TimeTrackingEntriesApi.md#update_time_tracking_entry) | **PUT** /time_tracking_entries/{time_tracking_entry_gid} | Update a time tracking entry -*TypeaheadApi* | [**typeahead_for_workspace**](docs/TypeaheadApi.md#typeahead_for_workspace) | **GET** /workspaces/{workspace_gid}/typeahead | Get objects via typeahead -*UserTaskListsApi* | [**get_user_task_list**](docs/UserTaskListsApi.md#get_user_task_list) | **GET** /user_task_lists/{user_task_list_gid} | Get a user task list -*UserTaskListsApi* | [**get_user_task_list_for_user**](docs/UserTaskListsApi.md#get_user_task_list_for_user) | **GET** /users/{user_gid}/user_task_list | Get a user's task list -*UsersApi* | [**get_favorites_for_user**](docs/UsersApi.md#get_favorites_for_user) | **GET** /users/{user_gid}/favorites | Get a user's favorites -*UsersApi* | [**get_user**](docs/UsersApi.md#get_user) | **GET** /users/{user_gid} | Get a user -*UsersApi* | [**get_users**](docs/UsersApi.md#get_users) | **GET** /users | Get multiple users -*UsersApi* | [**get_users_for_team**](docs/UsersApi.md#get_users_for_team) | **GET** /teams/{team_gid}/users | Get users in a team -*UsersApi* | [**get_users_for_workspace**](docs/UsersApi.md#get_users_for_workspace) | **GET** /workspaces/{workspace_gid}/users | Get users in a workspace or organization -*WebhooksApi* | [**create_webhook**](docs/WebhooksApi.md#create_webhook) | **POST** /webhooks | Establish a webhook -*WebhooksApi* | [**delete_webhook**](docs/WebhooksApi.md#delete_webhook) | **DELETE** /webhooks/{webhook_gid} | Delete a webhook -*WebhooksApi* | [**get_webhook**](docs/WebhooksApi.md#get_webhook) | **GET** /webhooks/{webhook_gid} | Get a webhook -*WebhooksApi* | [**get_webhooks**](docs/WebhooksApi.md#get_webhooks) | **GET** /webhooks | Get multiple webhooks -*WebhooksApi* | [**update_webhook**](docs/WebhooksApi.md#update_webhook) | **PUT** /webhooks/{webhook_gid} | Update a webhook -*WorkspaceMembershipsApi* | [**get_workspace_membership**](docs/WorkspaceMembershipsApi.md#get_workspace_membership) | **GET** /workspace_memberships/{workspace_membership_gid} | Get a workspace membership -*WorkspaceMembershipsApi* | [**get_workspace_memberships_for_user**](docs/WorkspaceMembershipsApi.md#get_workspace_memberships_for_user) | **GET** /users/{user_gid}/workspace_memberships | Get workspace memberships for a user -*WorkspaceMembershipsApi* | [**get_workspace_memberships_for_workspace**](docs/WorkspaceMembershipsApi.md#get_workspace_memberships_for_workspace) | **GET** /workspaces/{workspace_gid}/workspace_memberships | Get the workspace memberships for a workspace -*WorkspacesApi* | [**add_user_for_workspace**](docs/WorkspacesApi.md#add_user_for_workspace) | **POST** /workspaces/{workspace_gid}/addUser | Add a user to a workspace or organization -*WorkspacesApi* | [**get_workspace**](docs/WorkspacesApi.md#get_workspace) | **GET** /workspaces/{workspace_gid} | Get a workspace -*WorkspacesApi* | [**get_workspaces**](docs/WorkspacesApi.md#get_workspaces) | **GET** /workspaces | Get multiple workspaces -*WorkspacesApi* | [**remove_user_for_workspace**](docs/WorkspacesApi.md#remove_user_for_workspace) | **POST** /workspaces/{workspace_gid}/removeUser | Remove a user from a workspace or organization -*WorkspacesApi* | [**update_workspace**](docs/WorkspacesApi.md#update_workspace) | **PUT** /workspaces/{workspace_gid} | Update a workspace - -## Documentation For Models - - - [AddCustomFieldSettingRequest](docs/AddCustomFieldSettingRequest.md) - - [AddFollowersRequest](docs/AddFollowersRequest.md) - - [AddMembersRequest](docs/AddMembersRequest.md) - - [AllOfProjectResponseOwner](docs/AllOfProjectResponseOwner.md) - - [AllOfProjectTemplateBaseOwner](docs/AllOfProjectTemplateBaseOwner.md) - - [AllOfProjectTemplateResponseOwner](docs/AllOfProjectTemplateResponseOwner.md) - - [AllOfStoryResponseNewDateValue](docs/AllOfStoryResponseNewDateValue.md) - - [AllOfStoryResponseOldDateValue](docs/AllOfStoryResponseOldDateValue.md) - - [AllOfTaskTemplateResponseCreatedBy](docs/AllOfTaskTemplateResponseCreatedBy.md) - - [AllOfTaskTemplateResponseProject](docs/AllOfTaskTemplateResponseProject.md) - - [AllOfTaskTemplateResponseTemplate](docs/AllOfTaskTemplateResponseTemplate.md) - - [AllOfUserTaskListBaseOwner](docs/AllOfUserTaskListBaseOwner.md) - - [AllOfUserTaskListBaseWorkspace](docs/AllOfUserTaskListBaseWorkspace.md) - - [AllOfUserTaskListCompactOwner](docs/AllOfUserTaskListCompactOwner.md) - - [AllOfUserTaskListCompactWorkspace](docs/AllOfUserTaskListCompactWorkspace.md) - - [AllOfUserTaskListRequestOwner](docs/AllOfUserTaskListRequestOwner.md) - - [AllOfUserTaskListRequestWorkspace](docs/AllOfUserTaskListRequestWorkspace.md) - - [AllOfUserTaskListResponseOwner](docs/AllOfUserTaskListResponseOwner.md) - - [AllOfUserTaskListResponseWorkspace](docs/AllOfUserTaskListResponseWorkspace.md) - - [AllOfWorkspaceMembershipResponseUserTaskListOwner](docs/AllOfWorkspaceMembershipResponseUserTaskListOwner.md) - - [AllOfWorkspaceMembershipResponseUserTaskListWorkspace](docs/AllOfWorkspaceMembershipResponseUserTaskListWorkspace.md) - - [AsanaNamedResource](docs/AsanaNamedResource.md) - - [AsanaNamedResourceArray](docs/AsanaNamedResourceArray.md) - - [AsanaResource](docs/AsanaResource.md) - - [AttachmentBase](docs/AttachmentBase.md) - - [AttachmentCompact](docs/AttachmentCompact.md) - - [AttachmentRequest](docs/AttachmentRequest.md) - - [AttachmentResponse](docs/AttachmentResponse.md) - - [AttachmentResponseArray](docs/AttachmentResponseArray.md) - - [AttachmentResponseData](docs/AttachmentResponseData.md) - - [AttachmentResponseParent](docs/AttachmentResponseParent.md) - - [AttachmentResponseParentCreatedBy](docs/AttachmentResponseParentCreatedBy.md) - - [AuditLogEvent](docs/AuditLogEvent.md) - - [AuditLogEventActor](docs/AuditLogEventActor.md) - - [AuditLogEventArray](docs/AuditLogEventArray.md) - - [AuditLogEventContext](docs/AuditLogEventContext.md) - - [AuditLogEventDetails](docs/AuditLogEventDetails.md) - - [AuditLogEventResource](docs/AuditLogEventResource.md) - - [BatchBody](docs/BatchBody.md) - - [BatchRequest](docs/BatchRequest.md) - - [BatchRequestAction](docs/BatchRequestAction.md) - - [BatchRequestActions](docs/BatchRequestActions.md) - - [BatchRequestOptions](docs/BatchRequestOptions.md) - - [BatchResponse](docs/BatchResponse.md) - - [BatchResponseArray](docs/BatchResponseArray.md) - - [CreateMembershipRequest](docs/CreateMembershipRequest.md) - - [CreateTimeTrackingEntryRequest](docs/CreateTimeTrackingEntryRequest.md) - - [CustomFieldBase](docs/CustomFieldBase.md) - - [CustomFieldBaseDateValue](docs/CustomFieldBaseDateValue.md) - - [CustomFieldBaseEnumOptions](docs/CustomFieldBaseEnumOptions.md) - - [CustomFieldBaseEnumValue](docs/CustomFieldBaseEnumValue.md) - - [CustomFieldCompact](docs/CustomFieldCompact.md) - - [CustomFieldGidEnumOptionsBody](docs/CustomFieldGidEnumOptionsBody.md) - - [CustomFieldRequest](docs/CustomFieldRequest.md) - - [CustomFieldResponse](docs/CustomFieldResponse.md) - - [CustomFieldResponseArray](docs/CustomFieldResponseArray.md) - - [CustomFieldResponseCreatedBy](docs/CustomFieldResponseCreatedBy.md) - - [CustomFieldResponseData](docs/CustomFieldResponseData.md) - - [CustomFieldResponsePeopleValue](docs/CustomFieldResponsePeopleValue.md) - - [CustomFieldSettingBase](docs/CustomFieldSettingBase.md) - - [CustomFieldSettingCompact](docs/CustomFieldSettingCompact.md) - - [CustomFieldSettingResponse](docs/CustomFieldSettingResponse.md) - - [CustomFieldSettingResponseArray](docs/CustomFieldSettingResponseArray.md) - - [CustomFieldSettingResponseCustomField](docs/CustomFieldSettingResponseCustomField.md) - - [CustomFieldSettingResponseData](docs/CustomFieldSettingResponseData.md) - - [CustomFieldSettingResponseParent](docs/CustomFieldSettingResponseParent.md) - - [CustomFieldSettingResponseProject](docs/CustomFieldSettingResponseProject.md) - - [CustomFieldsBody](docs/CustomFieldsBody.md) - - [CustomFieldsCustomFieldGidBody](docs/CustomFieldsCustomFieldGidBody.md) - - [DateVariableCompact](docs/DateVariableCompact.md) - - [DateVariableRequest](docs/DateVariableRequest.md) - - [EmptyResponse](docs/EmptyResponse.md) - - [EmptyResponseData](docs/EmptyResponseData.md) - - [EnumOption](docs/EnumOption.md) - - [EnumOptionBase](docs/EnumOptionBase.md) - - [EnumOptionData](docs/EnumOptionData.md) - - [EnumOptionInsertRequest](docs/EnumOptionInsertRequest.md) - - [EnumOptionRequest](docs/EnumOptionRequest.md) - - [EnumOptionsEnumOptionGidBody](docs/EnumOptionsEnumOptionGidBody.md) - - [EnumOptionsInsertBody](docs/EnumOptionsInsertBody.md) - - [Error](docs/Error.md) - - [ErrorResponse](docs/ErrorResponse.md) - - [ErrorResponseErrors](docs/ErrorResponseErrors.md) - - [EventResponse](docs/EventResponse.md) - - [EventResponseArray](docs/EventResponseArray.md) - - [EventResponseChange](docs/EventResponseChange.md) - - [EventResponseParent](docs/EventResponseParent.md) - - [EventResponseResource](docs/EventResponseResource.md) - - [EventResponseUser](docs/EventResponseUser.md) - - [GoalAddSubgoalRequest](docs/GoalAddSubgoalRequest.md) - - [GoalAddSupportingRelationshipRequest](docs/GoalAddSupportingRelationshipRequest.md) - - [GoalAddSupportingWorkRequest](docs/GoalAddSupportingWorkRequest.md) - - [GoalBase](docs/GoalBase.md) - - [GoalCompact](docs/GoalCompact.md) - - [GoalGidAddFollowersBody](docs/GoalGidAddFollowersBody.md) - - [GoalGidAddSupportingRelationshipBody](docs/GoalGidAddSupportingRelationshipBody.md) - - [GoalGidRemoveFollowersBody](docs/GoalGidRemoveFollowersBody.md) - - [GoalGidRemoveSupportingRelationshipBody](docs/GoalGidRemoveSupportingRelationshipBody.md) - - [GoalGidSetMetricBody](docs/GoalGidSetMetricBody.md) - - [GoalGidSetMetricCurrentValueBody](docs/GoalGidSetMetricCurrentValueBody.md) - - [GoalMembershipBase](docs/GoalMembershipBase.md) - - [GoalMembershipCompact](docs/GoalMembershipCompact.md) - - [GoalMembershipResponse](docs/GoalMembershipResponse.md) - - [GoalMembershipResponseUser](docs/GoalMembershipResponseUser.md) - - [GoalMembershipResponseWorkspace](docs/GoalMembershipResponseWorkspace.md) - - [GoalMetricBase](docs/GoalMetricBase.md) - - [GoalMetricCurrentValueRequest](docs/GoalMetricCurrentValueRequest.md) - - [GoalMetricRequest](docs/GoalMetricRequest.md) - - [GoalRelationshipBase](docs/GoalRelationshipBase.md) - - [GoalRelationshipBaseSupportedGoal](docs/GoalRelationshipBaseSupportedGoal.md) - - [GoalRelationshipBaseSupportingResource](docs/GoalRelationshipBaseSupportingResource.md) - - [GoalRelationshipCompact](docs/GoalRelationshipCompact.md) - - [GoalRelationshipRequest](docs/GoalRelationshipRequest.md) - - [GoalRelationshipResponse](docs/GoalRelationshipResponse.md) - - [GoalRelationshipResponseArray](docs/GoalRelationshipResponseArray.md) - - [GoalRelationshipResponseData](docs/GoalRelationshipResponseData.md) - - [GoalRelationshipsGoalRelationshipGidBody](docs/GoalRelationshipsGoalRelationshipGidBody.md) - - [GoalRemoveSubgoalRequest](docs/GoalRemoveSubgoalRequest.md) - - [GoalRemoveSupportingRelationshipRequest](docs/GoalRemoveSupportingRelationshipRequest.md) - - [GoalRequest](docs/GoalRequest.md) - - [GoalRequestBase](docs/GoalRequestBase.md) - - [GoalResponse](docs/GoalResponse.md) - - [GoalResponseArray](docs/GoalResponseArray.md) - - [GoalResponseCurrentStatusUpdate](docs/GoalResponseCurrentStatusUpdate.md) - - [GoalResponseData](docs/GoalResponseData.md) - - [GoalResponseLikes](docs/GoalResponseLikes.md) - - [GoalResponseMetric](docs/GoalResponseMetric.md) - - [GoalResponseTeam](docs/GoalResponseTeam.md) - - [GoalResponseTimePeriod](docs/GoalResponseTimePeriod.md) - - [GoalResponseWorkspace](docs/GoalResponseWorkspace.md) - - [GoalUpdateRequest](docs/GoalUpdateRequest.md) - - [GoalsBody](docs/GoalsBody.md) - - [GoalsGoalGidBody](docs/GoalsGoalGidBody.md) - - [InlineResponse412](docs/InlineResponse412.md) - - [InlineResponse412Errors](docs/InlineResponse412Errors.md) - - [JobBase](docs/JobBase.md) - - [JobBaseNewProject](docs/JobBaseNewProject.md) - - [JobBaseNewProjectTemplate](docs/JobBaseNewProjectTemplate.md) - - [JobBaseNewTask](docs/JobBaseNewTask.md) - - [JobCompact](docs/JobCompact.md) - - [JobResponse](docs/JobResponse.md) - - [JobResponseData](docs/JobResponseData.md) - - [Like](docs/Like.md) - - [MemberCompact](docs/MemberCompact.md) - - [MembershipCompact](docs/MembershipCompact.md) - - [MembershipCompactGoal](docs/MembershipCompactGoal.md) - - [MembershipCompactMember](docs/MembershipCompactMember.md) - - [MembershipCompactParent](docs/MembershipCompactParent.md) - - [MembershipRequest](docs/MembershipRequest.md) - - [MembershipResponse](docs/MembershipResponse.md) - - [MembershipResponseArray](docs/MembershipResponseArray.md) - - [MembershipResponseData](docs/MembershipResponseData.md) - - [MembershipsBody](docs/MembershipsBody.md) - - [ModifyDependenciesRequest](docs/ModifyDependenciesRequest.md) - - [ModifyDependentsRequest](docs/ModifyDependentsRequest.md) - - [NextPage](docs/NextPage.md) - - [OrganizationExportBase](docs/OrganizationExportBase.md) - - [OrganizationExportCompact](docs/OrganizationExportCompact.md) - - [OrganizationExportRequest](docs/OrganizationExportRequest.md) - - [OrganizationExportResponse](docs/OrganizationExportResponse.md) - - [OrganizationExportResponseData](docs/OrganizationExportResponseData.md) - - [OrganizationExportsBody](docs/OrganizationExportsBody.md) - - [PortfolioAddItemRequest](docs/PortfolioAddItemRequest.md) - - [PortfolioBase](docs/PortfolioBase.md) - - [PortfolioCompact](docs/PortfolioCompact.md) - - [PortfolioGidAddCustomFieldSettingBody](docs/PortfolioGidAddCustomFieldSettingBody.md) - - [PortfolioGidAddItemBody](docs/PortfolioGidAddItemBody.md) - - [PortfolioGidAddMembersBody](docs/PortfolioGidAddMembersBody.md) - - [PortfolioGidRemoveCustomFieldSettingBody](docs/PortfolioGidRemoveCustomFieldSettingBody.md) - - [PortfolioGidRemoveItemBody](docs/PortfolioGidRemoveItemBody.md) - - [PortfolioGidRemoveMembersBody](docs/PortfolioGidRemoveMembersBody.md) - - [PortfolioMembershipBase](docs/PortfolioMembershipBase.md) - - [PortfolioMembershipBasePortfolio](docs/PortfolioMembershipBasePortfolio.md) - - [PortfolioMembershipCompact](docs/PortfolioMembershipCompact.md) - - [PortfolioMembershipResponse](docs/PortfolioMembershipResponse.md) - - [PortfolioMembershipResponseArray](docs/PortfolioMembershipResponseArray.md) - - [PortfolioMembershipResponseData](docs/PortfolioMembershipResponseData.md) - - [PortfolioRemoveItemRequest](docs/PortfolioRemoveItemRequest.md) - - [PortfolioRequest](docs/PortfolioRequest.md) - - [PortfolioResponse](docs/PortfolioResponse.md) - - [PortfolioResponseArray](docs/PortfolioResponseArray.md) - - [PortfolioResponseCurrentStatusUpdate](docs/PortfolioResponseCurrentStatusUpdate.md) - - [PortfolioResponseCustomFieldSettings](docs/PortfolioResponseCustomFieldSettings.md) - - [PortfolioResponseCustomFields](docs/PortfolioResponseCustomFields.md) - - [PortfolioResponseData](docs/PortfolioResponseData.md) - - [PortfolioResponseWorkspace](docs/PortfolioResponseWorkspace.md) - - [PortfoliosBody](docs/PortfoliosBody.md) - - [PortfoliosPortfolioGidBody](docs/PortfoliosPortfolioGidBody.md) - - [Preview](docs/Preview.md) - - [ProjectBase](docs/ProjectBase.md) - - [ProjectBaseCurrentStatus](docs/ProjectBaseCurrentStatus.md) - - [ProjectBaseCurrentStatusUpdate](docs/ProjectBaseCurrentStatusUpdate.md) - - [ProjectBriefBase](docs/ProjectBriefBase.md) - - [ProjectBriefCompact](docs/ProjectBriefCompact.md) - - [ProjectBriefRequest](docs/ProjectBriefRequest.md) - - [ProjectBriefResponse](docs/ProjectBriefResponse.md) - - [ProjectBriefResponseData](docs/ProjectBriefResponseData.md) - - [ProjectBriefResponseProject](docs/ProjectBriefResponseProject.md) - - [ProjectBriefsProjectBriefGidBody](docs/ProjectBriefsProjectBriefGidBody.md) - - [ProjectCompact](docs/ProjectCompact.md) - - [ProjectDuplicateRequest](docs/ProjectDuplicateRequest.md) - - [ProjectDuplicateRequestScheduleDates](docs/ProjectDuplicateRequestScheduleDates.md) - - [ProjectGidAddCustomFieldSettingBody](docs/ProjectGidAddCustomFieldSettingBody.md) - - [ProjectGidAddFollowersBody](docs/ProjectGidAddFollowersBody.md) - - [ProjectGidAddMembersBody](docs/ProjectGidAddMembersBody.md) - - [ProjectGidDuplicateBody](docs/ProjectGidDuplicateBody.md) - - [ProjectGidProjectBriefsBody](docs/ProjectGidProjectBriefsBody.md) - - [ProjectGidProjectStatusesBody](docs/ProjectGidProjectStatusesBody.md) - - [ProjectGidRemoveCustomFieldSettingBody](docs/ProjectGidRemoveCustomFieldSettingBody.md) - - [ProjectGidRemoveFollowersBody](docs/ProjectGidRemoveFollowersBody.md) - - [ProjectGidRemoveMembersBody](docs/ProjectGidRemoveMembersBody.md) - - [ProjectGidSaveAsTemplateBody](docs/ProjectGidSaveAsTemplateBody.md) - - [ProjectGidSectionsBody](docs/ProjectGidSectionsBody.md) - - [ProjectMembershipBase](docs/ProjectMembershipBase.md) - - [ProjectMembershipCompact](docs/ProjectMembershipCompact.md) - - [ProjectMembershipCompactArray](docs/ProjectMembershipCompactArray.md) - - [ProjectMembershipCompactResponse](docs/ProjectMembershipCompactResponse.md) - - [ProjectMembershipCompactResponseData](docs/ProjectMembershipCompactResponseData.md) - - [ProjectMembershipNormalResponse](docs/ProjectMembershipNormalResponse.md) - - [ProjectMembershipNormalResponseData](docs/ProjectMembershipNormalResponseData.md) - - [ProjectRequest](docs/ProjectRequest.md) - - [ProjectResponse](docs/ProjectResponse.md) - - [ProjectResponseArray](docs/ProjectResponseArray.md) - - [ProjectResponseCompletedBy](docs/ProjectResponseCompletedBy.md) - - [ProjectResponseCreatedFromTemplate](docs/ProjectResponseCreatedFromTemplate.md) - - [ProjectResponseData](docs/ProjectResponseData.md) - - [ProjectResponseProjectBrief](docs/ProjectResponseProjectBrief.md) - - [ProjectResponseTeam](docs/ProjectResponseTeam.md) - - [ProjectResponseWorkspace](docs/ProjectResponseWorkspace.md) - - [ProjectSaveAsTemplateRequest](docs/ProjectSaveAsTemplateRequest.md) - - [ProjectSectionInsertRequest](docs/ProjectSectionInsertRequest.md) - - [ProjectStatusBase](docs/ProjectStatusBase.md) - - [ProjectStatusCompact](docs/ProjectStatusCompact.md) - - [ProjectStatusRequest](docs/ProjectStatusRequest.md) - - [ProjectStatusResponse](docs/ProjectStatusResponse.md) - - [ProjectStatusResponseArray](docs/ProjectStatusResponseArray.md) - - [ProjectStatusResponseData](docs/ProjectStatusResponseData.md) - - [ProjectTemplateBase](docs/ProjectTemplateBase.md) - - [ProjectTemplateBaseRequestedDates](docs/ProjectTemplateBaseRequestedDates.md) - - [ProjectTemplateBaseRequestedRoles](docs/ProjectTemplateBaseRequestedRoles.md) - - [ProjectTemplateBaseTeam](docs/ProjectTemplateBaseTeam.md) - - [ProjectTemplateCompact](docs/ProjectTemplateCompact.md) - - [ProjectTemplateGidInstantiateProjectBody](docs/ProjectTemplateGidInstantiateProjectBody.md) - - [ProjectTemplateInstantiateProjectRequest](docs/ProjectTemplateInstantiateProjectRequest.md) - - [ProjectTemplateInstantiateProjectRequestRequestedDates](docs/ProjectTemplateInstantiateProjectRequestRequestedDates.md) - - [ProjectTemplateInstantiateProjectRequestRequestedRoles](docs/ProjectTemplateInstantiateProjectRequestRequestedRoles.md) - - [ProjectTemplateResponse](docs/ProjectTemplateResponse.md) - - [ProjectTemplateResponseArray](docs/ProjectTemplateResponseArray.md) - - [ProjectTemplateResponseData](docs/ProjectTemplateResponseData.md) - - [ProjectUpdateRequest](docs/ProjectUpdateRequest.md) - - [ProjectsBody](docs/ProjectsBody.md) - - [ProjectsProjectGidBody](docs/ProjectsProjectGidBody.md) - - [RemoveCustomFieldSettingRequest](docs/RemoveCustomFieldSettingRequest.md) - - [RemoveFollowersRequest](docs/RemoveFollowersRequest.md) - - [RemoveMembersRequest](docs/RemoveMembersRequest.md) - - [RequestedRoleRequest](docs/RequestedRoleRequest.md) - - [RuleTriggerGidRunBody](docs/RuleTriggerGidRunBody.md) - - [RuleTriggerRequest](docs/RuleTriggerRequest.md) - - [RuleTriggerResponse](docs/RuleTriggerResponse.md) - - [RuleTriggerResponseData](docs/RuleTriggerResponseData.md) - - [SectionBase](docs/SectionBase.md) - - [SectionCompact](docs/SectionCompact.md) - - [SectionGidAddTaskBody](docs/SectionGidAddTaskBody.md) - - [SectionRequest](docs/SectionRequest.md) - - [SectionResponse](docs/SectionResponse.md) - - [SectionResponseArray](docs/SectionResponseArray.md) - - [SectionResponseData](docs/SectionResponseData.md) - - [SectionTaskInsertRequest](docs/SectionTaskInsertRequest.md) - - [SectionsInsertBody](docs/SectionsInsertBody.md) - - [SectionsSectionGidBody](docs/SectionsSectionGidBody.md) - - [StatusUpdateBase](docs/StatusUpdateBase.md) - - [StatusUpdateCompact](docs/StatusUpdateCompact.md) - - [StatusUpdateRequest](docs/StatusUpdateRequest.md) - - [StatusUpdateResponse](docs/StatusUpdateResponse.md) - - [StatusUpdateResponseArray](docs/StatusUpdateResponseArray.md) - - [StatusUpdateResponseData](docs/StatusUpdateResponseData.md) - - [StatusUpdateResponseParent](docs/StatusUpdateResponseParent.md) - - [StatusUpdatesBody](docs/StatusUpdatesBody.md) - - [StoriesStoryGidBody](docs/StoriesStoryGidBody.md) - - [StoryBase](docs/StoryBase.md) - - [StoryCompact](docs/StoryCompact.md) - - [StoryRequest](docs/StoryRequest.md) - - [StoryResponse](docs/StoryResponse.md) - - [StoryResponseArray](docs/StoryResponseArray.md) - - [StoryResponseAssignee](docs/StoryResponseAssignee.md) - - [StoryResponseCustomField](docs/StoryResponseCustomField.md) - - [StoryResponseData](docs/StoryResponseData.md) - - [StoryResponseDates](docs/StoryResponseDates.md) - - [StoryResponseOldDates](docs/StoryResponseOldDates.md) - - [StoryResponseOldEnumValue](docs/StoryResponseOldEnumValue.md) - - [StoryResponseOldSection](docs/StoryResponseOldSection.md) - - [StoryResponsePreviews](docs/StoryResponsePreviews.md) - - [StoryResponseProject](docs/StoryResponseProject.md) - - [StoryResponseStory](docs/StoryResponseStory.md) - - [StoryResponseTag](docs/StoryResponseTag.md) - - [StoryResponseTarget](docs/StoryResponseTarget.md) - - [StoryResponseTask](docs/StoryResponseTask.md) - - [TagBase](docs/TagBase.md) - - [TagCompact](docs/TagCompact.md) - - [TagCreateTagForWorkspaceRequest](docs/TagCreateTagForWorkspaceRequest.md) - - [TagRequest](docs/TagRequest.md) - - [TagResponse](docs/TagResponse.md) - - [TagResponseArray](docs/TagResponseArray.md) - - [TagResponseData](docs/TagResponseData.md) - - [TagsBody](docs/TagsBody.md) - - [TaskAddFollowersRequest](docs/TaskAddFollowersRequest.md) - - [TaskAddProjectRequest](docs/TaskAddProjectRequest.md) - - [TaskAddTagRequest](docs/TaskAddTagRequest.md) - - [TaskBase](docs/TaskBase.md) - - [TaskBaseCompletedBy](docs/TaskBaseCompletedBy.md) - - [TaskBaseDependencies](docs/TaskBaseDependencies.md) - - [TaskBaseExternal](docs/TaskBaseExternal.md) - - [TaskBaseMemberships](docs/TaskBaseMemberships.md) - - [TaskBaseSection](docs/TaskBaseSection.md) - - [TaskCompact](docs/TaskCompact.md) - - [TaskCountResponse](docs/TaskCountResponse.md) - - [TaskCountResponseData](docs/TaskCountResponseData.md) - - [TaskDuplicateRequest](docs/TaskDuplicateRequest.md) - - [TaskGidAddDependenciesBody](docs/TaskGidAddDependenciesBody.md) - - [TaskGidAddDependentsBody](docs/TaskGidAddDependentsBody.md) - - [TaskGidAddFollowersBody](docs/TaskGidAddFollowersBody.md) - - [TaskGidAddProjectBody](docs/TaskGidAddProjectBody.md) - - [TaskGidAddTagBody](docs/TaskGidAddTagBody.md) - - [TaskGidDuplicateBody](docs/TaskGidDuplicateBody.md) - - [TaskGidRemoveDependenciesBody](docs/TaskGidRemoveDependenciesBody.md) - - [TaskGidRemoveDependentsBody](docs/TaskGidRemoveDependentsBody.md) - - [TaskGidRemoveFollowersBody](docs/TaskGidRemoveFollowersBody.md) - - [TaskGidRemoveProjectBody](docs/TaskGidRemoveProjectBody.md) - - [TaskGidRemoveTagBody](docs/TaskGidRemoveTagBody.md) - - [TaskGidSetParentBody](docs/TaskGidSetParentBody.md) - - [TaskGidStoriesBody](docs/TaskGidStoriesBody.md) - - [TaskGidSubtasksBody](docs/TaskGidSubtasksBody.md) - - [TaskGidTimeTrackingEntriesBody](docs/TaskGidTimeTrackingEntriesBody.md) - - [TaskRemoveFollowersRequest](docs/TaskRemoveFollowersRequest.md) - - [TaskRemoveProjectRequest](docs/TaskRemoveProjectRequest.md) - - [TaskRemoveTagRequest](docs/TaskRemoveTagRequest.md) - - [TaskRequest](docs/TaskRequest.md) - - [TaskResponse](docs/TaskResponse.md) - - [TaskResponseArray](docs/TaskResponseArray.md) - - [TaskResponseAssigneeSection](docs/TaskResponseAssigneeSection.md) - - [TaskResponseCustomFields](docs/TaskResponseCustomFields.md) - - [TaskResponseData](docs/TaskResponseData.md) - - [TaskResponseParent](docs/TaskResponseParent.md) - - [TaskResponseTags](docs/TaskResponseTags.md) - - [TaskResponseWorkspace](docs/TaskResponseWorkspace.md) - - [TaskSetParentRequest](docs/TaskSetParentRequest.md) - - [TaskTemplateBase](docs/TaskTemplateBase.md) - - [TaskTemplateCompact](docs/TaskTemplateCompact.md) - - [TaskTemplateGidInstantiateTaskBody](docs/TaskTemplateGidInstantiateTaskBody.md) - - [TaskTemplateInstantiateTaskRequest](docs/TaskTemplateInstantiateTaskRequest.md) - - [TaskTemplateRecipe](docs/TaskTemplateRecipe.md) - - [TaskTemplateRecipeAttachments](docs/TaskTemplateRecipeAttachments.md) - - [TaskTemplateRecipeCompact](docs/TaskTemplateRecipeCompact.md) - - [TaskTemplateRecipeDependencies](docs/TaskTemplateRecipeDependencies.md) - - [TaskTemplateResponse](docs/TaskTemplateResponse.md) - - [TaskTemplateResponseArray](docs/TaskTemplateResponseArray.md) - - [TaskTemplateResponseData](docs/TaskTemplateResponseData.md) - - [TasksBody](docs/TasksBody.md) - - [TasksTaskGidBody](docs/TasksTaskGidBody.md) - - [TeamAddUserRequest](docs/TeamAddUserRequest.md) - - [TeamBase](docs/TeamBase.md) - - [TeamCompact](docs/TeamCompact.md) - - [TeamGidAddUserBody](docs/TeamGidAddUserBody.md) - - [TeamGidProjectsBody](docs/TeamGidProjectsBody.md) - - [TeamGidRemoveUserBody](docs/TeamGidRemoveUserBody.md) - - [TeamMembershipBase](docs/TeamMembershipBase.md) - - [TeamMembershipCompact](docs/TeamMembershipCompact.md) - - [TeamMembershipResponse](docs/TeamMembershipResponse.md) - - [TeamMembershipResponseArray](docs/TeamMembershipResponseArray.md) - - [TeamMembershipResponseData](docs/TeamMembershipResponseData.md) - - [TeamRemoveUserRequest](docs/TeamRemoveUserRequest.md) - - [TeamRequest](docs/TeamRequest.md) - - [TeamResponse](docs/TeamResponse.md) - - [TeamResponseArray](docs/TeamResponseArray.md) - - [TeamResponseData](docs/TeamResponseData.md) - - [TeamResponseOrganization](docs/TeamResponseOrganization.md) - - [TeamsBody](docs/TeamsBody.md) - - [TeamsTeamGidBody](docs/TeamsTeamGidBody.md) - - [TemplateRole](docs/TemplateRole.md) - - [TimePeriodBase](docs/TimePeriodBase.md) - - [TimePeriodCompact](docs/TimePeriodCompact.md) - - [TimePeriodResponse](docs/TimePeriodResponse.md) - - [TimePeriodResponseArray](docs/TimePeriodResponseArray.md) - - [TimePeriodResponseData](docs/TimePeriodResponseData.md) - - [TimeTrackingEntriesTimeTrackingEntryGidBody](docs/TimeTrackingEntriesTimeTrackingEntryGidBody.md) - - [TimeTrackingEntryBase](docs/TimeTrackingEntryBase.md) - - [TimeTrackingEntryBaseData](docs/TimeTrackingEntryBaseData.md) - - [TimeTrackingEntryCompact](docs/TimeTrackingEntryCompact.md) - - [TimeTrackingEntryCompactArray](docs/TimeTrackingEntryCompactArray.md) - - [UpdateTimeTrackingEntryRequest](docs/UpdateTimeTrackingEntryRequest.md) - - [UserBase](docs/UserBase.md) - - [UserBaseResponse](docs/UserBaseResponse.md) - - [UserBaseResponseData](docs/UserBaseResponseData.md) - - [UserBaseResponsePhoto](docs/UserBaseResponsePhoto.md) - - [UserCompact](docs/UserCompact.md) - - [UserRequest](docs/UserRequest.md) - - [UserResponse](docs/UserResponse.md) - - [UserResponseArray](docs/UserResponseArray.md) - - [UserResponseData](docs/UserResponseData.md) - - [UserTaskListBase](docs/UserTaskListBase.md) - - [UserTaskListCompact](docs/UserTaskListCompact.md) - - [UserTaskListRequest](docs/UserTaskListRequest.md) - - [UserTaskListResponse](docs/UserTaskListResponse.md) - - [UserTaskListResponseData](docs/UserTaskListResponseData.md) - - [WebhookCompact](docs/WebhookCompact.md) - - [WebhookCompactResource](docs/WebhookCompactResource.md) - - [WebhookFilter](docs/WebhookFilter.md) - - [WebhookRequest](docs/WebhookRequest.md) - - [WebhookRequestFilters](docs/WebhookRequestFilters.md) - - [WebhookResponse](docs/WebhookResponse.md) - - [WebhookResponseArray](docs/WebhookResponseArray.md) - - [WebhookResponseData](docs/WebhookResponseData.md) - - [WebhookUpdateRequest](docs/WebhookUpdateRequest.md) - - [WebhooksBody](docs/WebhooksBody.md) - - [WebhooksWebhookGidBody](docs/WebhooksWebhookGidBody.md) - - [WorkspaceAddUserRequest](docs/WorkspaceAddUserRequest.md) - - [WorkspaceBase](docs/WorkspaceBase.md) - - [WorkspaceCompact](docs/WorkspaceCompact.md) - - [WorkspaceGidAddUserBody](docs/WorkspaceGidAddUserBody.md) - - [WorkspaceGidProjectsBody](docs/WorkspaceGidProjectsBody.md) - - [WorkspaceGidRemoveUserBody](docs/WorkspaceGidRemoveUserBody.md) - - [WorkspaceGidTagsBody](docs/WorkspaceGidTagsBody.md) - - [WorkspaceMembershipBase](docs/WorkspaceMembershipBase.md) - - [WorkspaceMembershipCompact](docs/WorkspaceMembershipCompact.md) - - [WorkspaceMembershipRequest](docs/WorkspaceMembershipRequest.md) - - [WorkspaceMembershipResponse](docs/WorkspaceMembershipResponse.md) - - [WorkspaceMembershipResponseArray](docs/WorkspaceMembershipResponseArray.md) - - [WorkspaceMembershipResponseData](docs/WorkspaceMembershipResponseData.md) - - [WorkspaceMembershipResponseUserTaskList](docs/WorkspaceMembershipResponseUserTaskList.md) - - [WorkspaceMembershipResponseVacationDates](docs/WorkspaceMembershipResponseVacationDates.md) - - [WorkspaceRemoveUserRequest](docs/WorkspaceRemoveUserRequest.md) - - [WorkspaceRequest](docs/WorkspaceRequest.md) - - [WorkspaceResponse](docs/WorkspaceResponse.md) - - [WorkspaceResponseArray](docs/WorkspaceResponseArray.md) - - [WorkspaceResponseData](docs/WorkspaceResponseData.md) - - [WorkspacesWorkspaceGidBody](docs/WorkspacesWorkspaceGidBody.md) - -## Documentation For Authorization - - -## oauth2 - -- **Type**: OAuth -- **Flow**: accessCode -- **Authorization URL**: https://app.asana.com/-/oauth_authorize -- **Scopes**: - - **default**: Provides access to all endpoints documented in our API reference. If no scopes are requested, this scope is assumed by default. - - **openid**: Provides access to OpenID Connect ID tokens and the OpenID Connect user info endpoint. - - **email**: Provides access to the user’s email through the OpenID Connect user info endpoint. - - **profile**: Provides access to the user’s name and profile photo through the OpenID Connect user info endpoint. - - -## Getting events - -In order to get events you will need a sync token. This sync token can be acquired in the error message from the initial -request to [get_events](docs/EventsApi.md#get_events). - -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -events_api_instance = asana.EventsApi(api_client) -resource = '12345' # str | A resource ID to subscribe to. The resource can be a task or project. -sync = '' # str | A sync token received from the last request, or none on first sync. Events will be returned from the point in time that the sync token was generated. *Note: On your first request, omit the sync token. The response will be the same as for an expired sync token, and will include a new valid sync token.If the sync token is too old (which may happen from time to time) the API will return a `412 Precondition Failed` error, and include a fresh sync token in the response.* (optional) - -try: - # Initial request to get the sync token - api_response = events_api_instance.get_events(resource, sync=sync) -except ApiException as e: - # Set the sync token - sync = json.loads(e.body.decode('utf-8'))['sync'] - -try: - # Follow up request to get events - api_response = events_api_instance.get_events(resource, sync=sync) - pprint(api_response) -except ApiException as e: - print("Exception when calling EventsApi->get_events: %s\n" % e) -``` - -## Pagination - -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -task_api_instance = asana.TasksApi(api_client) -limit = 10 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -project = '321654' # str | The project to filter tasks on. (optional) - -try: - # Get multiple tasks with next_page + +Redirect the user to the authorization URL obtained from the client's `session` object: + + (url, state) = client.session.authorization_url() + +When the user is redirected back to your callback, check the `state` URL parameter matches, then pass the `code` parameter to obtain a bearer token: + + if request.params['state'] == state: + token = client.session.fetch_token(code=request.params['code']) + # ... + else: + # error! possible CSRF attack + +Note: if you're writing a non-browser-based application (e.x. a command line tool) you can use the special redirect URI `urn:ietf:wg:oauth:2.0:oob` to prompt the user to copy and paste the code into the application. + +Usage +----- + +The client's methods are divided into several resources: `attachments`, `events`, `jobs`, `portfolios`, `portfolio_memberships`, `projects`, `project_memberships`, `stories`, `tags`, `tasks`, `teams`, `users`, `user_task_lists`, and `workspaces`. + +Methods that return a single object return that object directly: + + me = client.users.get_user('me') + print(f'Hello {me['name']}') + + workspace_id = me['workspaces'][0]['gid'] + project = client.projects.create_in_workspace(workspace_id, { 'name': 'new project' }) + print(f'Created project with id: {project['gid']}') + +Methods that return multiple items (e.x. `get_tasks`, `get_projects`, `get_portfolios`, etc.) return a page iterator by default. See the "Collections" section. + +#### See [the gen folder](asana/resources/gen) for methods available for each resource. + +Options +------- + +Various options can be set globally on the `Client.DEFAULTS` object, per-client on `client.options`, or per-request as additional named arguments. For example: + + # global: + asana.Client.DEFAULT_OPTIONS['page_size'] = 100 + + # per-client: + client.options['page_size'] = 100 + + # per-request: + client.tasks.get_tasks({ 'project': 1234 }, page_size=100) + +### Available options + +* `base_url` (default: "https://app.asana.com/api/1.0"): API endpoint base URL to connect to +* `max_retries` (default: 5): number to times to retry if API rate limit is reached or a server error occures. Rate limit retries delay until the rate limit expires, server errors exponentially backoff starting with a 1 second delay. +* `full_payload` (default: False): return the entire JSON response instead of the 'data' propery (default for collection methods and `events.get`) +* `fields` and `expand`: see [API documentation](https://asana.com/developers/documentation/getting-started/input-output-options) + +Collections (methods returning an array as its 'data' property): + +* `iterator_type` (default: "items"): specifies which type of iterator (or not) to return. Valid values are "items" and `None`. +* `item_limit` (default: None): limits the number of items of a collection to return. +* `page_size` (default: 50): limits the number of items per page to fetch at a time. +* `offset`: offset token returned by previous calls to the same method (in `response['next_page']['offset']`) + +Events: + +* `poll_interval` (default: 5): polling interval for getting new events via `events.get_next` and `events.get_iterator` +* `sync`: sync token returned by previous calls to `events.get` (in `response['sync']`) + +### Asana Change Warnings + +You will receive warning logs if performing requests that may be affected by a deprecation. The warning contains a link that explains the deprecation. + +If you receive one of these warnings, you should: +* Read about the deprecation. +* Resolve sections of your code that would be affected by the deprecation. +* Add the deprecation flag to your "asana-enable" header. + +You can place it on the client for all requests, or place it on a single request. + + client.headers={'asana-enable': 'string_ids'} + or + me = client.users.get_user('me', headers={'asana-enable': 'string_ids'}) + +If you would rather suppress these warnings, you can set + + client.LOG_ASANA_CHANGE_WARNINGS = False + +Collections +----------- + +### Items Iterator + +By default, methods that return a collection of objects return an item iterator: + + workspaces = client.workspaces.get_workspaces(item_limit=1) + print(next(workspaces)) + print(next(workspaces)) # raises StopIteration if there are no more items + +Or: + + for workspace in client.workspaces.get_workspaces() + print(workspace) + +### Raw API + +You can also use the raw API to fetch a page at a time: + offset = None while True: - # If the "offset" is None make a request without providing the offset query parameter - # Asana throws an error if we make a request with a "offset" query param of None - if offset is None: - api_response = task_api_instance.get_tasks(limit=limit, project=project) - else: - api_response = task_api_instance.get_tasks(limit=limit, project=project, offset=offset) - - # Do something - # EX: print response - pprint(api_response) - - # Check to see if there is a next_page - if api_response.next_page: - offset = api_response.next_page.offset - else: - break -except ApiException as e: - print("Exception when calling TasksApi->get_tasks: %s\n" % e) -``` - -## Accessing repsonse data - -By default, the client library returns a class object of the resource. You can use dot notation to access the response data. - -TIP: look at the "Return type" section of the documented endpoint to understand which properties are accessible. (EX: [get_task](docs/TasksApi.md#get_task)) - -### Example: Accessing task data (dot notation) -```python -. -. -. -try: - task = tasks_api_instance.get_task(task_gid).data - task_name = task.name - task_notes = task.notes -except ApiException as e: - . - . - . -``` - -If you would like to convert the class object into a dictionary and access the data via bracket notation, you can use the `to_dict()` method. - -### Example: Accessing task data (bracket notation) -```python -. -. -. -try: - task_dict = tasks_api_instance.get_task(task_gid).to_dict() - task_dict_data = task_dict['data'] - task_name = task_dict_data['name'] - task_notes = task_dict_data['notes'] -except ApiException as e: - . - . - . -``` - -## Accessing response status code and headers - -In the scenario you want to access the response headers or the status code along with the response data you can -provide the `_return_http_data_only` parameter argument in the request method and set the value to `False` - -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.UsersApi(api_client) -user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - -try: - # Get a user - Add asana-enable in the request - api_response = api_instance.get_user(user_gid, _return_http_data_only=False) # returns a tuple: (object, status, headers) - pprint(api_response) -except ApiException as e: - print("Exception when calling UsersApi->get_user: %s\n" % e) -``` - -## Adding deprecation flag to your "asana-enable" header - -### On the client -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# Add asana-enable header for the client -api_client.default_headers['asana-enable'] = 'string_ids' -``` - -OR - -### On the request -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.UsersApi(api_client) -user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - -try: - # Get a user - Add asana-enable in the request - api_response = api_instance.get_user(user_gid, header_params={'asana-enable': 'string_ids'}) - pprint(api_response) -except ApiException as e: - print("Exception when calling UsersApi->get_user: %s\n" % e) -``` - -## Documentation for Using the `call_api` method - -Use this to make HTTP calls when the endpoint does not exist in the current library version or has bugs - -### Example: GET, POST, PUT, DELETE on tasks - -#### GET - get a task -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -try: - # GET - get a task - api_response = api_client.call_api( - "/tasks/{task_gid}", - "GET", - path_params={"task_gid": ""}, - query_params=[], - header_params={"Accept": "application/json; charset=utf-8"}, - body=None, - post_params=[], - files={}, - response_type=object, # If there is an existing response model for the resource you can use that EX: "TaskResponseData" or you can specify one of the following types: float, bool, bytes, str, object - auth_settings=["oauth2"], - async_req=None, - _return_http_data_only=True, - _preload_content=True, - _request_timeout=None, - collection_formats={}, - ) - pprint(api_response) -except ApiException as e: - print("Exception: %s\n" % e) -``` - -#### GET - get multiple tasks -> with opt_fields -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -try: - # GET - get multiple tasks - api_response = api_client.call_api( - "/tasks", - "GET", - path_params={}, - query_params=[('opt_fields', 'name,notes,projects')], - header_params={"Accept": "application/json; charset=utf-8"}, - body=None, - post_params=[], - files={}, - response_type=object, # If there is an existing response model for the resource you can use that EX: "TaskResponseData" or you can specify one of the following types: float, bool, bytes, str, object - auth_settings=["oauth2"], - async_req=None, - _return_http_data_only=True, - _preload_content=True, - _request_timeout=None, - collection_formats={}, - ) - pprint(api_response) -except ApiException as e: - print("Exception: %s\n" % e) -``` - -#### POST - create a task -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -try: - # POST - create a task - api_response = api_client.call_api( - "/tasks", - "POST", - path_params={}, - query_params=[], - header_params={ - "Accept": "application/json; charset=utf-8", - "Content-Type": "application/json; charset=utf-8", - }, - body={ - "data": { - "name": "New Task", - "projects": [""], - } - }, - post_params=[], - files={}, - response_type=object, # If there is an existing response model for the resource you can use that EX: "TaskResponseData" or you can specify one of the following types: float, bool, bytes, str, object - auth_settings=["oauth2"], - async_req=None, - _return_http_data_only=True, - _preload_content=True, - _request_timeout=None, - collection_formats={}, - ) - pprint(api_response) -except ApiException as e: - print("Exception: %s\n" % e) -``` - -#### PUT - update a task -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -try: - # PUT - update a task - api_response = api_client.call_api( - "/tasks/{task_gid}", - "PUT", - path_params={"task_gid": ""}, - query_params=[], - header_params={ - "Accept": "application/json; charset=utf-8", - "Content-Type": "application/json; charset=utf-8", - }, - body={ - "data": { - "name": "Updated Task", - } - }, - post_params=[], - files={}, - response_type=object, # If there is an existing response model for the resource you can use that EX: "TaskResponseData" or you can specify one of the following types: float, bool, bytes, str, object - auth_settings=["oauth2"], - async_req=None, - _return_http_data_only=True, - _preload_content=True, - _request_timeout=None, - collection_formats={}, - ) - pprint(api_response) -except ApiException as e: - print("Exception: %s\n" % e) -``` - -#### DELETE - delete a task -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -try: - # DELETE - delete a task - api_response = api_client.call_api( - "/tasks/{task_gid}", - "DELETE", - path_params={"task_gid": ""}, - query_params=[], - header_params={"Accept": "application/json; charset=utf-8"}, - body=None, - post_params=[], - files={}, - response_type=object, # If there is an existing response model for the resource you can use that EX: "EmptyResponseData" or you can specify one of the following types: float, bool, bytes, str, object - auth_settings=["oauth2"], - async_req=None, - _return_http_data_only=True, - _preload_content=True, - _request_timeout=None, - collection_formats={}, - ) - pprint(api_response) -except ApiException as e: - print("Exception: %s\n" % e) -``` + page = client.workspaces.get_workspaces(offset=offset, iterator_type=None, full_payload=True) + print(page['data']) + if 'next_page' in page and page['next_page']: + offset = page['next_page']['offset'] + else: + break -## Author +Contributing +------------ +Feel free to fork and submit pull requests for the code! Please follow the +existing code as an example of style and make sure that all your code passes +lint and tests. +### Code generation -[release-image]: https://img.shields.io/github/release/asana/python-asana.svg +The specific Asana resource classes under `gen` (`_Tag`, `_Workspace`, `_Task`, etc) are +generated code, hence they shouldn't be modified by hand. + +### Deployment + +**Repo Owners Only.** Take the following steps to issue a new release of the library. + +#### Automatic Deployment + +Run `deploy.py [major|minor|patch]`. See `deploy.py -h` for additional info. + +#### Manual Deployment + + 1. Merge in the desired changes into the `master` branch and commit them. + 2. Clone the repo, work on master. + 3. Edit package version in `asana/__init__.py` and `./VERSION` to indicate the [semantic version](http://semver.org/) change. + 4. Commit the change + 5. Tag the commit with `v` plus the same version number you set in the file. + `git tag v1.2.3` + 6. Push changes to origin, including tags: + `git push origin master --tags` + +GitHub Actions will automatically build and deploy the tagged release to [PyPI](https://pypi.org/). -[github-actions-image]: https://github.com/Asana/python-asana/workflows/Build/badge.svg [github-actions-url]: https://github.com/Asana/python-asana/actions +[github-actions-image]: https://github.com/Asana/python-asana/workflows/Build/badge.svg -[pypi-image]: https://img.shields.io/pypi/v/asana.svg?style=flat-square [pypi-url]: https://pypi.python.org/pypi/asana/ +[pypi-image]: https://img.shields.io/pypi/v/asana.svg?style=flat-square + +[asana-docs]: https://developers.asana.com/docs diff --git a/TESTING b/TESTING new file mode 100644 index 00000000..d1917e59 --- /dev/null +++ b/TESTING @@ -0,0 +1,4 @@ +Unit tests +---------- + + py.test tests diff --git a/VERSION b/VERSION new file mode 100644 index 00000000..0444f320 --- /dev/null +++ b/VERSION @@ -0,0 +1 @@ +3.2.1 \ No newline at end of file diff --git a/asana/__init__.py b/asana/__init__.py index f9bb4320..863b9d31 100644 --- a/asana/__init__.py +++ b/asana/__init__.py @@ -1,492 +1,6 @@ -# coding: utf-8 +__title__ = 'asana' +__license__ = 'MIT' +__copyright__ = 'Copyright 2016 Asana, Inc.' -# flake8: noqa - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -# import apis into sdk package -from asana.api.attachments_api import AttachmentsApi -from asana.api.audit_log_api_api import AuditLogAPIApi -from asana.api.batch_api_api import BatchAPIApi -from asana.api.custom_field_settings_api import CustomFieldSettingsApi -from asana.api.custom_fields_api import CustomFieldsApi -from asana.api.events_api import EventsApi -from asana.api.goal_relationships_api import GoalRelationshipsApi -from asana.api.goals_api import GoalsApi -from asana.api.jobs_api import JobsApi -from asana.api.memberships_api import MembershipsApi -from asana.api.organization_exports_api import OrganizationExportsApi -from asana.api.portfolio_memberships_api import PortfolioMembershipsApi -from asana.api.portfolios_api import PortfoliosApi -from asana.api.project_briefs_api import ProjectBriefsApi -from asana.api.project_memberships_api import ProjectMembershipsApi -from asana.api.project_statuses_api import ProjectStatusesApi -from asana.api.project_templates_api import ProjectTemplatesApi -from asana.api.projects_api import ProjectsApi -from asana.api.rules_api import RulesApi -from asana.api.sections_api import SectionsApi -from asana.api.status_updates_api import StatusUpdatesApi -from asana.api.stories_api import StoriesApi -from asana.api.tags_api import TagsApi -from asana.api.task_templates_api import TaskTemplatesApi -from asana.api.tasks_api import TasksApi -from asana.api.team_memberships_api import TeamMembershipsApi -from asana.api.teams_api import TeamsApi -from asana.api.time_periods_api import TimePeriodsApi -from asana.api.time_tracking_entries_api import TimeTrackingEntriesApi -from asana.api.typeahead_api import TypeaheadApi -from asana.api.user_task_lists_api import UserTaskListsApi -from asana.api.users_api import UsersApi -from asana.api.webhooks_api import WebhooksApi -from asana.api.workspace_memberships_api import WorkspaceMembershipsApi -from asana.api.workspaces_api import WorkspacesApi -# import ApiClient -from asana.api_client import ApiClient -from asana.configuration import Configuration -# import models into sdk package -from asana.models.add_custom_field_setting_request import AddCustomFieldSettingRequest -from asana.models.add_followers_request import AddFollowersRequest -from asana.models.add_members_request import AddMembersRequest -from asana.models.all_of_project_response_owner import AllOfProjectResponseOwner -from asana.models.all_of_project_template_base_owner import AllOfProjectTemplateBaseOwner -from asana.models.all_of_project_template_response_owner import AllOfProjectTemplateResponseOwner -from asana.models.all_of_story_response_new_date_value import AllOfStoryResponseNewDateValue -from asana.models.all_of_story_response_old_date_value import AllOfStoryResponseOldDateValue -from asana.models.all_of_task_template_response_created_by import AllOfTaskTemplateResponseCreatedBy -from asana.models.all_of_task_template_response_project import AllOfTaskTemplateResponseProject -from asana.models.all_of_task_template_response_template import AllOfTaskTemplateResponseTemplate -from asana.models.all_of_user_task_list_base_owner import AllOfUserTaskListBaseOwner -from asana.models.all_of_user_task_list_base_workspace import AllOfUserTaskListBaseWorkspace -from asana.models.all_of_user_task_list_compact_owner import AllOfUserTaskListCompactOwner -from asana.models.all_of_user_task_list_compact_workspace import AllOfUserTaskListCompactWorkspace -from asana.models.all_of_user_task_list_request_owner import AllOfUserTaskListRequestOwner -from asana.models.all_of_user_task_list_request_workspace import AllOfUserTaskListRequestWorkspace -from asana.models.all_of_user_task_list_response_owner import AllOfUserTaskListResponseOwner -from asana.models.all_of_user_task_list_response_workspace import AllOfUserTaskListResponseWorkspace -from asana.models.all_of_workspace_membership_response_user_task_list_owner import AllOfWorkspaceMembershipResponseUserTaskListOwner -from asana.models.all_of_workspace_membership_response_user_task_list_workspace import AllOfWorkspaceMembershipResponseUserTaskListWorkspace -from asana.models.asana_named_resource import AsanaNamedResource -from asana.models.asana_named_resource_array import AsanaNamedResourceArray -from asana.models.asana_resource import AsanaResource -from asana.models.attachment_base import AttachmentBase -from asana.models.attachment_compact import AttachmentCompact -from asana.models.attachment_request import AttachmentRequest -from asana.models.attachment_response import AttachmentResponse -from asana.models.attachment_response_array import AttachmentResponseArray -from asana.models.attachment_response_data import AttachmentResponseData -from asana.models.attachment_response_parent import AttachmentResponseParent -from asana.models.attachment_response_parent_created_by import AttachmentResponseParentCreatedBy -from asana.models.audit_log_event import AuditLogEvent -from asana.models.audit_log_event_actor import AuditLogEventActor -from asana.models.audit_log_event_array import AuditLogEventArray -from asana.models.audit_log_event_context import AuditLogEventContext -from asana.models.audit_log_event_details import AuditLogEventDetails -from asana.models.audit_log_event_resource import AuditLogEventResource -from asana.models.batch_body import BatchBody -from asana.models.batch_request import BatchRequest -from asana.models.batch_request_action import BatchRequestAction -from asana.models.batch_request_actions import BatchRequestActions -from asana.models.batch_request_options import BatchRequestOptions -from asana.models.batch_response import BatchResponse -from asana.models.batch_response_array import BatchResponseArray -from asana.models.create_membership_request import CreateMembershipRequest -from asana.models.create_time_tracking_entry_request import CreateTimeTrackingEntryRequest -from asana.models.custom_field_base import CustomFieldBase -from asana.models.custom_field_base_date_value import CustomFieldBaseDateValue -from asana.models.custom_field_base_enum_options import CustomFieldBaseEnumOptions -from asana.models.custom_field_base_enum_value import CustomFieldBaseEnumValue -from asana.models.custom_field_compact import CustomFieldCompact -from asana.models.custom_field_gid_enum_options_body import CustomFieldGidEnumOptionsBody -from asana.models.custom_field_request import CustomFieldRequest -from asana.models.custom_field_response import CustomFieldResponse -from asana.models.custom_field_response_array import CustomFieldResponseArray -from asana.models.custom_field_response_created_by import CustomFieldResponseCreatedBy -from asana.models.custom_field_response_data import CustomFieldResponseData -from asana.models.custom_field_response_people_value import CustomFieldResponsePeopleValue -from asana.models.custom_field_setting_base import CustomFieldSettingBase -from asana.models.custom_field_setting_compact import CustomFieldSettingCompact -from asana.models.custom_field_setting_response import CustomFieldSettingResponse -from asana.models.custom_field_setting_response_array import CustomFieldSettingResponseArray -from asana.models.custom_field_setting_response_custom_field import CustomFieldSettingResponseCustomField -from asana.models.custom_field_setting_response_data import CustomFieldSettingResponseData -from asana.models.custom_field_setting_response_parent import CustomFieldSettingResponseParent -from asana.models.custom_field_setting_response_project import CustomFieldSettingResponseProject -from asana.models.custom_fields_body import CustomFieldsBody -from asana.models.custom_fields_custom_field_gid_body import CustomFieldsCustomFieldGidBody -from asana.models.date_variable_compact import DateVariableCompact -from asana.models.date_variable_request import DateVariableRequest -from asana.models.empty_response import EmptyResponse -from asana.models.empty_response_data import EmptyResponseData -from asana.models.enum_option import EnumOption -from asana.models.enum_option_base import EnumOptionBase -from asana.models.enum_option_data import EnumOptionData -from asana.models.enum_option_insert_request import EnumOptionInsertRequest -from asana.models.enum_option_request import EnumOptionRequest -from asana.models.enum_options_enum_option_gid_body import EnumOptionsEnumOptionGidBody -from asana.models.enum_options_insert_body import EnumOptionsInsertBody -from asana.models.error import Error -from asana.models.error_response import ErrorResponse -from asana.models.error_response_errors import ErrorResponseErrors -from asana.models.event_response import EventResponse -from asana.models.event_response_array import EventResponseArray -from asana.models.event_response_change import EventResponseChange -from asana.models.event_response_parent import EventResponseParent -from asana.models.event_response_resource import EventResponseResource -from asana.models.event_response_user import EventResponseUser -from asana.models.goal_add_subgoal_request import GoalAddSubgoalRequest -from asana.models.goal_add_supporting_relationship_request import GoalAddSupportingRelationshipRequest -from asana.models.goal_add_supporting_work_request import GoalAddSupportingWorkRequest -from asana.models.goal_base import GoalBase -from asana.models.goal_compact import GoalCompact -from asana.models.goal_gid_add_followers_body import GoalGidAddFollowersBody -from asana.models.goal_gid_add_supporting_relationship_body import GoalGidAddSupportingRelationshipBody -from asana.models.goal_gid_remove_followers_body import GoalGidRemoveFollowersBody -from asana.models.goal_gid_remove_supporting_relationship_body import GoalGidRemoveSupportingRelationshipBody -from asana.models.goal_gid_set_metric_body import GoalGidSetMetricBody -from asana.models.goal_gid_set_metric_current_value_body import GoalGidSetMetricCurrentValueBody -from asana.models.goal_membership_base import GoalMembershipBase -from asana.models.goal_membership_compact import GoalMembershipCompact -from asana.models.goal_membership_response import GoalMembershipResponse -from asana.models.goal_membership_response_user import GoalMembershipResponseUser -from asana.models.goal_membership_response_workspace import GoalMembershipResponseWorkspace -from asana.models.goal_metric_base import GoalMetricBase -from asana.models.goal_metric_current_value_request import GoalMetricCurrentValueRequest -from asana.models.goal_metric_request import GoalMetricRequest -from asana.models.goal_relationship_base import GoalRelationshipBase -from asana.models.goal_relationship_base_supported_goal import GoalRelationshipBaseSupportedGoal -from asana.models.goal_relationship_base_supporting_resource import GoalRelationshipBaseSupportingResource -from asana.models.goal_relationship_compact import GoalRelationshipCompact -from asana.models.goal_relationship_request import GoalRelationshipRequest -from asana.models.goal_relationship_response import GoalRelationshipResponse -from asana.models.goal_relationship_response_array import GoalRelationshipResponseArray -from asana.models.goal_relationship_response_data import GoalRelationshipResponseData -from asana.models.goal_relationships_goal_relationship_gid_body import GoalRelationshipsGoalRelationshipGidBody -from asana.models.goal_remove_subgoal_request import GoalRemoveSubgoalRequest -from asana.models.goal_remove_supporting_relationship_request import GoalRemoveSupportingRelationshipRequest -from asana.models.goal_request import GoalRequest -from asana.models.goal_request_base import GoalRequestBase -from asana.models.goal_response import GoalResponse -from asana.models.goal_response_array import GoalResponseArray -from asana.models.goal_response_current_status_update import GoalResponseCurrentStatusUpdate -from asana.models.goal_response_data import GoalResponseData -from asana.models.goal_response_likes import GoalResponseLikes -from asana.models.goal_response_metric import GoalResponseMetric -from asana.models.goal_response_team import GoalResponseTeam -from asana.models.goal_response_time_period import GoalResponseTimePeriod -from asana.models.goal_response_workspace import GoalResponseWorkspace -from asana.models.goal_update_request import GoalUpdateRequest -from asana.models.goals_body import GoalsBody -from asana.models.goals_goal_gid_body import GoalsGoalGidBody -from asana.models.inline_response412 import InlineResponse412 -from asana.models.inline_response412_errors import InlineResponse412Errors -from asana.models.job_base import JobBase -from asana.models.job_base_new_project import JobBaseNewProject -from asana.models.job_base_new_project_template import JobBaseNewProjectTemplate -from asana.models.job_base_new_task import JobBaseNewTask -from asana.models.job_compact import JobCompact -from asana.models.job_response import JobResponse -from asana.models.job_response_data import JobResponseData -from asana.models.like import Like -from asana.models.member_compact import MemberCompact -from asana.models.membership_compact import MembershipCompact -from asana.models.membership_compact_goal import MembershipCompactGoal -from asana.models.membership_compact_member import MembershipCompactMember -from asana.models.membership_compact_parent import MembershipCompactParent -from asana.models.membership_request import MembershipRequest -from asana.models.membership_response import MembershipResponse -from asana.models.membership_response_array import MembershipResponseArray -from asana.models.membership_response_data import MembershipResponseData -from asana.models.memberships_body import MembershipsBody -from asana.models.modify_dependencies_request import ModifyDependenciesRequest -from asana.models.modify_dependents_request import ModifyDependentsRequest -from asana.models.next_page import NextPage -from asana.models.organization_export_base import OrganizationExportBase -from asana.models.organization_export_compact import OrganizationExportCompact -from asana.models.organization_export_request import OrganizationExportRequest -from asana.models.organization_export_response import OrganizationExportResponse -from asana.models.organization_export_response_data import OrganizationExportResponseData -from asana.models.organization_exports_body import OrganizationExportsBody -from asana.models.portfolio_add_item_request import PortfolioAddItemRequest -from asana.models.portfolio_base import PortfolioBase -from asana.models.portfolio_compact import PortfolioCompact -from asana.models.portfolio_gid_add_custom_field_setting_body import PortfolioGidAddCustomFieldSettingBody -from asana.models.portfolio_gid_add_item_body import PortfolioGidAddItemBody -from asana.models.portfolio_gid_add_members_body import PortfolioGidAddMembersBody -from asana.models.portfolio_gid_remove_custom_field_setting_body import PortfolioGidRemoveCustomFieldSettingBody -from asana.models.portfolio_gid_remove_item_body import PortfolioGidRemoveItemBody -from asana.models.portfolio_gid_remove_members_body import PortfolioGidRemoveMembersBody -from asana.models.portfolio_membership_base import PortfolioMembershipBase -from asana.models.portfolio_membership_base_portfolio import PortfolioMembershipBasePortfolio -from asana.models.portfolio_membership_compact import PortfolioMembershipCompact -from asana.models.portfolio_membership_response import PortfolioMembershipResponse -from asana.models.portfolio_membership_response_array import PortfolioMembershipResponseArray -from asana.models.portfolio_membership_response_data import PortfolioMembershipResponseData -from asana.models.portfolio_remove_item_request import PortfolioRemoveItemRequest -from asana.models.portfolio_request import PortfolioRequest -from asana.models.portfolio_response import PortfolioResponse -from asana.models.portfolio_response_array import PortfolioResponseArray -from asana.models.portfolio_response_current_status_update import PortfolioResponseCurrentStatusUpdate -from asana.models.portfolio_response_custom_field_settings import PortfolioResponseCustomFieldSettings -from asana.models.portfolio_response_custom_fields import PortfolioResponseCustomFields -from asana.models.portfolio_response_data import PortfolioResponseData -from asana.models.portfolio_response_workspace import PortfolioResponseWorkspace -from asana.models.portfolios_body import PortfoliosBody -from asana.models.portfolios_portfolio_gid_body import PortfoliosPortfolioGidBody -from asana.models.preview import Preview -from asana.models.project_base import ProjectBase -from asana.models.project_base_current_status import ProjectBaseCurrentStatus -from asana.models.project_base_current_status_update import ProjectBaseCurrentStatusUpdate -from asana.models.project_brief_base import ProjectBriefBase -from asana.models.project_brief_compact import ProjectBriefCompact -from asana.models.project_brief_request import ProjectBriefRequest -from asana.models.project_brief_response import ProjectBriefResponse -from asana.models.project_brief_response_data import ProjectBriefResponseData -from asana.models.project_brief_response_project import ProjectBriefResponseProject -from asana.models.project_briefs_project_brief_gid_body import ProjectBriefsProjectBriefGidBody -from asana.models.project_compact import ProjectCompact -from asana.models.project_duplicate_request import ProjectDuplicateRequest -from asana.models.project_duplicate_request_schedule_dates import ProjectDuplicateRequestScheduleDates -from asana.models.project_gid_add_custom_field_setting_body import ProjectGidAddCustomFieldSettingBody -from asana.models.project_gid_add_followers_body import ProjectGidAddFollowersBody -from asana.models.project_gid_add_members_body import ProjectGidAddMembersBody -from asana.models.project_gid_duplicate_body import ProjectGidDuplicateBody -from asana.models.project_gid_project_briefs_body import ProjectGidProjectBriefsBody -from asana.models.project_gid_project_statuses_body import ProjectGidProjectStatusesBody -from asana.models.project_gid_remove_custom_field_setting_body import ProjectGidRemoveCustomFieldSettingBody -from asana.models.project_gid_remove_followers_body import ProjectGidRemoveFollowersBody -from asana.models.project_gid_remove_members_body import ProjectGidRemoveMembersBody -from asana.models.project_gid_save_as_template_body import ProjectGidSaveAsTemplateBody -from asana.models.project_gid_sections_body import ProjectGidSectionsBody -from asana.models.project_membership_base import ProjectMembershipBase -from asana.models.project_membership_compact import ProjectMembershipCompact -from asana.models.project_membership_compact_array import ProjectMembershipCompactArray -from asana.models.project_membership_compact_response import ProjectMembershipCompactResponse -from asana.models.project_membership_compact_response_data import ProjectMembershipCompactResponseData -from asana.models.project_membership_normal_response import ProjectMembershipNormalResponse -from asana.models.project_membership_normal_response_data import ProjectMembershipNormalResponseData -from asana.models.project_request import ProjectRequest -from asana.models.project_response import ProjectResponse -from asana.models.project_response_array import ProjectResponseArray -from asana.models.project_response_completed_by import ProjectResponseCompletedBy -from asana.models.project_response_created_from_template import ProjectResponseCreatedFromTemplate -from asana.models.project_response_data import ProjectResponseData -from asana.models.project_response_project_brief import ProjectResponseProjectBrief -from asana.models.project_response_team import ProjectResponseTeam -from asana.models.project_response_workspace import ProjectResponseWorkspace -from asana.models.project_save_as_template_request import ProjectSaveAsTemplateRequest -from asana.models.project_section_insert_request import ProjectSectionInsertRequest -from asana.models.project_status_base import ProjectStatusBase -from asana.models.project_status_compact import ProjectStatusCompact -from asana.models.project_status_request import ProjectStatusRequest -from asana.models.project_status_response import ProjectStatusResponse -from asana.models.project_status_response_array import ProjectStatusResponseArray -from asana.models.project_status_response_data import ProjectStatusResponseData -from asana.models.project_template_base import ProjectTemplateBase -from asana.models.project_template_base_requested_dates import ProjectTemplateBaseRequestedDates -from asana.models.project_template_base_requested_roles import ProjectTemplateBaseRequestedRoles -from asana.models.project_template_base_team import ProjectTemplateBaseTeam -from asana.models.project_template_compact import ProjectTemplateCompact -from asana.models.project_template_gid_instantiate_project_body import ProjectTemplateGidInstantiateProjectBody -from asana.models.project_template_instantiate_project_request import ProjectTemplateInstantiateProjectRequest -from asana.models.project_template_instantiate_project_request_requested_dates import ProjectTemplateInstantiateProjectRequestRequestedDates -from asana.models.project_template_instantiate_project_request_requested_roles import ProjectTemplateInstantiateProjectRequestRequestedRoles -from asana.models.project_template_response import ProjectTemplateResponse -from asana.models.project_template_response_array import ProjectTemplateResponseArray -from asana.models.project_template_response_data import ProjectTemplateResponseData -from asana.models.project_update_request import ProjectUpdateRequest -from asana.models.projects_body import ProjectsBody -from asana.models.projects_project_gid_body import ProjectsProjectGidBody -from asana.models.remove_custom_field_setting_request import RemoveCustomFieldSettingRequest -from asana.models.remove_followers_request import RemoveFollowersRequest -from asana.models.remove_members_request import RemoveMembersRequest -from asana.models.requested_role_request import RequestedRoleRequest -from asana.models.rule_trigger_gid_run_body import RuleTriggerGidRunBody -from asana.models.rule_trigger_request import RuleTriggerRequest -from asana.models.rule_trigger_response import RuleTriggerResponse -from asana.models.rule_trigger_response_data import RuleTriggerResponseData -from asana.models.section_base import SectionBase -from asana.models.section_compact import SectionCompact -from asana.models.section_gid_add_task_body import SectionGidAddTaskBody -from asana.models.section_request import SectionRequest -from asana.models.section_response import SectionResponse -from asana.models.section_response_array import SectionResponseArray -from asana.models.section_response_data import SectionResponseData -from asana.models.section_task_insert_request import SectionTaskInsertRequest -from asana.models.sections_insert_body import SectionsInsertBody -from asana.models.sections_section_gid_body import SectionsSectionGidBody -from asana.models.status_update_base import StatusUpdateBase -from asana.models.status_update_compact import StatusUpdateCompact -from asana.models.status_update_request import StatusUpdateRequest -from asana.models.status_update_response import StatusUpdateResponse -from asana.models.status_update_response_array import StatusUpdateResponseArray -from asana.models.status_update_response_data import StatusUpdateResponseData -from asana.models.status_update_response_parent import StatusUpdateResponseParent -from asana.models.status_updates_body import StatusUpdatesBody -from asana.models.stories_story_gid_body import StoriesStoryGidBody -from asana.models.story_base import StoryBase -from asana.models.story_compact import StoryCompact -from asana.models.story_request import StoryRequest -from asana.models.story_response import StoryResponse -from asana.models.story_response_array import StoryResponseArray -from asana.models.story_response_assignee import StoryResponseAssignee -from asana.models.story_response_custom_field import StoryResponseCustomField -from asana.models.story_response_data import StoryResponseData -from asana.models.story_response_dates import StoryResponseDates -from asana.models.story_response_old_dates import StoryResponseOldDates -from asana.models.story_response_old_enum_value import StoryResponseOldEnumValue -from asana.models.story_response_old_section import StoryResponseOldSection -from asana.models.story_response_previews import StoryResponsePreviews -from asana.models.story_response_project import StoryResponseProject -from asana.models.story_response_story import StoryResponseStory -from asana.models.story_response_tag import StoryResponseTag -from asana.models.story_response_target import StoryResponseTarget -from asana.models.story_response_task import StoryResponseTask -from asana.models.tag_base import TagBase -from asana.models.tag_compact import TagCompact -from asana.models.tag_create_tag_for_workspace_request import TagCreateTagForWorkspaceRequest -from asana.models.tag_request import TagRequest -from asana.models.tag_response import TagResponse -from asana.models.tag_response_array import TagResponseArray -from asana.models.tag_response_data import TagResponseData -from asana.models.tags_body import TagsBody -from asana.models.task_add_followers_request import TaskAddFollowersRequest -from asana.models.task_add_project_request import TaskAddProjectRequest -from asana.models.task_add_tag_request import TaskAddTagRequest -from asana.models.task_base import TaskBase -from asana.models.task_base_completed_by import TaskBaseCompletedBy -from asana.models.task_base_dependencies import TaskBaseDependencies -from asana.models.task_base_external import TaskBaseExternal -from asana.models.task_base_memberships import TaskBaseMemberships -from asana.models.task_base_section import TaskBaseSection -from asana.models.task_compact import TaskCompact -from asana.models.task_count_response import TaskCountResponse -from asana.models.task_count_response_data import TaskCountResponseData -from asana.models.task_duplicate_request import TaskDuplicateRequest -from asana.models.task_gid_add_dependencies_body import TaskGidAddDependenciesBody -from asana.models.task_gid_add_dependents_body import TaskGidAddDependentsBody -from asana.models.task_gid_add_followers_body import TaskGidAddFollowersBody -from asana.models.task_gid_add_project_body import TaskGidAddProjectBody -from asana.models.task_gid_add_tag_body import TaskGidAddTagBody -from asana.models.task_gid_duplicate_body import TaskGidDuplicateBody -from asana.models.task_gid_remove_dependencies_body import TaskGidRemoveDependenciesBody -from asana.models.task_gid_remove_dependents_body import TaskGidRemoveDependentsBody -from asana.models.task_gid_remove_followers_body import TaskGidRemoveFollowersBody -from asana.models.task_gid_remove_project_body import TaskGidRemoveProjectBody -from asana.models.task_gid_remove_tag_body import TaskGidRemoveTagBody -from asana.models.task_gid_set_parent_body import TaskGidSetParentBody -from asana.models.task_gid_stories_body import TaskGidStoriesBody -from asana.models.task_gid_subtasks_body import TaskGidSubtasksBody -from asana.models.task_gid_time_tracking_entries_body import TaskGidTimeTrackingEntriesBody -from asana.models.task_remove_followers_request import TaskRemoveFollowersRequest -from asana.models.task_remove_project_request import TaskRemoveProjectRequest -from asana.models.task_remove_tag_request import TaskRemoveTagRequest -from asana.models.task_request import TaskRequest -from asana.models.task_response import TaskResponse -from asana.models.task_response_array import TaskResponseArray -from asana.models.task_response_assignee_section import TaskResponseAssigneeSection -from asana.models.task_response_custom_fields import TaskResponseCustomFields -from asana.models.task_response_data import TaskResponseData -from asana.models.task_response_parent import TaskResponseParent -from asana.models.task_response_tags import TaskResponseTags -from asana.models.task_response_workspace import TaskResponseWorkspace -from asana.models.task_set_parent_request import TaskSetParentRequest -from asana.models.task_template_base import TaskTemplateBase -from asana.models.task_template_compact import TaskTemplateCompact -from asana.models.task_template_gid_instantiate_task_body import TaskTemplateGidInstantiateTaskBody -from asana.models.task_template_instantiate_task_request import TaskTemplateInstantiateTaskRequest -from asana.models.task_template_recipe import TaskTemplateRecipe -from asana.models.task_template_recipe_attachments import TaskTemplateRecipeAttachments -from asana.models.task_template_recipe_compact import TaskTemplateRecipeCompact -from asana.models.task_template_recipe_dependencies import TaskTemplateRecipeDependencies -from asana.models.task_template_response import TaskTemplateResponse -from asana.models.task_template_response_array import TaskTemplateResponseArray -from asana.models.task_template_response_data import TaskTemplateResponseData -from asana.models.tasks_body import TasksBody -from asana.models.tasks_task_gid_body import TasksTaskGidBody -from asana.models.team_add_user_request import TeamAddUserRequest -from asana.models.team_base import TeamBase -from asana.models.team_compact import TeamCompact -from asana.models.team_gid_add_user_body import TeamGidAddUserBody -from asana.models.team_gid_projects_body import TeamGidProjectsBody -from asana.models.team_gid_remove_user_body import TeamGidRemoveUserBody -from asana.models.team_membership_base import TeamMembershipBase -from asana.models.team_membership_compact import TeamMembershipCompact -from asana.models.team_membership_response import TeamMembershipResponse -from asana.models.team_membership_response_array import TeamMembershipResponseArray -from asana.models.team_membership_response_data import TeamMembershipResponseData -from asana.models.team_remove_user_request import TeamRemoveUserRequest -from asana.models.team_request import TeamRequest -from asana.models.team_response import TeamResponse -from asana.models.team_response_array import TeamResponseArray -from asana.models.team_response_data import TeamResponseData -from asana.models.team_response_organization import TeamResponseOrganization -from asana.models.teams_body import TeamsBody -from asana.models.teams_team_gid_body import TeamsTeamGidBody -from asana.models.template_role import TemplateRole -from asana.models.time_period_base import TimePeriodBase -from asana.models.time_period_compact import TimePeriodCompact -from asana.models.time_period_response import TimePeriodResponse -from asana.models.time_period_response_array import TimePeriodResponseArray -from asana.models.time_period_response_data import TimePeriodResponseData -from asana.models.time_tracking_entries_time_tracking_entry_gid_body import TimeTrackingEntriesTimeTrackingEntryGidBody -from asana.models.time_tracking_entry_base import TimeTrackingEntryBase -from asana.models.time_tracking_entry_base_data import TimeTrackingEntryBaseData -from asana.models.time_tracking_entry_compact import TimeTrackingEntryCompact -from asana.models.time_tracking_entry_compact_array import TimeTrackingEntryCompactArray -from asana.models.update_time_tracking_entry_request import UpdateTimeTrackingEntryRequest -from asana.models.user_base import UserBase -from asana.models.user_base_response import UserBaseResponse -from asana.models.user_base_response_data import UserBaseResponseData -from asana.models.user_base_response_photo import UserBaseResponsePhoto -from asana.models.user_compact import UserCompact -from asana.models.user_request import UserRequest -from asana.models.user_response import UserResponse -from asana.models.user_response_array import UserResponseArray -from asana.models.user_response_data import UserResponseData -from asana.models.user_task_list_base import UserTaskListBase -from asana.models.user_task_list_compact import UserTaskListCompact -from asana.models.user_task_list_request import UserTaskListRequest -from asana.models.user_task_list_response import UserTaskListResponse -from asana.models.user_task_list_response_data import UserTaskListResponseData -from asana.models.webhook_compact import WebhookCompact -from asana.models.webhook_compact_resource import WebhookCompactResource -from asana.models.webhook_filter import WebhookFilter -from asana.models.webhook_request import WebhookRequest -from asana.models.webhook_request_filters import WebhookRequestFilters -from asana.models.webhook_response import WebhookResponse -from asana.models.webhook_response_array import WebhookResponseArray -from asana.models.webhook_response_data import WebhookResponseData -from asana.models.webhook_update_request import WebhookUpdateRequest -from asana.models.webhooks_body import WebhooksBody -from asana.models.webhooks_webhook_gid_body import WebhooksWebhookGidBody -from asana.models.workspace_add_user_request import WorkspaceAddUserRequest -from asana.models.workspace_base import WorkspaceBase -from asana.models.workspace_compact import WorkspaceCompact -from asana.models.workspace_gid_add_user_body import WorkspaceGidAddUserBody -from asana.models.workspace_gid_projects_body import WorkspaceGidProjectsBody -from asana.models.workspace_gid_remove_user_body import WorkspaceGidRemoveUserBody -from asana.models.workspace_gid_tags_body import WorkspaceGidTagsBody -from asana.models.workspace_membership_base import WorkspaceMembershipBase -from asana.models.workspace_membership_compact import WorkspaceMembershipCompact -from asana.models.workspace_membership_request import WorkspaceMembershipRequest -from asana.models.workspace_membership_response import WorkspaceMembershipResponse -from asana.models.workspace_membership_response_array import WorkspaceMembershipResponseArray -from asana.models.workspace_membership_response_data import WorkspaceMembershipResponseData -from asana.models.workspace_membership_response_user_task_list import WorkspaceMembershipResponseUserTaskList -from asana.models.workspace_membership_response_vacation_dates import WorkspaceMembershipResponseVacationDates -from asana.models.workspace_remove_user_request import WorkspaceRemoveUserRequest -from asana.models.workspace_request import WorkspaceRequest -from asana.models.workspace_response import WorkspaceResponse -from asana.models.workspace_response_array import WorkspaceResponseArray -from asana.models.workspace_response_data import WorkspaceResponseData -from asana.models.workspaces_workspace_gid_body import WorkspacesWorkspaceGidBody +from asana.version import __version__ +from .client import Client diff --git a/asana/api/__init__.py b/asana/api/__init__.py deleted file mode 100644 index df32f318..00000000 --- a/asana/api/__init__.py +++ /dev/null @@ -1,40 +0,0 @@ -from __future__ import absolute_import - -# flake8: noqa - -# import apis into api package -from asana.api.attachments_api import AttachmentsApi -from asana.api.audit_log_api_api import AuditLogAPIApi -from asana.api.batch_api_api import BatchAPIApi -from asana.api.custom_field_settings_api import CustomFieldSettingsApi -from asana.api.custom_fields_api import CustomFieldsApi -from asana.api.events_api import EventsApi -from asana.api.goal_relationships_api import GoalRelationshipsApi -from asana.api.goals_api import GoalsApi -from asana.api.jobs_api import JobsApi -from asana.api.memberships_api import MembershipsApi -from asana.api.organization_exports_api import OrganizationExportsApi -from asana.api.portfolio_memberships_api import PortfolioMembershipsApi -from asana.api.portfolios_api import PortfoliosApi -from asana.api.project_briefs_api import ProjectBriefsApi -from asana.api.project_memberships_api import ProjectMembershipsApi -from asana.api.project_statuses_api import ProjectStatusesApi -from asana.api.project_templates_api import ProjectTemplatesApi -from asana.api.projects_api import ProjectsApi -from asana.api.rules_api import RulesApi -from asana.api.sections_api import SectionsApi -from asana.api.status_updates_api import StatusUpdatesApi -from asana.api.stories_api import StoriesApi -from asana.api.tags_api import TagsApi -from asana.api.task_templates_api import TaskTemplatesApi -from asana.api.tasks_api import TasksApi -from asana.api.team_memberships_api import TeamMembershipsApi -from asana.api.teams_api import TeamsApi -from asana.api.time_periods_api import TimePeriodsApi -from asana.api.time_tracking_entries_api import TimeTrackingEntriesApi -from asana.api.typeahead_api import TypeaheadApi -from asana.api.user_task_lists_api import UserTaskListsApi -from asana.api.users_api import UsersApi -from asana.api.webhooks_api import WebhooksApi -from asana.api.workspace_memberships_api import WorkspaceMembershipsApi -from asana.api.workspaces_api import WorkspacesApi diff --git a/asana/api/attachments_api.py b/asana/api/attachments_api.py deleted file mode 100644 index 07c37796..00000000 --- a/asana/api/attachments_api.py +++ /dev/null @@ -1,464 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class AttachmentsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_attachment_for_object(self, **kwargs): # noqa: E501 - """Upload an attachment # noqa: E501 - - Upload an attachment. This method uploads an attachment on an object and returns the compact record for the created attachment object. This is possible by either: - Providing the URL of the external resource being attached, or - Downloading the file content first and then uploading it as any other attachment. Note that it is not possible to attach files from third party services such as Dropbox, Box, Vimeo & Google Drive via the API The 100MB size limit on attachments in Asana is enforced on this endpoint. This endpoint expects a multipart/form-data encoded request containing the full contents of the file to be uploaded. Requests made should follow the HTTP/1.1 specification that line terminators are of the form `CRLF` or `\\r\\n` outlined [here](http://www.w3.org/Protocols/HTTP/1.1/draft-ietf-http-v11-spec-01#Basic-Rules) in order for the server to reliably and properly handle the request. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_attachment_for_object(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str resource_subtype: - :param str file: - :param str parent: - :param str url: - :param str name: - :param bool connect_to_app: - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: AttachmentResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_attachment_for_object_with_http_info(**kwargs) # noqa: E501 - else: - (data) = self.create_attachment_for_object_with_http_info(**kwargs) # noqa: E501 - return data - - def create_attachment_for_object_with_http_info(self, **kwargs): # noqa: E501 - """Upload an attachment # noqa: E501 - - Upload an attachment. This method uploads an attachment on an object and returns the compact record for the created attachment object. This is possible by either: - Providing the URL of the external resource being attached, or - Downloading the file content first and then uploading it as any other attachment. Note that it is not possible to attach files from third party services such as Dropbox, Box, Vimeo & Google Drive via the API The 100MB size limit on attachments in Asana is enforced on this endpoint. This endpoint expects a multipart/form-data encoded request containing the full contents of the file to be uploaded. Requests made should follow the HTTP/1.1 specification that line terminators are of the form `CRLF` or `\\r\\n` outlined [here](http://www.w3.org/Protocols/HTTP/1.1/draft-ietf-http-v11-spec-01#Basic-Rules) in order for the server to reliably and properly handle the request. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_attachment_for_object_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str resource_subtype: - :param str file: - :param str parent: - :param str url: - :param str name: - :param bool connect_to_app: - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: AttachmentResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['resource_subtype', 'file', 'parent', 'url', 'name', 'connect_to_app', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_attachment_for_object" % key - ) - params[key] = val - del params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - if 'resource_subtype' in params: - form_params.append(('resource_subtype', params['resource_subtype'])) # noqa: E501 - if 'file' in params: - local_var_files['file'] = params['file'] # noqa: E501 - if 'parent' in params: - form_params.append(('parent', params['parent'])) # noqa: E501 - if 'url' in params: - form_params.append(('url', params['url'])) # noqa: E501 - if 'name' in params: - form_params.append(('name', params['name'])) # noqa: E501 - if 'connect_to_app' in params: - form_params.append(('connect_to_app', params['connect_to_app'])) # noqa: E501 - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['multipart/form-data']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/attachments', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='AttachmentResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_attachment(self, attachment_gid, **kwargs): # noqa: E501 - """Delete an attachment # noqa: E501 - - Deletes a specific, existing attachment. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_attachment(attachment_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str attachment_gid: Globally unique identifier for the attachment. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_attachment_with_http_info(attachment_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_attachment_with_http_info(attachment_gid, **kwargs) # noqa: E501 - return data - - def delete_attachment_with_http_info(self, attachment_gid, **kwargs): # noqa: E501 - """Delete an attachment # noqa: E501 - - Deletes a specific, existing attachment. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_attachment_with_http_info(attachment_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str attachment_gid: Globally unique identifier for the attachment. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['attachment_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_attachment" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'attachment_gid' is set - if ('attachment_gid' not in params or - params['attachment_gid'] is None): - raise ValueError("Missing the required parameter `attachment_gid` when calling `delete_attachment`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'attachment_gid' in params: - path_params['attachment_gid'] = params['attachment_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/attachments/{attachment_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_attachment(self, attachment_gid, **kwargs): # noqa: E501 - """Get an attachment # noqa: E501 - - Get the full record for a single attachment. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_attachment(attachment_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str attachment_gid: Globally unique identifier for the attachment. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: AttachmentResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_attachment_with_http_info(attachment_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_attachment_with_http_info(attachment_gid, **kwargs) # noqa: E501 - return data - - def get_attachment_with_http_info(self, attachment_gid, **kwargs): # noqa: E501 - """Get an attachment # noqa: E501 - - Get the full record for a single attachment. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_attachment_with_http_info(attachment_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str attachment_gid: Globally unique identifier for the attachment. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: AttachmentResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['attachment_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_attachment" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'attachment_gid' is set - if ('attachment_gid' not in params or - params['attachment_gid'] is None): - raise ValueError("Missing the required parameter `attachment_gid` when calling `get_attachment`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'attachment_gid' in params: - path_params['attachment_gid'] = params['attachment_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/attachments/{attachment_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='AttachmentResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_attachments_for_object(self, parent, **kwargs): # noqa: E501 - """Get attachments from an object # noqa: E501 - - Returns the compact records for all attachments on the object. There are three possible `parent` values for this request: `project`, `project_brief`, and `task`. For a project, an attachment refers to a file uploaded to the \"Key resources\" section in the project Overview. For a project brief, an attachment refers to inline files in the project brief itself. For a task, an attachment refers to a file directly associated to that task. Note that within the Asana app, inline images in the task description do not appear in the index of image thumbnails nor as stories in the task. However, requests made to `GET /attachments` for a task will return all of the images in the task, including inline images. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_attachments_for_object(parent, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str parent: Globally unique identifier for object to fetch statuses from. Must be a GID for a `project`, `project_brief`, or `task`. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: AttachmentResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_attachments_for_object_with_http_info(parent, **kwargs) # noqa: E501 - else: - (data) = self.get_attachments_for_object_with_http_info(parent, **kwargs) # noqa: E501 - return data - - def get_attachments_for_object_with_http_info(self, parent, **kwargs): # noqa: E501 - """Get attachments from an object # noqa: E501 - - Returns the compact records for all attachments on the object. There are three possible `parent` values for this request: `project`, `project_brief`, and `task`. For a project, an attachment refers to a file uploaded to the \"Key resources\" section in the project Overview. For a project brief, an attachment refers to inline files in the project brief itself. For a task, an attachment refers to a file directly associated to that task. Note that within the Asana app, inline images in the task description do not appear in the index of image thumbnails nor as stories in the task. However, requests made to `GET /attachments` for a task will return all of the images in the task, including inline images. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_attachments_for_object_with_http_info(parent, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str parent: Globally unique identifier for object to fetch statuses from. Must be a GID for a `project`, `project_brief`, or `task`. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: AttachmentResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['parent', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_attachments_for_object" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'parent' is set - if ('parent' not in params or - params['parent'] is None): - raise ValueError("Missing the required parameter `parent` when calling `get_attachments_for_object`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'parent' in params: - query_params.append(('parent', params['parent'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/attachments', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='AttachmentResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/audit_log_api_api.py b/asana/api/audit_log_api_api.py deleted file mode 100644 index d3795cdc..00000000 --- a/asana/api/audit_log_api_api.py +++ /dev/null @@ -1,162 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class AuditLogAPIApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def get_audit_log_events(self, workspace_gid, **kwargs): # noqa: E501 - """Get audit log events # noqa: E501 - - Retrieve the audit log events that have been captured in your domain. This endpoint will return a list of [AuditLogEvent](/reference/audit-log-api) objects, sorted by creation time in ascending order. Note that the Audit Log API captures events from October 8th, 2021 and later. Queries for events before this date will not return results. There are a number of query parameters (below) that can be used to filter the set of [AuditLogEvent](/reference/audit-log-api) objects that are returned in the response. Any combination of query parameters is valid. When no filters are provided, all of the events that have been captured in your domain will match. The list of events will always be [paginated](/docs/pagination). The default limit is 1000 events. The next set of events can be retrieved using the `offset` from the previous response. If there are no events that match the provided filters in your domain, the endpoint will return `null` for the `next_page` field. Querying again with the same filters may return new events if they were captured after the last request. Once a response includes a `next_page` with an `offset`, subsequent requests can be made with the latest `offset` to poll for new events that match the provided filters. *Note: If the filters you provided match events in your domain and `next_page` is present in the response, we will continue to send `next_page` on subsequent requests even when there are no more events that match the filters. This was put in place so that you can implement an audit log stream that will return future events that match these filters. If you are not interested in future events that match the filters you have defined, you can rely on checking empty `data` response for the end of current events that match your filters.* When no `offset` is provided, the response will begin with the oldest events that match the provided filters. It is important to note that [AuditLogEvent](/reference/audit-log-api) objects will be permanently deleted from our systems after 90 days. If you wish to keep a permanent record of these events, we recommend using a SIEM tool to ingest and store these logs. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_audit_log_events(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param datetime start_at: Filter to events created after this time (inclusive). - :param datetime end_at: Filter to events created before this time (exclusive). - :param str event_type: Filter to events of this type. Refer to the [supported audit log events](/docs/audit-log-events#supported-audit-log-events) for a full list of values. - :param str actor_type: Filter to events with an actor of this type. This only needs to be included if querying for actor types without an ID. If `actor_gid` is included, this should be excluded. - :param str actor_gid: Filter to events triggered by the actor with this ID. - :param str resource_gid: Filter to events with this resource ID. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :return: AuditLogEventArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_audit_log_events_with_http_info(workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_audit_log_events_with_http_info(workspace_gid, **kwargs) # noqa: E501 - return data - - def get_audit_log_events_with_http_info(self, workspace_gid, **kwargs): # noqa: E501 - """Get audit log events # noqa: E501 - - Retrieve the audit log events that have been captured in your domain. This endpoint will return a list of [AuditLogEvent](/reference/audit-log-api) objects, sorted by creation time in ascending order. Note that the Audit Log API captures events from October 8th, 2021 and later. Queries for events before this date will not return results. There are a number of query parameters (below) that can be used to filter the set of [AuditLogEvent](/reference/audit-log-api) objects that are returned in the response. Any combination of query parameters is valid. When no filters are provided, all of the events that have been captured in your domain will match. The list of events will always be [paginated](/docs/pagination). The default limit is 1000 events. The next set of events can be retrieved using the `offset` from the previous response. If there are no events that match the provided filters in your domain, the endpoint will return `null` for the `next_page` field. Querying again with the same filters may return new events if they were captured after the last request. Once a response includes a `next_page` with an `offset`, subsequent requests can be made with the latest `offset` to poll for new events that match the provided filters. *Note: If the filters you provided match events in your domain and `next_page` is present in the response, we will continue to send `next_page` on subsequent requests even when there are no more events that match the filters. This was put in place so that you can implement an audit log stream that will return future events that match these filters. If you are not interested in future events that match the filters you have defined, you can rely on checking empty `data` response for the end of current events that match your filters.* When no `offset` is provided, the response will begin with the oldest events that match the provided filters. It is important to note that [AuditLogEvent](/reference/audit-log-api) objects will be permanently deleted from our systems after 90 days. If you wish to keep a permanent record of these events, we recommend using a SIEM tool to ingest and store these logs. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_audit_log_events_with_http_info(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param datetime start_at: Filter to events created after this time (inclusive). - :param datetime end_at: Filter to events created before this time (exclusive). - :param str event_type: Filter to events of this type. Refer to the [supported audit log events](/docs/audit-log-events#supported-audit-log-events) for a full list of values. - :param str actor_type: Filter to events with an actor of this type. This only needs to be included if querying for actor types without an ID. If `actor_gid` is included, this should be excluded. - :param str actor_gid: Filter to events triggered by the actor with this ID. - :param str resource_gid: Filter to events with this resource ID. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :return: AuditLogEventArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace_gid', 'start_at', 'end_at', 'event_type', 'actor_type', 'actor_gid', 'resource_gid', 'limit', 'offset'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_audit_log_events" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `get_audit_log_events`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'start_at' in params: - query_params.append(('start_at', params['start_at'])) # noqa: E501 - if 'end_at' in params: - query_params.append(('end_at', params['end_at'])) # noqa: E501 - if 'event_type' in params: - query_params.append(('event_type', params['event_type'])) # noqa: E501 - if 'actor_type' in params: - query_params.append(('actor_type', params['actor_type'])) # noqa: E501 - if 'actor_gid' in params: - query_params.append(('actor_gid', params['actor_gid'])) # noqa: E501 - if 'resource_gid' in params: - query_params.append(('resource_gid', params['resource_gid'])) # noqa: E501 - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}/audit_log_events', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='AuditLogEventArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/batch_api_api.py b/asana/api/batch_api_api.py deleted file mode 100644 index 33a10153..00000000 --- a/asana/api/batch_api_api.py +++ /dev/null @@ -1,139 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class BatchAPIApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_batch_request(self, body, **kwargs): # noqa: E501 - """Submit parallel requests # noqa: E501 - - Make multiple requests in parallel to Asana's API. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_batch_request(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param BatchBody body: The requests to batch together via the Batch API. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: BatchResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_batch_request_with_http_info(body, **kwargs) # noqa: E501 - else: - (data) = self.create_batch_request_with_http_info(body, **kwargs) # noqa: E501 - return data - - def create_batch_request_with_http_info(self, body, **kwargs): # noqa: E501 - """Submit parallel requests # noqa: E501 - - Make multiple requests in parallel to Asana's API. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_batch_request_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param BatchBody body: The requests to batch together via the Batch API. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: BatchResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_batch_request" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_batch_request`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/batch', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='BatchResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/custom_field_settings_api.py b/asana/api/custom_field_settings_api.py deleted file mode 100644 index 23a9f4e8..00000000 --- a/asana/api/custom_field_settings_api.py +++ /dev/null @@ -1,253 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class CustomFieldSettingsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def get_custom_field_settings_for_portfolio(self, portfolio_gid, **kwargs): # noqa: E501 - """Get a portfolio's custom fields # noqa: E501 - - Returns a list of all of the custom fields settings on a portfolio, in compact form. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_custom_field_settings_for_portfolio(portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: CustomFieldSettingResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_custom_field_settings_for_portfolio_with_http_info(portfolio_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_custom_field_settings_for_portfolio_with_http_info(portfolio_gid, **kwargs) # noqa: E501 - return data - - def get_custom_field_settings_for_portfolio_with_http_info(self, portfolio_gid, **kwargs): # noqa: E501 - """Get a portfolio's custom fields # noqa: E501 - - Returns a list of all of the custom fields settings on a portfolio, in compact form. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_custom_field_settings_for_portfolio_with_http_info(portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: CustomFieldSettingResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['portfolio_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_custom_field_settings_for_portfolio" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'portfolio_gid' is set - if ('portfolio_gid' not in params or - params['portfolio_gid'] is None): - raise ValueError("Missing the required parameter `portfolio_gid` when calling `get_custom_field_settings_for_portfolio`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'portfolio_gid' in params: - path_params['portfolio_gid'] = params['portfolio_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios/{portfolio_gid}/custom_field_settings', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='CustomFieldSettingResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_custom_field_settings_for_project(self, project_gid, **kwargs): # noqa: E501 - """Get a project's custom fields # noqa: E501 - - Returns a list of all of the custom fields settings on a project, in compact form. Note that, as in all queries to collections which return compact representation, `opt_fields` can be used to include more data than is returned in the compact representation. See the [documentation for input/output options](https://developers.asana.com/docs/inputoutput-options) for more information. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_custom_field_settings_for_project(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: CustomFieldSettingResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_custom_field_settings_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_custom_field_settings_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - return data - - def get_custom_field_settings_for_project_with_http_info(self, project_gid, **kwargs): # noqa: E501 - """Get a project's custom fields # noqa: E501 - - Returns a list of all of the custom fields settings on a project, in compact form. Note that, as in all queries to collections which return compact representation, `opt_fields` can be used to include more data than is returned in the compact representation. See the [documentation for input/output options](https://developers.asana.com/docs/inputoutput-options) for more information. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_custom_field_settings_for_project_with_http_info(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: CustomFieldSettingResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_custom_field_settings_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `get_custom_field_settings_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/custom_field_settings', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='CustomFieldSettingResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/custom_fields_api.py b/asana/api/custom_fields_api.py deleted file mode 100644 index fdfbcaa3..00000000 --- a/asana/api/custom_fields_api.py +++ /dev/null @@ -1,888 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class CustomFieldsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_custom_field(self, body, **kwargs): # noqa: E501 - """Create a custom field # noqa: E501 - - Creates a new custom field in a workspace. Every custom field is required to be created in a specific workspace, and this workspace cannot be changed once set. A custom field’s name must be unique within a workspace and not conflict with names of existing task properties such as `Due Date` or `Assignee`. A custom field’s type must be one of `text`, `enum`, `multi_enum`, `number`, `date`, or `people`. Returns the full record of the newly created custom field. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_custom_field(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param CustomFieldsBody body: The custom field object to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: CustomFieldResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_custom_field_with_http_info(body, **kwargs) # noqa: E501 - else: - (data) = self.create_custom_field_with_http_info(body, **kwargs) # noqa: E501 - return data - - def create_custom_field_with_http_info(self, body, **kwargs): # noqa: E501 - """Create a custom field # noqa: E501 - - Creates a new custom field in a workspace. Every custom field is required to be created in a specific workspace, and this workspace cannot be changed once set. A custom field’s name must be unique within a workspace and not conflict with names of existing task properties such as `Due Date` or `Assignee`. A custom field’s type must be one of `text`, `enum`, `multi_enum`, `number`, `date`, or `people`. Returns the full record of the newly created custom field. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_custom_field_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param CustomFieldsBody body: The custom field object to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: CustomFieldResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_custom_field" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_custom_field`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/custom_fields', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='CustomFieldResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_enum_option_for_custom_field(self, custom_field_gid, **kwargs): # noqa: E501 - """Create an enum option # noqa: E501 - - Creates an enum option and adds it to this custom field’s list of enum options. A custom field can have at most 500 enum options (including disabled options). By default new enum options are inserted at the end of a custom field’s list. Locked custom fields can only have enum options added by the user who locked the field. Returns the full record of the newly created enum option. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_enum_option_for_custom_field(custom_field_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str custom_field_gid: Globally unique identifier for the custom field. (required) - :param CustomFieldGidEnumOptionsBody body: The enum option object to create. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: EnumOptionData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_enum_option_for_custom_field_with_http_info(custom_field_gid, **kwargs) # noqa: E501 - else: - (data) = self.create_enum_option_for_custom_field_with_http_info(custom_field_gid, **kwargs) # noqa: E501 - return data - - def create_enum_option_for_custom_field_with_http_info(self, custom_field_gid, **kwargs): # noqa: E501 - """Create an enum option # noqa: E501 - - Creates an enum option and adds it to this custom field’s list of enum options. A custom field can have at most 500 enum options (including disabled options). By default new enum options are inserted at the end of a custom field’s list. Locked custom fields can only have enum options added by the user who locked the field. Returns the full record of the newly created enum option. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_enum_option_for_custom_field_with_http_info(custom_field_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str custom_field_gid: Globally unique identifier for the custom field. (required) - :param CustomFieldGidEnumOptionsBody body: The enum option object to create. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: EnumOptionData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['custom_field_gid', 'body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_enum_option_for_custom_field" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'custom_field_gid' is set - if ('custom_field_gid' not in params or - params['custom_field_gid'] is None): - raise ValueError("Missing the required parameter `custom_field_gid` when calling `create_enum_option_for_custom_field`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'custom_field_gid' in params: - path_params['custom_field_gid'] = params['custom_field_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/custom_fields/{custom_field_gid}/enum_options', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EnumOptionData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_custom_field(self, custom_field_gid, **kwargs): # noqa: E501 - """Delete a custom field # noqa: E501 - - A specific, existing custom field can be deleted by making a DELETE request on the URL for that custom field. Locked custom fields can only be deleted by the user who locked the field. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_custom_field(custom_field_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str custom_field_gid: Globally unique identifier for the custom field. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_custom_field_with_http_info(custom_field_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_custom_field_with_http_info(custom_field_gid, **kwargs) # noqa: E501 - return data - - def delete_custom_field_with_http_info(self, custom_field_gid, **kwargs): # noqa: E501 - """Delete a custom field # noqa: E501 - - A specific, existing custom field can be deleted by making a DELETE request on the URL for that custom field. Locked custom fields can only be deleted by the user who locked the field. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_custom_field_with_http_info(custom_field_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str custom_field_gid: Globally unique identifier for the custom field. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['custom_field_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_custom_field" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'custom_field_gid' is set - if ('custom_field_gid' not in params or - params['custom_field_gid'] is None): - raise ValueError("Missing the required parameter `custom_field_gid` when calling `delete_custom_field`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'custom_field_gid' in params: - path_params['custom_field_gid'] = params['custom_field_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/custom_fields/{custom_field_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_custom_field(self, custom_field_gid, **kwargs): # noqa: E501 - """Get a custom field # noqa: E501 - - Get the complete definition of a custom field’s metadata. Since custom fields can be defined for one of a number of types, and these types have different data and behaviors, there are fields that are relevant to a particular type. For instance, as noted above, enum_options is only relevant for the enum type and defines the set of choices that the enum could represent. The examples below show some of these type-specific custom field definitions. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_custom_field(custom_field_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str custom_field_gid: Globally unique identifier for the custom field. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: CustomFieldResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_custom_field_with_http_info(custom_field_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_custom_field_with_http_info(custom_field_gid, **kwargs) # noqa: E501 - return data - - def get_custom_field_with_http_info(self, custom_field_gid, **kwargs): # noqa: E501 - """Get a custom field # noqa: E501 - - Get the complete definition of a custom field’s metadata. Since custom fields can be defined for one of a number of types, and these types have different data and behaviors, there are fields that are relevant to a particular type. For instance, as noted above, enum_options is only relevant for the enum type and defines the set of choices that the enum could represent. The examples below show some of these type-specific custom field definitions. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_custom_field_with_http_info(custom_field_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str custom_field_gid: Globally unique identifier for the custom field. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: CustomFieldResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['custom_field_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_custom_field" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'custom_field_gid' is set - if ('custom_field_gid' not in params or - params['custom_field_gid'] is None): - raise ValueError("Missing the required parameter `custom_field_gid` when calling `get_custom_field`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'custom_field_gid' in params: - path_params['custom_field_gid'] = params['custom_field_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/custom_fields/{custom_field_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='CustomFieldResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_custom_fields_for_workspace(self, workspace_gid, **kwargs): # noqa: E501 - """Get a workspace's custom fields # noqa: E501 - - Returns a list of the compact representation of all of the custom fields in a workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_custom_fields_for_workspace(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: CustomFieldResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_custom_fields_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_custom_fields_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - return data - - def get_custom_fields_for_workspace_with_http_info(self, workspace_gid, **kwargs): # noqa: E501 - """Get a workspace's custom fields # noqa: E501 - - Returns a list of the compact representation of all of the custom fields in a workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_custom_fields_for_workspace_with_http_info(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: CustomFieldResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_custom_fields_for_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `get_custom_fields_for_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}/custom_fields', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='CustomFieldResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def insert_enum_option_for_custom_field(self, custom_field_gid, **kwargs): # noqa: E501 - """Reorder a custom field's enum # noqa: E501 - - Moves a particular enum option to be either before or after another specified enum option in the custom field. Locked custom fields can only be reordered by the user who locked the field. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.insert_enum_option_for_custom_field(custom_field_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str custom_field_gid: Globally unique identifier for the custom field. (required) - :param EnumOptionsInsertBody body: The enum option object to create. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: EnumOptionData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.insert_enum_option_for_custom_field_with_http_info(custom_field_gid, **kwargs) # noqa: E501 - else: - (data) = self.insert_enum_option_for_custom_field_with_http_info(custom_field_gid, **kwargs) # noqa: E501 - return data - - def insert_enum_option_for_custom_field_with_http_info(self, custom_field_gid, **kwargs): # noqa: E501 - """Reorder a custom field's enum # noqa: E501 - - Moves a particular enum option to be either before or after another specified enum option in the custom field. Locked custom fields can only be reordered by the user who locked the field. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.insert_enum_option_for_custom_field_with_http_info(custom_field_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str custom_field_gid: Globally unique identifier for the custom field. (required) - :param EnumOptionsInsertBody body: The enum option object to create. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: EnumOptionData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['custom_field_gid', 'body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method insert_enum_option_for_custom_field" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'custom_field_gid' is set - if ('custom_field_gid' not in params or - params['custom_field_gid'] is None): - raise ValueError("Missing the required parameter `custom_field_gid` when calling `insert_enum_option_for_custom_field`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'custom_field_gid' in params: - path_params['custom_field_gid'] = params['custom_field_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/custom_fields/{custom_field_gid}/enum_options/insert', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EnumOptionData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_custom_field(self, custom_field_gid, **kwargs): # noqa: E501 - """Update a custom field # noqa: E501 - - A specific, existing custom field can be updated by making a PUT request on the URL for that custom field. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the custom field. A custom field’s `type` cannot be updated. An enum custom field’s `enum_options` cannot be updated with this endpoint. Instead see “Work With Enum Options” for information on how to update `enum_options`. Locked custom fields can only be updated by the user who locked the field. Returns the complete updated custom field record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_custom_field(custom_field_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str custom_field_gid: Globally unique identifier for the custom field. (required) - :param CustomFieldsCustomFieldGidBody body: The custom field object with all updated properties. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: CustomFieldResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_custom_field_with_http_info(custom_field_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_custom_field_with_http_info(custom_field_gid, **kwargs) # noqa: E501 - return data - - def update_custom_field_with_http_info(self, custom_field_gid, **kwargs): # noqa: E501 - """Update a custom field # noqa: E501 - - A specific, existing custom field can be updated by making a PUT request on the URL for that custom field. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the custom field. A custom field’s `type` cannot be updated. An enum custom field’s `enum_options` cannot be updated with this endpoint. Instead see “Work With Enum Options” for information on how to update `enum_options`. Locked custom fields can only be updated by the user who locked the field. Returns the complete updated custom field record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_custom_field_with_http_info(custom_field_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str custom_field_gid: Globally unique identifier for the custom field. (required) - :param CustomFieldsCustomFieldGidBody body: The custom field object with all updated properties. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: CustomFieldResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['custom_field_gid', 'body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_custom_field" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'custom_field_gid' is set - if ('custom_field_gid' not in params or - params['custom_field_gid'] is None): - raise ValueError("Missing the required parameter `custom_field_gid` when calling `update_custom_field`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'custom_field_gid' in params: - path_params['custom_field_gid'] = params['custom_field_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/custom_fields/{custom_field_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='CustomFieldResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_enum_option(self, enum_option_gid, **kwargs): # noqa: E501 - """Update an enum option # noqa: E501 - - Updates an existing enum option. Enum custom fields require at least one enabled enum option. Locked custom fields can only be updated by the user who locked the field. Returns the full record of the updated enum option. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_enum_option(enum_option_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str enum_option_gid: Globally unique identifier for the enum option. (required) - :param EnumOptionsEnumOptionGidBody body: The enum option object to update - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: EnumOptionData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_enum_option_with_http_info(enum_option_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_enum_option_with_http_info(enum_option_gid, **kwargs) # noqa: E501 - return data - - def update_enum_option_with_http_info(self, enum_option_gid, **kwargs): # noqa: E501 - """Update an enum option # noqa: E501 - - Updates an existing enum option. Enum custom fields require at least one enabled enum option. Locked custom fields can only be updated by the user who locked the field. Returns the full record of the updated enum option. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_enum_option_with_http_info(enum_option_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str enum_option_gid: Globally unique identifier for the enum option. (required) - :param EnumOptionsEnumOptionGidBody body: The enum option object to update - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: EnumOptionData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['enum_option_gid', 'body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_enum_option" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'enum_option_gid' is set - if ('enum_option_gid' not in params or - params['enum_option_gid'] is None): - raise ValueError("Missing the required parameter `enum_option_gid` when calling `update_enum_option`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'enum_option_gid' in params: - path_params['enum_option_gid'] = params['enum_option_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/enum_options/{enum_option_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EnumOptionData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/events_api.py b/asana/api/events_api.py deleted file mode 100644 index 01a75319..00000000 --- a/asana/api/events_api.py +++ /dev/null @@ -1,139 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class EventsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def get_events(self, resource, **kwargs): # noqa: E501 - """Get events on a resource # noqa: E501 - - Returns the full record for all events that have occurred since the sync token was created. A `GET` request to the endpoint `/[path_to_resource]/events` can be made in lieu of including the resource ID in the data for the request. Asana limits a single sync token to 100 events. If more than 100 events exist for a given resource, `has_more: true` will be returned in the response, indicating that there are more events to pull. *Note: The resource returned will be the resource that triggered the event. This may be different from the one that the events were requested for. For example, a subscription to a project will contain events for tasks contained within the project.* # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_events(resource, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str resource: A resource ID to subscribe to. The resource can be a task or project. (required) - :param str sync: A sync token received from the last request, or none on first sync. Events will be returned from the point in time that the sync token was generated. *Note: On your first request, omit the sync token. The response will be the same as for an expired sync token, and will include a new valid sync token.If the sync token is too old (which may happen from time to time) the API will return a `412 Precondition Failed` error, and include a fresh sync token in the response.* - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: EventResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_events_with_http_info(resource, **kwargs) # noqa: E501 - else: - (data) = self.get_events_with_http_info(resource, **kwargs) # noqa: E501 - return data - - def get_events_with_http_info(self, resource, **kwargs): # noqa: E501 - """Get events on a resource # noqa: E501 - - Returns the full record for all events that have occurred since the sync token was created. A `GET` request to the endpoint `/[path_to_resource]/events` can be made in lieu of including the resource ID in the data for the request. Asana limits a single sync token to 100 events. If more than 100 events exist for a given resource, `has_more: true` will be returned in the response, indicating that there are more events to pull. *Note: The resource returned will be the resource that triggered the event. This may be different from the one that the events were requested for. For example, a subscription to a project will contain events for tasks contained within the project.* # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_events_with_http_info(resource, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str resource: A resource ID to subscribe to. The resource can be a task or project. (required) - :param str sync: A sync token received from the last request, or none on first sync. Events will be returned from the point in time that the sync token was generated. *Note: On your first request, omit the sync token. The response will be the same as for an expired sync token, and will include a new valid sync token.If the sync token is too old (which may happen from time to time) the API will return a `412 Precondition Failed` error, and include a fresh sync token in the response.* - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: EventResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['resource', 'sync', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_events" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'resource' is set - if ('resource' not in params or - params['resource'] is None): - raise ValueError("Missing the required parameter `resource` when calling `get_events`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'resource' in params: - query_params.append(('resource', params['resource'])) # noqa: E501 - if 'sync' in params: - query_params.append(('sync', params['sync'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/events', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EventResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/goal_relationships_api.py b/asana/api/goal_relationships_api.py deleted file mode 100644 index eeedcb37..00000000 --- a/asana/api/goal_relationships_api.py +++ /dev/null @@ -1,586 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class GoalRelationshipsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def add_supporting_relationship(self, body, goal_gid, **kwargs): # noqa: E501 - """Add a supporting goal relationship # noqa: E501 - - Creates a goal relationship by adding a supporting resource to a given goal. Returns the newly created goal relationship record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_supporting_relationship(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalGidAddSupportingRelationshipBody body: The supporting resource to be added to the goal (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalRelationshipResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_supporting_relationship_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_supporting_relationship_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - return data - - def add_supporting_relationship_with_http_info(self, body, goal_gid, **kwargs): # noqa: E501 - """Add a supporting goal relationship # noqa: E501 - - Creates a goal relationship by adding a supporting resource to a given goal. Returns the newly created goal relationship record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_supporting_relationship_with_http_info(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalGidAddSupportingRelationshipBody body: The supporting resource to be added to the goal (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalRelationshipResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'goal_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_supporting_relationship" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_supporting_relationship`") # noqa: E501 - # verify the required parameter 'goal_gid' is set - if ('goal_gid' not in params or - params['goal_gid'] is None): - raise ValueError("Missing the required parameter `goal_gid` when calling `add_supporting_relationship`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'goal_gid' in params: - path_params['goal_gid'] = params['goal_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goals/{goal_gid}/addSupportingRelationship', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GoalRelationshipResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_goal_relationship(self, goal_relationship_gid, **kwargs): # noqa: E501 - """Get a goal relationship # noqa: E501 - - Returns the complete updated goal relationship record for a single goal relationship. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_goal_relationship(goal_relationship_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str goal_relationship_gid: Globally unique identifier for the goal relationship. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalRelationshipResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_goal_relationship_with_http_info(goal_relationship_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_goal_relationship_with_http_info(goal_relationship_gid, **kwargs) # noqa: E501 - return data - - def get_goal_relationship_with_http_info(self, goal_relationship_gid, **kwargs): # noqa: E501 - """Get a goal relationship # noqa: E501 - - Returns the complete updated goal relationship record for a single goal relationship. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_goal_relationship_with_http_info(goal_relationship_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str goal_relationship_gid: Globally unique identifier for the goal relationship. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalRelationshipResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['goal_relationship_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_goal_relationship" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'goal_relationship_gid' is set - if ('goal_relationship_gid' not in params or - params['goal_relationship_gid'] is None): - raise ValueError("Missing the required parameter `goal_relationship_gid` when calling `get_goal_relationship`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'goal_relationship_gid' in params: - path_params['goal_relationship_gid'] = params['goal_relationship_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goal_relationships/{goal_relationship_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GoalRelationshipResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_goal_relationships(self, supported_goal, **kwargs): # noqa: E501 - """Get goal relationships # noqa: E501 - - Returns compact goal relationship records. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_goal_relationships(supported_goal, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str supported_goal: Globally unique identifier for the supported goal in the goal relationship. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str resource_subtype: If provided, filter to goal relationships with a given resource_subtype. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalRelationshipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_goal_relationships_with_http_info(supported_goal, **kwargs) # noqa: E501 - else: - (data) = self.get_goal_relationships_with_http_info(supported_goal, **kwargs) # noqa: E501 - return data - - def get_goal_relationships_with_http_info(self, supported_goal, **kwargs): # noqa: E501 - """Get goal relationships # noqa: E501 - - Returns compact goal relationship records. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_goal_relationships_with_http_info(supported_goal, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str supported_goal: Globally unique identifier for the supported goal in the goal relationship. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str resource_subtype: If provided, filter to goal relationships with a given resource_subtype. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalRelationshipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['supported_goal', 'limit', 'offset', 'resource_subtype', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_goal_relationships" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'supported_goal' is set - if ('supported_goal' not in params or - params['supported_goal'] is None): - raise ValueError("Missing the required parameter `supported_goal` when calling `get_goal_relationships`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'supported_goal' in params: - query_params.append(('supported_goal', params['supported_goal'])) # noqa: E501 - if 'resource_subtype' in params: - query_params.append(('resource_subtype', params['resource_subtype'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goal_relationships', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GoalRelationshipResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_supporting_relationship(self, body, goal_gid, **kwargs): # noqa: E501 - """Removes a supporting goal relationship # noqa: E501 - - Removes a goal relationship for a given parent goal. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_supporting_relationship(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalGidRemoveSupportingRelationshipBody body: The supporting resource to be removed from the goal (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_supporting_relationship_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_supporting_relationship_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - return data - - def remove_supporting_relationship_with_http_info(self, body, goal_gid, **kwargs): # noqa: E501 - """Removes a supporting goal relationship # noqa: E501 - - Removes a goal relationship for a given parent goal. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_supporting_relationship_with_http_info(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalGidRemoveSupportingRelationshipBody body: The supporting resource to be removed from the goal (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'goal_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_supporting_relationship" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_supporting_relationship`") # noqa: E501 - # verify the required parameter 'goal_gid' is set - if ('goal_gid' not in params or - params['goal_gid'] is None): - raise ValueError("Missing the required parameter `goal_gid` when calling `remove_supporting_relationship`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'goal_gid' in params: - path_params['goal_gid'] = params['goal_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goals/{goal_gid}/removeSupportingRelationship', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_goal_relationship(self, body, goal_relationship_gid, **kwargs): # noqa: E501 - """Update a goal relationship # noqa: E501 - - An existing goal relationship can be updated by making a PUT request on the URL for that goal relationship. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. Returns the complete updated goal relationship record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_goal_relationship(body, goal_relationship_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalRelationshipsGoalRelationshipGidBody body: The updated fields for the goal relationship. (required) - :param str goal_relationship_gid: Globally unique identifier for the goal relationship. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalRelationshipResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_goal_relationship_with_http_info(body, goal_relationship_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_goal_relationship_with_http_info(body, goal_relationship_gid, **kwargs) # noqa: E501 - return data - - def update_goal_relationship_with_http_info(self, body, goal_relationship_gid, **kwargs): # noqa: E501 - """Update a goal relationship # noqa: E501 - - An existing goal relationship can be updated by making a PUT request on the URL for that goal relationship. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. Returns the complete updated goal relationship record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_goal_relationship_with_http_info(body, goal_relationship_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalRelationshipsGoalRelationshipGidBody body: The updated fields for the goal relationship. (required) - :param str goal_relationship_gid: Globally unique identifier for the goal relationship. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalRelationshipResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'goal_relationship_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_goal_relationship" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `update_goal_relationship`") # noqa: E501 - # verify the required parameter 'goal_relationship_gid' is set - if ('goal_relationship_gid' not in params or - params['goal_relationship_gid'] is None): - raise ValueError("Missing the required parameter `goal_relationship_gid` when calling `update_goal_relationship`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'goal_relationship_gid' in params: - path_params['goal_relationship_gid'] = params['goal_relationship_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goal_relationships/{goal_relationship_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GoalRelationshipResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/goals_api.py b/asana/api/goals_api.py deleted file mode 100644 index 594b9c82..00000000 --- a/asana/api/goals_api.py +++ /dev/null @@ -1,1137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class GoalsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def add_followers(self, body, goal_gid, **kwargs): # noqa: E501 - """Add a collaborator to a goal # noqa: E501 - - Adds followers to a goal. Returns the goal the followers were added to. Each goal can be associated with zero or more followers in the system. Requests to add/remove followers, if successful, will return the complete updated goal record, described above. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_followers(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalGidAddFollowersBody body: The followers to be added as collaborators (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_followers_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_followers_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - return data - - def add_followers_with_http_info(self, body, goal_gid, **kwargs): # noqa: E501 - """Add a collaborator to a goal # noqa: E501 - - Adds followers to a goal. Returns the goal the followers were added to. Each goal can be associated with zero or more followers in the system. Requests to add/remove followers, if successful, will return the complete updated goal record, described above. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_followers_with_http_info(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalGidAddFollowersBody body: The followers to be added as collaborators (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'goal_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_followers" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_followers`") # noqa: E501 - # verify the required parameter 'goal_gid' is set - if ('goal_gid' not in params or - params['goal_gid'] is None): - raise ValueError("Missing the required parameter `goal_gid` when calling `add_followers`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'goal_gid' in params: - path_params['goal_gid'] = params['goal_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goals/{goal_gid}/addFollowers', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GoalResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_goal(self, body, **kwargs): # noqa: E501 - """Create a goal # noqa: E501 - - Creates a new goal in a workspace or team. Returns the full record of the newly created goal. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_goal(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalsBody body: The goal to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_goal_with_http_info(body, **kwargs) # noqa: E501 - else: - (data) = self.create_goal_with_http_info(body, **kwargs) # noqa: E501 - return data - - def create_goal_with_http_info(self, body, **kwargs): # noqa: E501 - """Create a goal # noqa: E501 - - Creates a new goal in a workspace or team. Returns the full record of the newly created goal. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_goal_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalsBody body: The goal to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_goal" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_goal`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goals', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GoalResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_goal_metric(self, body, goal_gid, **kwargs): # noqa: E501 - """Create a goal metric # noqa: E501 - - Creates and adds a goal metric to a specified goal. Note that this replaces an existing goal metric if one already exists. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_goal_metric(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalGidSetMetricBody body: The goal metric to create. (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_goal_metric_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - else: - (data) = self.create_goal_metric_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - return data - - def create_goal_metric_with_http_info(self, body, goal_gid, **kwargs): # noqa: E501 - """Create a goal metric # noqa: E501 - - Creates and adds a goal metric to a specified goal. Note that this replaces an existing goal metric if one already exists. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_goal_metric_with_http_info(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalGidSetMetricBody body: The goal metric to create. (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'goal_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_goal_metric" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_goal_metric`") # noqa: E501 - # verify the required parameter 'goal_gid' is set - if ('goal_gid' not in params or - params['goal_gid'] is None): - raise ValueError("Missing the required parameter `goal_gid` when calling `create_goal_metric`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'goal_gid' in params: - path_params['goal_gid'] = params['goal_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goals/{goal_gid}/setMetric', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GoalResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_goal(self, goal_gid, **kwargs): # noqa: E501 - """Delete a goal # noqa: E501 - - A specific, existing goal can be deleted by making a DELETE request on the URL for that goal. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_goal(goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str goal_gid: Globally unique identifier for the goal. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_goal_with_http_info(goal_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_goal_with_http_info(goal_gid, **kwargs) # noqa: E501 - return data - - def delete_goal_with_http_info(self, goal_gid, **kwargs): # noqa: E501 - """Delete a goal # noqa: E501 - - A specific, existing goal can be deleted by making a DELETE request on the URL for that goal. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_goal_with_http_info(goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str goal_gid: Globally unique identifier for the goal. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['goal_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_goal" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'goal_gid' is set - if ('goal_gid' not in params or - params['goal_gid'] is None): - raise ValueError("Missing the required parameter `goal_gid` when calling `delete_goal`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'goal_gid' in params: - path_params['goal_gid'] = params['goal_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goals/{goal_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_goal(self, goal_gid, **kwargs): # noqa: E501 - """Get a goal # noqa: E501 - - Returns the complete goal record for a single goal. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_goal(goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_goal_with_http_info(goal_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_goal_with_http_info(goal_gid, **kwargs) # noqa: E501 - return data - - def get_goal_with_http_info(self, goal_gid, **kwargs): # noqa: E501 - """Get a goal # noqa: E501 - - Returns the complete goal record for a single goal. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_goal_with_http_info(goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['goal_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_goal" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'goal_gid' is set - if ('goal_gid' not in params or - params['goal_gid'] is None): - raise ValueError("Missing the required parameter `goal_gid` when calling `get_goal`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'goal_gid' in params: - path_params['goal_gid'] = params['goal_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goals/{goal_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GoalResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_goals(self, **kwargs): # noqa: E501 - """Get goals # noqa: E501 - - Returns compact goal records. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_goals(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio: Globally unique identifier for supporting portfolio. - :param str project: Globally unique identifier for supporting project. - :param bool is_workspace_level: Filter to goals with is_workspace_level set to query value. Must be used with the workspace parameter. - :param str team: Globally unique identifier for the team. - :param str workspace: Globally unique identifier for the workspace. - :param list[str] time_periods: Globally unique identifiers for the time periods. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_goals_with_http_info(**kwargs) # noqa: E501 - else: - (data) = self.get_goals_with_http_info(**kwargs) # noqa: E501 - return data - - def get_goals_with_http_info(self, **kwargs): # noqa: E501 - """Get goals # noqa: E501 - - Returns compact goal records. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_goals_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio: Globally unique identifier for supporting portfolio. - :param str project: Globally unique identifier for supporting project. - :param bool is_workspace_level: Filter to goals with is_workspace_level set to query value. Must be used with the workspace parameter. - :param str team: Globally unique identifier for the team. - :param str workspace: Globally unique identifier for the workspace. - :param list[str] time_periods: Globally unique identifiers for the time periods. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['portfolio', 'project', 'is_workspace_level', 'team', 'workspace', 'time_periods', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_goals" % key - ) - params[key] = val - del params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'portfolio' in params: - query_params.append(('portfolio', params['portfolio'])) # noqa: E501 - if 'project' in params: - query_params.append(('project', params['project'])) # noqa: E501 - if 'is_workspace_level' in params: - query_params.append(('is_workspace_level', params['is_workspace_level'])) # noqa: E501 - if 'team' in params: - query_params.append(('team', params['team'])) # noqa: E501 - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'time_periods' in params: - query_params.append(('time_periods', params['time_periods'])) # noqa: E501 - collection_formats['time_periods'] = 'multi' # noqa: E501 - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goals', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GoalResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_parent_goals_for_goal(self, goal_gid, **kwargs): # noqa: E501 - """Get parent goals from a goal # noqa: E501 - - Returns a compact representation of all of the parent goals of a goal. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_parent_goals_for_goal(goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_parent_goals_for_goal_with_http_info(goal_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_parent_goals_for_goal_with_http_info(goal_gid, **kwargs) # noqa: E501 - return data - - def get_parent_goals_for_goal_with_http_info(self, goal_gid, **kwargs): # noqa: E501 - """Get parent goals from a goal # noqa: E501 - - Returns a compact representation of all of the parent goals of a goal. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_parent_goals_for_goal_with_http_info(goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['goal_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_parent_goals_for_goal" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'goal_gid' is set - if ('goal_gid' not in params or - params['goal_gid'] is None): - raise ValueError("Missing the required parameter `goal_gid` when calling `get_parent_goals_for_goal`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'goal_gid' in params: - path_params['goal_gid'] = params['goal_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goals/{goal_gid}/parentGoals', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GoalResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_followers(self, body, goal_gid, **kwargs): # noqa: E501 - """Remove a collaborator from a goal # noqa: E501 - - Removes followers from a goal. Returns the goal the followers were removed from. Each goal can be associated with zero or more followers in the system. Requests to add/remove followers, if successful, will return the complete updated goal record, described above. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_followers(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalGidRemoveFollowersBody body: The followers to be removed as collaborators (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_followers_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_followers_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - return data - - def remove_followers_with_http_info(self, body, goal_gid, **kwargs): # noqa: E501 - """Remove a collaborator from a goal # noqa: E501 - - Removes followers from a goal. Returns the goal the followers were removed from. Each goal can be associated with zero or more followers in the system. Requests to add/remove followers, if successful, will return the complete updated goal record, described above. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_followers_with_http_info(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalGidRemoveFollowersBody body: The followers to be removed as collaborators (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'goal_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_followers" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_followers`") # noqa: E501 - # verify the required parameter 'goal_gid' is set - if ('goal_gid' not in params or - params['goal_gid'] is None): - raise ValueError("Missing the required parameter `goal_gid` when calling `remove_followers`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'goal_gid' in params: - path_params['goal_gid'] = params['goal_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goals/{goal_gid}/removeFollowers', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GoalResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_goal(self, body, goal_gid, **kwargs): # noqa: E501 - """Update a goal # noqa: E501 - - An existing goal can be updated by making a PUT request on the URL for that goal. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. Returns the complete updated goal record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_goal(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalsGoalGidBody body: The updated fields for the goal. (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_goal_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_goal_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - return data - - def update_goal_with_http_info(self, body, goal_gid, **kwargs): # noqa: E501 - """Update a goal # noqa: E501 - - An existing goal can be updated by making a PUT request on the URL for that goal. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. Returns the complete updated goal record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_goal_with_http_info(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalsGoalGidBody body: The updated fields for the goal. (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'goal_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_goal" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `update_goal`") # noqa: E501 - # verify the required parameter 'goal_gid' is set - if ('goal_gid' not in params or - params['goal_gid'] is None): - raise ValueError("Missing the required parameter `goal_gid` when calling `update_goal`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'goal_gid' in params: - path_params['goal_gid'] = params['goal_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goals/{goal_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GoalResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_goal_metric(self, body, goal_gid, **kwargs): # noqa: E501 - """Update a goal metric # noqa: E501 - - Updates a goal's existing metric's `current_number_value` if one exists, otherwise responds with a 400 status code. Returns the complete updated goal metric record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_goal_metric(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalGidSetMetricCurrentValueBody body: The updated fields for the goal metric. (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_goal_metric_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_goal_metric_with_http_info(body, goal_gid, **kwargs) # noqa: E501 - return data - - def update_goal_metric_with_http_info(self, body, goal_gid, **kwargs): # noqa: E501 - """Update a goal metric # noqa: E501 - - Updates a goal's existing metric's `current_number_value` if one exists, otherwise responds with a 400 status code. Returns the complete updated goal metric record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_goal_metric_with_http_info(body, goal_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param GoalGidSetMetricCurrentValueBody body: The updated fields for the goal metric. (required) - :param str goal_gid: Globally unique identifier for the goal. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: GoalResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'goal_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_goal_metric" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `update_goal_metric`") # noqa: E501 - # verify the required parameter 'goal_gid' is set - if ('goal_gid' not in params or - params['goal_gid'] is None): - raise ValueError("Missing the required parameter `goal_gid` when calling `update_goal_metric`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'goal_gid' in params: - path_params['goal_gid'] = params['goal_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/goals/{goal_gid}/setMetricCurrentValue', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='GoalResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/jobs_api.py b/asana/api/jobs_api.py deleted file mode 100644 index 86139824..00000000 --- a/asana/api/jobs_api.py +++ /dev/null @@ -1,135 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class JobsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def get_job(self, job_gid, **kwargs): # noqa: E501 - """Get a job by id # noqa: E501 - - Returns the full record for a job. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_job(job_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str job_gid: Globally unique identifier for the job. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: JobResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_job_with_http_info(job_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_job_with_http_info(job_gid, **kwargs) # noqa: E501 - return data - - def get_job_with_http_info(self, job_gid, **kwargs): # noqa: E501 - """Get a job by id # noqa: E501 - - Returns the full record for a job. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_job_with_http_info(job_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str job_gid: Globally unique identifier for the job. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: JobResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['job_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_job" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'job_gid' is set - if ('job_gid' not in params or - params['job_gid'] is None): - raise ValueError("Missing the required parameter `job_gid` when calling `get_job`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'job_gid' in params: - path_params['job_gid'] = params['job_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/jobs/{job_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='JobResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/memberships_api.py b/asana/api/memberships_api.py deleted file mode 100644 index 76268cc8..00000000 --- a/asana/api/memberships_api.py +++ /dev/null @@ -1,439 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class MembershipsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_membership(self, **kwargs): # noqa: E501 - """Create a membership # noqa: E501 - - Creates a new membership in a `goal`. `Teams` or `users` can be a member of `goals`. Returns the full record of the newly created membership. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_membership(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param MembershipsBody body: The updated fields for the membership. - :return: MembershipResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_membership_with_http_info(**kwargs) # noqa: E501 - else: - (data) = self.create_membership_with_http_info(**kwargs) # noqa: E501 - return data - - def create_membership_with_http_info(self, **kwargs): # noqa: E501 - """Create a membership # noqa: E501 - - Creates a new membership in a `goal`. `Teams` or `users` can be a member of `goals`. Returns the full record of the newly created membership. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_membership_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param MembershipsBody body: The updated fields for the membership. - :return: MembershipResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_membership" % key - ) - params[key] = val - del params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/memberships', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='MembershipResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_membership(self, membership_gid, **kwargs): # noqa: E501 - """Delete a membership # noqa: E501 - - A specific, existing membership can be deleted by making a `DELETE` request on the URL for that membership. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_membership(membership_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str membership_gid: Globally unique identifier for the membership. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_membership_with_http_info(membership_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_membership_with_http_info(membership_gid, **kwargs) # noqa: E501 - return data - - def delete_membership_with_http_info(self, membership_gid, **kwargs): # noqa: E501 - """Delete a membership # noqa: E501 - - A specific, existing membership can be deleted by making a `DELETE` request on the URL for that membership. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_membership_with_http_info(membership_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str membership_gid: Globally unique identifier for the membership. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['membership_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_membership" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'membership_gid' is set - if ('membership_gid' not in params or - params['membership_gid'] is None): - raise ValueError("Missing the required parameter `membership_gid` when calling `delete_membership`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'membership_gid' in params: - path_params['membership_gid'] = params['membership_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/memberships/{membership_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_membership(self, membership_gid, **kwargs): # noqa: E501 - """Get a membership # noqa: E501 - - Returns compact `project_membership` record for a single membership. `GET` only supports project memberships currently # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_membership(membership_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str membership_gid: Globally unique identifier for the membership. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectMembershipCompactResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_membership_with_http_info(membership_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_membership_with_http_info(membership_gid, **kwargs) # noqa: E501 - return data - - def get_membership_with_http_info(self, membership_gid, **kwargs): # noqa: E501 - """Get a membership # noqa: E501 - - Returns compact `project_membership` record for a single membership. `GET` only supports project memberships currently # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_membership_with_http_info(membership_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str membership_gid: Globally unique identifier for the membership. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectMembershipCompactResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['membership_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_membership" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'membership_gid' is set - if ('membership_gid' not in params or - params['membership_gid'] is None): - raise ValueError("Missing the required parameter `membership_gid` when calling `get_membership`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'membership_gid' in params: - path_params['membership_gid'] = params['membership_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/memberships/{membership_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectMembershipCompactResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_memberships(self, **kwargs): # noqa: E501 - """Get multiple memberships # noqa: E501 - - Returns compact `goal_membership` or `project_membership` records. The possible types for `parent` in this request are `goal` or `project`. An additional member (user GID or team GID) can be passed in to filter to a specific membership. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_memberships(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str parent: Globally unique identifier for `goal` or `project`. - :param str member: Globally unique identifier for `team` or `user`. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: MembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_memberships_with_http_info(**kwargs) # noqa: E501 - else: - (data) = self.get_memberships_with_http_info(**kwargs) # noqa: E501 - return data - - def get_memberships_with_http_info(self, **kwargs): # noqa: E501 - """Get multiple memberships # noqa: E501 - - Returns compact `goal_membership` or `project_membership` records. The possible types for `parent` in this request are `goal` or `project`. An additional member (user GID or team GID) can be passed in to filter to a specific membership. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_memberships_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str parent: Globally unique identifier for `goal` or `project`. - :param str member: Globally unique identifier for `team` or `user`. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: MembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['parent', 'member', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_memberships" % key - ) - params[key] = val - del params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'parent' in params: - query_params.append(('parent', params['parent'])) # noqa: E501 - if 'member' in params: - query_params.append(('member', params['member'])) # noqa: E501 - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/memberships', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='MembershipResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/organization_exports_api.py b/asana/api/organization_exports_api.py deleted file mode 100644 index 88241c07..00000000 --- a/asana/api/organization_exports_api.py +++ /dev/null @@ -1,241 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class OrganizationExportsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_organization_export(self, body, **kwargs): # noqa: E501 - """Create an organization export request # noqa: E501 - - This method creates a request to export an Organization. Asana will complete the export at some point after you create the request. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_organization_export(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param OrganizationExportsBody body: The organization to export. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: OrganizationExportResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_organization_export_with_http_info(body, **kwargs) # noqa: E501 - else: - (data) = self.create_organization_export_with_http_info(body, **kwargs) # noqa: E501 - return data - - def create_organization_export_with_http_info(self, body, **kwargs): # noqa: E501 - """Create an organization export request # noqa: E501 - - This method creates a request to export an Organization. Asana will complete the export at some point after you create the request. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_organization_export_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param OrganizationExportsBody body: The organization to export. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: OrganizationExportResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_organization_export" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_organization_export`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/organization_exports', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='OrganizationExportResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_organization_export(self, organization_export_gid, **kwargs): # noqa: E501 - """Get details on an org export request # noqa: E501 - - Returns details of a previously-requested Organization export. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_organization_export(organization_export_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str organization_export_gid: Globally unique identifier for the organization export. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: OrganizationExportResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_organization_export_with_http_info(organization_export_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_organization_export_with_http_info(organization_export_gid, **kwargs) # noqa: E501 - return data - - def get_organization_export_with_http_info(self, organization_export_gid, **kwargs): # noqa: E501 - """Get details on an org export request # noqa: E501 - - Returns details of a previously-requested Organization export. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_organization_export_with_http_info(organization_export_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str organization_export_gid: Globally unique identifier for the organization export. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: OrganizationExportResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['organization_export_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_organization_export" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'organization_export_gid' is set - if ('organization_export_gid' not in params or - params['organization_export_gid'] is None): - raise ValueError("Missing the required parameter `organization_export_gid` when calling `get_organization_export`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'organization_export_gid' in params: - path_params['organization_export_gid'] = params['organization_export_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/organization_exports/{organization_export_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='OrganizationExportResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/portfolio_memberships_api.py b/asana/api/portfolio_memberships_api.py deleted file mode 100644 index ee61b1a3..00000000 --- a/asana/api/portfolio_memberships_api.py +++ /dev/null @@ -1,363 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class PortfolioMembershipsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def get_portfolio_membership(self, portfolio_membership_gid, **kwargs): # noqa: E501 - """Get a portfolio membership # noqa: E501 - - Returns the complete portfolio record for a single portfolio membership. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_portfolio_membership(portfolio_membership_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio_membership_gid: (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioMembershipResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_portfolio_membership_with_http_info(portfolio_membership_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_portfolio_membership_with_http_info(portfolio_membership_gid, **kwargs) # noqa: E501 - return data - - def get_portfolio_membership_with_http_info(self, portfolio_membership_gid, **kwargs): # noqa: E501 - """Get a portfolio membership # noqa: E501 - - Returns the complete portfolio record for a single portfolio membership. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_portfolio_membership_with_http_info(portfolio_membership_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio_membership_gid: (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioMembershipResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['portfolio_membership_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_portfolio_membership" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'portfolio_membership_gid' is set - if ('portfolio_membership_gid' not in params or - params['portfolio_membership_gid'] is None): - raise ValueError("Missing the required parameter `portfolio_membership_gid` when calling `get_portfolio_membership`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'portfolio_membership_gid' in params: - path_params['portfolio_membership_gid'] = params['portfolio_membership_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolio_memberships/{portfolio_membership_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='PortfolioMembershipResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_portfolio_memberships(self, **kwargs): # noqa: E501 - """Get multiple portfolio memberships # noqa: E501 - - Returns a list of portfolio memberships in compact representation. You must specify `portfolio`, `portfolio` and `user`, or `workspace` and `user`. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_portfolio_memberships(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio: The portfolio to filter results on. - :param str workspace: The workspace to filter results on. - :param str user: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_portfolio_memberships_with_http_info(**kwargs) # noqa: E501 - else: - (data) = self.get_portfolio_memberships_with_http_info(**kwargs) # noqa: E501 - return data - - def get_portfolio_memberships_with_http_info(self, **kwargs): # noqa: E501 - """Get multiple portfolio memberships # noqa: E501 - - Returns a list of portfolio memberships in compact representation. You must specify `portfolio`, `portfolio` and `user`, or `workspace` and `user`. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_portfolio_memberships_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio: The portfolio to filter results on. - :param str workspace: The workspace to filter results on. - :param str user: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['portfolio', 'workspace', 'user', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_portfolio_memberships" % key - ) - params[key] = val - del params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'portfolio' in params: - query_params.append(('portfolio', params['portfolio'])) # noqa: E501 - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'user' in params: - query_params.append(('user', params['user'])) # noqa: E501 - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolio_memberships', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='PortfolioMembershipResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_portfolio_memberships_for_portfolio(self, portfolio_gid, **kwargs): # noqa: E501 - """Get memberships from a portfolio # noqa: E501 - - Returns the compact portfolio membership records for the portfolio. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_portfolio_memberships_for_portfolio(portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param str user: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_portfolio_memberships_for_portfolio_with_http_info(portfolio_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_portfolio_memberships_for_portfolio_with_http_info(portfolio_gid, **kwargs) # noqa: E501 - return data - - def get_portfolio_memberships_for_portfolio_with_http_info(self, portfolio_gid, **kwargs): # noqa: E501 - """Get memberships from a portfolio # noqa: E501 - - Returns the compact portfolio membership records for the portfolio. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_portfolio_memberships_for_portfolio_with_http_info(portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param str user: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['portfolio_gid', 'user', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_portfolio_memberships_for_portfolio" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'portfolio_gid' is set - if ('portfolio_gid' not in params or - params['portfolio_gid'] is None): - raise ValueError("Missing the required parameter `portfolio_gid` when calling `get_portfolio_memberships_for_portfolio`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'portfolio_gid' in params: - path_params['portfolio_gid'] = params['portfolio_gid'] # noqa: E501 - - query_params = [] - if 'user' in params: - query_params.append(('user', params['user'])) # noqa: E501 - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios/{portfolio_gid}/portfolio_memberships', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='PortfolioMembershipResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/portfolios_api.py b/asana/api/portfolios_api.py deleted file mode 100644 index 1110edb4..00000000 --- a/asana/api/portfolios_api.py +++ /dev/null @@ -1,1340 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class PortfoliosApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def add_custom_field_setting_for_portfolio(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Add a custom field to a portfolio # noqa: E501 - - Custom fields are associated with portfolios by way of custom field settings. This method creates a setting for the portfolio. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_custom_field_setting_for_portfolio(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfolioGidAddCustomFieldSettingBody body: Information about the custom field setting. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :return: CustomFieldSettingResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_custom_field_setting_for_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_custom_field_setting_for_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - return data - - def add_custom_field_setting_for_portfolio_with_http_info(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Add a custom field to a portfolio # noqa: E501 - - Custom fields are associated with portfolios by way of custom field settings. This method creates a setting for the portfolio. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_custom_field_setting_for_portfolio_with_http_info(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfolioGidAddCustomFieldSettingBody body: Information about the custom field setting. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :return: CustomFieldSettingResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'portfolio_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_custom_field_setting_for_portfolio" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_custom_field_setting_for_portfolio`") # noqa: E501 - # verify the required parameter 'portfolio_gid' is set - if ('portfolio_gid' not in params or - params['portfolio_gid'] is None): - raise ValueError("Missing the required parameter `portfolio_gid` when calling `add_custom_field_setting_for_portfolio`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'portfolio_gid' in params: - path_params['portfolio_gid'] = params['portfolio_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios/{portfolio_gid}/addCustomFieldSetting', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='CustomFieldSettingResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def add_item_for_portfolio(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Add a portfolio item # noqa: E501 - - Add an item to a portfolio. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_item_for_portfolio(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfolioGidAddItemBody body: Information about the item being inserted. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_item_for_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_item_for_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - return data - - def add_item_for_portfolio_with_http_info(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Add a portfolio item # noqa: E501 - - Add an item to a portfolio. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_item_for_portfolio_with_http_info(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfolioGidAddItemBody body: Information about the item being inserted. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'portfolio_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_item_for_portfolio" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_item_for_portfolio`") # noqa: E501 - # verify the required parameter 'portfolio_gid' is set - if ('portfolio_gid' not in params or - params['portfolio_gid'] is None): - raise ValueError("Missing the required parameter `portfolio_gid` when calling `add_item_for_portfolio`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'portfolio_gid' in params: - path_params['portfolio_gid'] = params['portfolio_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios/{portfolio_gid}/addItem', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def add_members_for_portfolio(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Add users to a portfolio # noqa: E501 - - Adds the specified list of users as members of the portfolio. Returns the updated portfolio record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_members_for_portfolio(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfolioGidAddMembersBody body: Information about the members being added. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_members_for_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_members_for_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - return data - - def add_members_for_portfolio_with_http_info(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Add users to a portfolio # noqa: E501 - - Adds the specified list of users as members of the portfolio. Returns the updated portfolio record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_members_for_portfolio_with_http_info(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfolioGidAddMembersBody body: Information about the members being added. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'portfolio_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_members_for_portfolio" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_members_for_portfolio`") # noqa: E501 - # verify the required parameter 'portfolio_gid' is set - if ('portfolio_gid' not in params or - params['portfolio_gid'] is None): - raise ValueError("Missing the required parameter `portfolio_gid` when calling `add_members_for_portfolio`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'portfolio_gid' in params: - path_params['portfolio_gid'] = params['portfolio_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios/{portfolio_gid}/addMembers', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='PortfolioResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_portfolio(self, body, **kwargs): # noqa: E501 - """Create a portfolio # noqa: E501 - - Creates a new portfolio in the given workspace with the supplied name. Note that portfolios created in the Asana UI may have some state (like the “Priority” custom field) which is automatically added to the portfolio when it is created. Portfolios created via our API will *not* be created with the same initial state to allow integrations to create their own starting state on a portfolio. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_portfolio(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfoliosBody body: The portfolio to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_portfolio_with_http_info(body, **kwargs) # noqa: E501 - else: - (data) = self.create_portfolio_with_http_info(body, **kwargs) # noqa: E501 - return data - - def create_portfolio_with_http_info(self, body, **kwargs): # noqa: E501 - """Create a portfolio # noqa: E501 - - Creates a new portfolio in the given workspace with the supplied name. Note that portfolios created in the Asana UI may have some state (like the “Priority” custom field) which is automatically added to the portfolio when it is created. Portfolios created via our API will *not* be created with the same initial state to allow integrations to create their own starting state on a portfolio. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_portfolio_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfoliosBody body: The portfolio to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_portfolio" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_portfolio`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='PortfolioResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_portfolio(self, portfolio_gid, **kwargs): # noqa: E501 - """Delete a portfolio # noqa: E501 - - An existing portfolio can be deleted by making a DELETE request on the URL for that portfolio. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_portfolio(portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_portfolio_with_http_info(portfolio_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_portfolio_with_http_info(portfolio_gid, **kwargs) # noqa: E501 - return data - - def delete_portfolio_with_http_info(self, portfolio_gid, **kwargs): # noqa: E501 - """Delete a portfolio # noqa: E501 - - An existing portfolio can be deleted by making a DELETE request on the URL for that portfolio. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_portfolio_with_http_info(portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['portfolio_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_portfolio" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'portfolio_gid' is set - if ('portfolio_gid' not in params or - params['portfolio_gid'] is None): - raise ValueError("Missing the required parameter `portfolio_gid` when calling `delete_portfolio`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'portfolio_gid' in params: - path_params['portfolio_gid'] = params['portfolio_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios/{portfolio_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_items_for_portfolio(self, portfolio_gid, **kwargs): # noqa: E501 - """Get portfolio items # noqa: E501 - - Get a list of the items in compact form in a portfolio. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_items_for_portfolio(portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_items_for_portfolio_with_http_info(portfolio_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_items_for_portfolio_with_http_info(portfolio_gid, **kwargs) # noqa: E501 - return data - - def get_items_for_portfolio_with_http_info(self, portfolio_gid, **kwargs): # noqa: E501 - """Get portfolio items # noqa: E501 - - Get a list of the items in compact form in a portfolio. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_items_for_portfolio_with_http_info(portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['portfolio_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_items_for_portfolio" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'portfolio_gid' is set - if ('portfolio_gid' not in params or - params['portfolio_gid'] is None): - raise ValueError("Missing the required parameter `portfolio_gid` when calling `get_items_for_portfolio`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'portfolio_gid' in params: - path_params['portfolio_gid'] = params['portfolio_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios/{portfolio_gid}/items', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_portfolio(self, portfolio_gid, **kwargs): # noqa: E501 - """Get a portfolio # noqa: E501 - - Returns the complete portfolio record for a single portfolio. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_portfolio(portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_portfolio_with_http_info(portfolio_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_portfolio_with_http_info(portfolio_gid, **kwargs) # noqa: E501 - return data - - def get_portfolio_with_http_info(self, portfolio_gid, **kwargs): # noqa: E501 - """Get a portfolio # noqa: E501 - - Returns the complete portfolio record for a single portfolio. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_portfolio_with_http_info(portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['portfolio_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_portfolio" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'portfolio_gid' is set - if ('portfolio_gid' not in params or - params['portfolio_gid'] is None): - raise ValueError("Missing the required parameter `portfolio_gid` when calling `get_portfolio`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'portfolio_gid' in params: - path_params['portfolio_gid'] = params['portfolio_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios/{portfolio_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='PortfolioResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_portfolios(self, workspace, **kwargs): # noqa: E501 - """Get multiple portfolios # noqa: E501 - - Returns a list of the portfolios in compact representation that are owned by the current API user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_portfolios(workspace, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace: The workspace or organization to filter portfolios on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str owner: The user who owns the portfolio. Currently, API users can only get a list of portfolios that they themselves own, unless the request is made from a Service Account. In the case of a Service Account, if this parameter is specified, then all portfolios owned by this parameter are returned. Otherwise, all portfolios across the workspace are returned. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_portfolios_with_http_info(workspace, **kwargs) # noqa: E501 - else: - (data) = self.get_portfolios_with_http_info(workspace, **kwargs) # noqa: E501 - return data - - def get_portfolios_with_http_info(self, workspace, **kwargs): # noqa: E501 - """Get multiple portfolios # noqa: E501 - - Returns a list of the portfolios in compact representation that are owned by the current API user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_portfolios_with_http_info(workspace, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace: The workspace or organization to filter portfolios on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str owner: The user who owns the portfolio. Currently, API users can only get a list of portfolios that they themselves own, unless the request is made from a Service Account. In the case of a Service Account, if this parameter is specified, then all portfolios owned by this parameter are returned. Otherwise, all portfolios across the workspace are returned. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace', 'limit', 'offset', 'owner', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_portfolios" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace' is set - if ('workspace' not in params or - params['workspace'] is None): - raise ValueError("Missing the required parameter `workspace` when calling `get_portfolios`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'owner' in params: - query_params.append(('owner', params['owner'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='PortfolioResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_custom_field_setting_for_portfolio(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Remove a custom field from a portfolio # noqa: E501 - - Removes a custom field setting from a portfolio. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_custom_field_setting_for_portfolio(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfolioGidRemoveCustomFieldSettingBody body: Information about the custom field setting being removed. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_custom_field_setting_for_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_custom_field_setting_for_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - return data - - def remove_custom_field_setting_for_portfolio_with_http_info(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Remove a custom field from a portfolio # noqa: E501 - - Removes a custom field setting from a portfolio. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_custom_field_setting_for_portfolio_with_http_info(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfolioGidRemoveCustomFieldSettingBody body: Information about the custom field setting being removed. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'portfolio_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_custom_field_setting_for_portfolio" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_custom_field_setting_for_portfolio`") # noqa: E501 - # verify the required parameter 'portfolio_gid' is set - if ('portfolio_gid' not in params or - params['portfolio_gid'] is None): - raise ValueError("Missing the required parameter `portfolio_gid` when calling `remove_custom_field_setting_for_portfolio`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'portfolio_gid' in params: - path_params['portfolio_gid'] = params['portfolio_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios/{portfolio_gid}/removeCustomFieldSetting', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_item_for_portfolio(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Remove a portfolio item # noqa: E501 - - Remove an item from a portfolio. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_item_for_portfolio(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfolioGidRemoveItemBody body: Information about the item being removed. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_item_for_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_item_for_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - return data - - def remove_item_for_portfolio_with_http_info(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Remove a portfolio item # noqa: E501 - - Remove an item from a portfolio. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_item_for_portfolio_with_http_info(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfolioGidRemoveItemBody body: Information about the item being removed. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'portfolio_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_item_for_portfolio" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_item_for_portfolio`") # noqa: E501 - # verify the required parameter 'portfolio_gid' is set - if ('portfolio_gid' not in params or - params['portfolio_gid'] is None): - raise ValueError("Missing the required parameter `portfolio_gid` when calling `remove_item_for_portfolio`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'portfolio_gid' in params: - path_params['portfolio_gid'] = params['portfolio_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios/{portfolio_gid}/removeItem', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_members_for_portfolio(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Remove users from a portfolio # noqa: E501 - - Removes the specified list of users from members of the portfolio. Returns the updated portfolio record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_members_for_portfolio(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfolioGidRemoveMembersBody body: Information about the members being removed. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_members_for_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_members_for_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - return data - - def remove_members_for_portfolio_with_http_info(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Remove users from a portfolio # noqa: E501 - - Removes the specified list of users from members of the portfolio. Returns the updated portfolio record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_members_for_portfolio_with_http_info(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfolioGidRemoveMembersBody body: Information about the members being removed. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'portfolio_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_members_for_portfolio" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_members_for_portfolio`") # noqa: E501 - # verify the required parameter 'portfolio_gid' is set - if ('portfolio_gid' not in params or - params['portfolio_gid'] is None): - raise ValueError("Missing the required parameter `portfolio_gid` when calling `remove_members_for_portfolio`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'portfolio_gid' in params: - path_params['portfolio_gid'] = params['portfolio_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios/{portfolio_gid}/removeMembers', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='PortfolioResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_portfolio(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Update a portfolio # noqa: E501 - - An existing portfolio can be updated by making a PUT request on the URL for that portfolio. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. Returns the complete updated portfolio record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_portfolio(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfoliosPortfolioGidBody body: The updated fields for the portfolio. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_portfolio_with_http_info(body, portfolio_gid, **kwargs) # noqa: E501 - return data - - def update_portfolio_with_http_info(self, body, portfolio_gid, **kwargs): # noqa: E501 - """Update a portfolio # noqa: E501 - - An existing portfolio can be updated by making a PUT request on the URL for that portfolio. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. Returns the complete updated portfolio record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_portfolio_with_http_info(body, portfolio_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param PortfoliosPortfolioGidBody body: The updated fields for the portfolio. (required) - :param str portfolio_gid: Globally unique identifier for the portfolio. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: PortfolioResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'portfolio_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_portfolio" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `update_portfolio`") # noqa: E501 - # verify the required parameter 'portfolio_gid' is set - if ('portfolio_gid' not in params or - params['portfolio_gid'] is None): - raise ValueError("Missing the required parameter `portfolio_gid` when calling `update_portfolio`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'portfolio_gid' in params: - path_params['portfolio_gid'] = params['portfolio_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/portfolios/{portfolio_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='PortfolioResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/project_briefs_api.py b/asana/api/project_briefs_api.py deleted file mode 100644 index 501b07e3..00000000 --- a/asana/api/project_briefs_api.py +++ /dev/null @@ -1,460 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class ProjectBriefsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_project_brief(self, body, project_gid, **kwargs): # noqa: E501 - """Create a project brief # noqa: E501 - - Creates a new project brief. Returns the full record of the newly created project brief. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_project_brief(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidProjectBriefsBody body: The project brief to create. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectBriefResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_project_brief_with_http_info(body, project_gid, **kwargs) # noqa: E501 - else: - (data) = self.create_project_brief_with_http_info(body, project_gid, **kwargs) # noqa: E501 - return data - - def create_project_brief_with_http_info(self, body, project_gid, **kwargs): # noqa: E501 - """Create a project brief # noqa: E501 - - Creates a new project brief. Returns the full record of the newly created project brief. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_project_brief_with_http_info(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidProjectBriefsBody body: The project brief to create. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectBriefResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'project_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_project_brief" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_project_brief`") # noqa: E501 - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `create_project_brief`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/project_briefs', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectBriefResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_project_brief(self, project_brief_gid, **kwargs): # noqa: E501 - """Delete a project brief # noqa: E501 - - Deletes a specific, existing project brief. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_project_brief(project_brief_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_brief_gid: Globally unique identifier for the project brief. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_project_brief_with_http_info(project_brief_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_project_brief_with_http_info(project_brief_gid, **kwargs) # noqa: E501 - return data - - def delete_project_brief_with_http_info(self, project_brief_gid, **kwargs): # noqa: E501 - """Delete a project brief # noqa: E501 - - Deletes a specific, existing project brief. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_project_brief_with_http_info(project_brief_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_brief_gid: Globally unique identifier for the project brief. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_brief_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_project_brief" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_brief_gid' is set - if ('project_brief_gid' not in params or - params['project_brief_gid'] is None): - raise ValueError("Missing the required parameter `project_brief_gid` when calling `delete_project_brief`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_brief_gid' in params: - path_params['project_brief_gid'] = params['project_brief_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/project_briefs/{project_brief_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_project_brief(self, project_brief_gid, **kwargs): # noqa: E501 - """Get a project brief # noqa: E501 - - Get the full record for a project brief. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_brief(project_brief_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_brief_gid: Globally unique identifier for the project brief. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectBriefResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_project_brief_with_http_info(project_brief_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_project_brief_with_http_info(project_brief_gid, **kwargs) # noqa: E501 - return data - - def get_project_brief_with_http_info(self, project_brief_gid, **kwargs): # noqa: E501 - """Get a project brief # noqa: E501 - - Get the full record for a project brief. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_brief_with_http_info(project_brief_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_brief_gid: Globally unique identifier for the project brief. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectBriefResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_brief_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_project_brief" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_brief_gid' is set - if ('project_brief_gid' not in params or - params['project_brief_gid'] is None): - raise ValueError("Missing the required parameter `project_brief_gid` when calling `get_project_brief`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_brief_gid' in params: - path_params['project_brief_gid'] = params['project_brief_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/project_briefs/{project_brief_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectBriefResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_project_brief(self, body, project_brief_gid, **kwargs): # noqa: E501 - """Update a project brief # noqa: E501 - - An existing project brief can be updated by making a PUT request on the URL for that project brief. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. Returns the complete updated project brief record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_project_brief(body, project_brief_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectBriefsProjectBriefGidBody body: The updated fields for the project brief. (required) - :param str project_brief_gid: Globally unique identifier for the project brief. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectBriefResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_project_brief_with_http_info(body, project_brief_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_project_brief_with_http_info(body, project_brief_gid, **kwargs) # noqa: E501 - return data - - def update_project_brief_with_http_info(self, body, project_brief_gid, **kwargs): # noqa: E501 - """Update a project brief # noqa: E501 - - An existing project brief can be updated by making a PUT request on the URL for that project brief. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. Returns the complete updated project brief record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_project_brief_with_http_info(body, project_brief_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectBriefsProjectBriefGidBody body: The updated fields for the project brief. (required) - :param str project_brief_gid: Globally unique identifier for the project brief. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectBriefResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'project_brief_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_project_brief" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `update_project_brief`") # noqa: E501 - # verify the required parameter 'project_brief_gid' is set - if ('project_brief_gid' not in params or - params['project_brief_gid'] is None): - raise ValueError("Missing the required parameter `project_brief_gid` when calling `update_project_brief`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_brief_gid' in params: - path_params['project_brief_gid'] = params['project_brief_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/project_briefs/{project_brief_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectBriefResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/project_memberships_api.py b/asana/api/project_memberships_api.py deleted file mode 100644 index 72544538..00000000 --- a/asana/api/project_memberships_api.py +++ /dev/null @@ -1,249 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class ProjectMembershipsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def get_project_membership(self, project_membership_gid, **kwargs): # noqa: E501 - """Get a project membership # noqa: E501 - - Returns the complete project record for a single project membership. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_membership(project_membership_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_membership_gid: (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectMembershipNormalResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_project_membership_with_http_info(project_membership_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_project_membership_with_http_info(project_membership_gid, **kwargs) # noqa: E501 - return data - - def get_project_membership_with_http_info(self, project_membership_gid, **kwargs): # noqa: E501 - """Get a project membership # noqa: E501 - - Returns the complete project record for a single project membership. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_membership_with_http_info(project_membership_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_membership_gid: (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectMembershipNormalResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_membership_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_project_membership" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_membership_gid' is set - if ('project_membership_gid' not in params or - params['project_membership_gid'] is None): - raise ValueError("Missing the required parameter `project_membership_gid` when calling `get_project_membership`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_membership_gid' in params: - path_params['project_membership_gid'] = params['project_membership_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/project_memberships/{project_membership_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectMembershipNormalResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_project_memberships_for_project(self, project_gid, **kwargs): # noqa: E501 - """Get memberships from a project # noqa: E501 - - Returns the compact project membership records for the project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_memberships_for_project(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param str user: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectMembershipCompactArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_project_memberships_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_project_memberships_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - return data - - def get_project_memberships_for_project_with_http_info(self, project_gid, **kwargs): # noqa: E501 - """Get memberships from a project # noqa: E501 - - Returns the compact project membership records for the project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_memberships_for_project_with_http_info(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param str user: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectMembershipCompactArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_gid', 'user', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_project_memberships_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `get_project_memberships_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'user' in params: - query_params.append(('user', params['user'])) # noqa: E501 - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/project_memberships', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectMembershipCompactArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/project_statuses_api.py b/asana/api/project_statuses_api.py deleted file mode 100644 index 850b6350..00000000 --- a/asana/api/project_statuses_api.py +++ /dev/null @@ -1,456 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class ProjectStatusesApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_project_status_for_project(self, body, project_gid, **kwargs): # noqa: E501 - """Create a project status # noqa: E501 - - *Deprecated: new integrations should prefer the `/status_updates` route.* Creates a new status update on the project. Returns the full record of the newly created project status update. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_project_status_for_project(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidProjectStatusesBody body: The project status to create. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectStatusResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_project_status_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - else: - (data) = self.create_project_status_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - return data - - def create_project_status_for_project_with_http_info(self, body, project_gid, **kwargs): # noqa: E501 - """Create a project status # noqa: E501 - - *Deprecated: new integrations should prefer the `/status_updates` route.* Creates a new status update on the project. Returns the full record of the newly created project status update. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_project_status_for_project_with_http_info(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidProjectStatusesBody body: The project status to create. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectStatusResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'project_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_project_status_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_project_status_for_project`") # noqa: E501 - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `create_project_status_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/project_statuses', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectStatusResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_project_status(self, project_status_gid, **kwargs): # noqa: E501 - """Delete a project status # noqa: E501 - - *Deprecated: new integrations should prefer the `/status_updates/{status_gid}` route.* Deletes a specific, existing project status update. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_project_status(project_status_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_status_gid: The project status update to get. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_project_status_with_http_info(project_status_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_project_status_with_http_info(project_status_gid, **kwargs) # noqa: E501 - return data - - def delete_project_status_with_http_info(self, project_status_gid, **kwargs): # noqa: E501 - """Delete a project status # noqa: E501 - - *Deprecated: new integrations should prefer the `/status_updates/{status_gid}` route.* Deletes a specific, existing project status update. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_project_status_with_http_info(project_status_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_status_gid: The project status update to get. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_status_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_project_status" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_status_gid' is set - if ('project_status_gid' not in params or - params['project_status_gid'] is None): - raise ValueError("Missing the required parameter `project_status_gid` when calling `delete_project_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_status_gid' in params: - path_params['project_status_gid'] = params['project_status_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/project_statuses/{project_status_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_project_status(self, project_status_gid, **kwargs): # noqa: E501 - """Get a project status # noqa: E501 - - *Deprecated: new integrations should prefer the `/status_updates/{status_gid}` route.* Returns the complete record for a single status update. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_status(project_status_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_status_gid: The project status update to get. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectStatusResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_project_status_with_http_info(project_status_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_project_status_with_http_info(project_status_gid, **kwargs) # noqa: E501 - return data - - def get_project_status_with_http_info(self, project_status_gid, **kwargs): # noqa: E501 - """Get a project status # noqa: E501 - - *Deprecated: new integrations should prefer the `/status_updates/{status_gid}` route.* Returns the complete record for a single status update. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_status_with_http_info(project_status_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_status_gid: The project status update to get. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectStatusResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_status_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_project_status" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_status_gid' is set - if ('project_status_gid' not in params or - params['project_status_gid'] is None): - raise ValueError("Missing the required parameter `project_status_gid` when calling `get_project_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_status_gid' in params: - path_params['project_status_gid'] = params['project_status_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/project_statuses/{project_status_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectStatusResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_project_statuses_for_project(self, project_gid, **kwargs): # noqa: E501 - """Get statuses from a project # noqa: E501 - - *Deprecated: new integrations should prefer the `/status_updates` route.* Returns the compact project status update records for all updates on the project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_statuses_for_project(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectStatusResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_project_statuses_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_project_statuses_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - return data - - def get_project_statuses_for_project_with_http_info(self, project_gid, **kwargs): # noqa: E501 - """Get statuses from a project # noqa: E501 - - *Deprecated: new integrations should prefer the `/status_updates` route.* Returns the compact project status update records for all updates on the project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_statuses_for_project_with_http_info(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectStatusResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_project_statuses_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `get_project_statuses_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/project_statuses', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectStatusResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/project_templates_api.py b/asana/api/project_templates_api.py deleted file mode 100644 index 0c94be6d..00000000 --- a/asana/api/project_templates_api.py +++ /dev/null @@ -1,562 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class ProjectTemplatesApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def delete_project_template(self, project_template_gid, **kwargs): # noqa: E501 - """Delete a project template # noqa: E501 - - A specific, existing project template can be deleted by making a DELETE request on the URL for that project template. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_project_template(project_template_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_template_gid: Globally unique identifier for the project template. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_project_template_with_http_info(project_template_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_project_template_with_http_info(project_template_gid, **kwargs) # noqa: E501 - return data - - def delete_project_template_with_http_info(self, project_template_gid, **kwargs): # noqa: E501 - """Delete a project template # noqa: E501 - - A specific, existing project template can be deleted by making a DELETE request on the URL for that project template. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_project_template_with_http_info(project_template_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_template_gid: Globally unique identifier for the project template. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_template_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_project_template" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_template_gid' is set - if ('project_template_gid' not in params or - params['project_template_gid'] is None): - raise ValueError("Missing the required parameter `project_template_gid` when calling `delete_project_template`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_template_gid' in params: - path_params['project_template_gid'] = params['project_template_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/project_templates/{project_template_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_project_template(self, project_template_gid, **kwargs): # noqa: E501 - """Get a project template # noqa: E501 - - Returns the complete project template record for a single project template. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_template(project_template_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_template_gid: Globally unique identifier for the project template. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectTemplateResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_project_template_with_http_info(project_template_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_project_template_with_http_info(project_template_gid, **kwargs) # noqa: E501 - return data - - def get_project_template_with_http_info(self, project_template_gid, **kwargs): # noqa: E501 - """Get a project template # noqa: E501 - - Returns the complete project template record for a single project template. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_template_with_http_info(project_template_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_template_gid: Globally unique identifier for the project template. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectTemplateResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_template_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_project_template" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_template_gid' is set - if ('project_template_gid' not in params or - params['project_template_gid'] is None): - raise ValueError("Missing the required parameter `project_template_gid` when calling `get_project_template`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_template_gid' in params: - path_params['project_template_gid'] = params['project_template_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/project_templates/{project_template_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectTemplateResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_project_templates(self, **kwargs): # noqa: E501 - """Get multiple project templates # noqa: E501 - - Returns the compact project template records for all project templates in the given team or workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_templates(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace: The workspace to filter results on. - :param str team: The team to filter projects on. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectTemplateResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_project_templates_with_http_info(**kwargs) # noqa: E501 - else: - (data) = self.get_project_templates_with_http_info(**kwargs) # noqa: E501 - return data - - def get_project_templates_with_http_info(self, **kwargs): # noqa: E501 - """Get multiple project templates # noqa: E501 - - Returns the compact project template records for all project templates in the given team or workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_templates_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace: The workspace to filter results on. - :param str team: The team to filter projects on. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectTemplateResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace', 'team', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_project_templates" % key - ) - params[key] = val - del params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'team' in params: - query_params.append(('team', params['team'])) # noqa: E501 - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/project_templates', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectTemplateResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_project_templates_for_team(self, team_gid, **kwargs): # noqa: E501 - """Get a team's project templates # noqa: E501 - - Returns the compact project template records for all project templates in the team. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_templates_for_team(team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str team_gid: Globally unique identifier for the team. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectTemplateResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_project_templates_for_team_with_http_info(team_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_project_templates_for_team_with_http_info(team_gid, **kwargs) # noqa: E501 - return data - - def get_project_templates_for_team_with_http_info(self, team_gid, **kwargs): # noqa: E501 - """Get a team's project templates # noqa: E501 - - Returns the compact project template records for all project templates in the team. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_templates_for_team_with_http_info(team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str team_gid: Globally unique identifier for the team. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectTemplateResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['team_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_project_templates_for_team" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'team_gid' is set - if ('team_gid' not in params or - params['team_gid'] is None): - raise ValueError("Missing the required parameter `team_gid` when calling `get_project_templates_for_team`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'team_gid' in params: - path_params['team_gid'] = params['team_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/teams/{team_gid}/project_templates', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectTemplateResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def instantiate_project(self, project_template_gid, **kwargs): # noqa: E501 - """Instantiate a project from a project template # noqa: E501 - - Creates and returns a job that will asynchronously handle the project instantiation. To form this request, it is recommended to first make a request to [get a project template](/reference/getprojecttemplate). Then, from the response, copy the `gid` from the object in the `requested_dates` array. This `gid` should be used in `requested_dates` to instantiate a project. _Note: The body of this request will differ if your workspace is an organization. To determine if your workspace is an organization, use the [is_organization](/reference/workspaces) parameter._ # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.instantiate_project(project_template_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_template_gid: Globally unique identifier for the project template. (required) - :param ProjectTemplateGidInstantiateProjectBody body: Describes the inputs used for instantiating a project, such as the resulting project's name, which team it should be created in, and values for date variables. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: JobResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.instantiate_project_with_http_info(project_template_gid, **kwargs) # noqa: E501 - else: - (data) = self.instantiate_project_with_http_info(project_template_gid, **kwargs) # noqa: E501 - return data - - def instantiate_project_with_http_info(self, project_template_gid, **kwargs): # noqa: E501 - """Instantiate a project from a project template # noqa: E501 - - Creates and returns a job that will asynchronously handle the project instantiation. To form this request, it is recommended to first make a request to [get a project template](/reference/getprojecttemplate). Then, from the response, copy the `gid` from the object in the `requested_dates` array. This `gid` should be used in `requested_dates` to instantiate a project. _Note: The body of this request will differ if your workspace is an organization. To determine if your workspace is an organization, use the [is_organization](/reference/workspaces) parameter._ # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.instantiate_project_with_http_info(project_template_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_template_gid: Globally unique identifier for the project template. (required) - :param ProjectTemplateGidInstantiateProjectBody body: Describes the inputs used for instantiating a project, such as the resulting project's name, which team it should be created in, and values for date variables. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: JobResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_template_gid', 'body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method instantiate_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_template_gid' is set - if ('project_template_gid' not in params or - params['project_template_gid'] is None): - raise ValueError("Missing the required parameter `project_template_gid` when calling `instantiate_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_template_gid' in params: - path_params['project_template_gid'] = params['project_template_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/project_templates/{project_template_gid}/instantiateProject', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='JobResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/projects_api.py b/asana/api/projects_api.py deleted file mode 100644 index fed985eb..00000000 --- a/asana/api/projects_api.py +++ /dev/null @@ -1,2132 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class ProjectsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def add_custom_field_setting_for_project(self, body, project_gid, **kwargs): # noqa: E501 - """Add a custom field to a project # noqa: E501 - - Custom fields are associated with projects by way of custom field settings. This method creates a setting for the project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_custom_field_setting_for_project(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidAddCustomFieldSettingBody body: Information about the custom field setting. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :return: CustomFieldSettingResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_custom_field_setting_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_custom_field_setting_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - return data - - def add_custom_field_setting_for_project_with_http_info(self, body, project_gid, **kwargs): # noqa: E501 - """Add a custom field to a project # noqa: E501 - - Custom fields are associated with projects by way of custom field settings. This method creates a setting for the project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_custom_field_setting_for_project_with_http_info(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidAddCustomFieldSettingBody body: Information about the custom field setting. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :return: CustomFieldSettingResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'project_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_custom_field_setting_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_custom_field_setting_for_project`") # noqa: E501 - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `add_custom_field_setting_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/addCustomFieldSetting', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='CustomFieldSettingResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def add_followers_for_project(self, body, project_gid, **kwargs): # noqa: E501 - """Add followers to a project # noqa: E501 - - Adds the specified list of users as followers to the project. Followers are a subset of members who have opted in to receive \"tasks added\" notifications for a project. Therefore, if the users are not already members of the project, they will also become members as a result of this operation. Returns the updated project record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_followers_for_project(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidAddFollowersBody body: Information about the followers being added. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_followers_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_followers_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - return data - - def add_followers_for_project_with_http_info(self, body, project_gid, **kwargs): # noqa: E501 - """Add followers to a project # noqa: E501 - - Adds the specified list of users as followers to the project. Followers are a subset of members who have opted in to receive \"tasks added\" notifications for a project. Therefore, if the users are not already members of the project, they will also become members as a result of this operation. Returns the updated project record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_followers_for_project_with_http_info(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidAddFollowersBody body: Information about the followers being added. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'project_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_followers_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_followers_for_project`") # noqa: E501 - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `add_followers_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/addFollowers', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def add_members_for_project(self, body, project_gid, **kwargs): # noqa: E501 - """Add users to a project # noqa: E501 - - Adds the specified list of users as members of the project. Note that a user being added as a member may also be added as a *follower* as a result of this operation. This is because the user's default notification settings (i.e., in the \"Notifcations\" tab of \"My Profile Settings\") will override this endpoint's default behavior of setting \"Tasks added\" notifications to `false`. Returns the updated project record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_members_for_project(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidAddMembersBody body: Information about the members being added. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_members_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_members_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - return data - - def add_members_for_project_with_http_info(self, body, project_gid, **kwargs): # noqa: E501 - """Add users to a project # noqa: E501 - - Adds the specified list of users as members of the project. Note that a user being added as a member may also be added as a *follower* as a result of this operation. This is because the user's default notification settings (i.e., in the \"Notifcations\" tab of \"My Profile Settings\") will override this endpoint's default behavior of setting \"Tasks added\" notifications to `false`. Returns the updated project record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_members_for_project_with_http_info(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidAddMembersBody body: Information about the members being added. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'project_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_members_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_members_for_project`") # noqa: E501 - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `add_members_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/addMembers', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_project(self, body, **kwargs): # noqa: E501 - """Create a project # noqa: E501 - - Create a new project in a workspace or team. Every project is required to be created in a specific workspace or organization, and this cannot be changed once set. Note that you can use the `workspace` parameter regardless of whether or not it is an organization. If the workspace for your project is an organization, you must also supply a `team` to share the project with. Returns the full record of the newly created project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_project(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectsBody body: The project to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_project_with_http_info(body, **kwargs) # noqa: E501 - else: - (data) = self.create_project_with_http_info(body, **kwargs) # noqa: E501 - return data - - def create_project_with_http_info(self, body, **kwargs): # noqa: E501 - """Create a project # noqa: E501 - - Create a new project in a workspace or team. Every project is required to be created in a specific workspace or organization, and this cannot be changed once set. Note that you can use the `workspace` parameter regardless of whether or not it is an organization. If the workspace for your project is an organization, you must also supply a `team` to share the project with. Returns the full record of the newly created project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_project_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectsBody body: The project to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_project_for_team(self, body, team_gid, **kwargs): # noqa: E501 - """Create a project in a team # noqa: E501 - - Creates a project shared with the given team. Returns the full record of the newly created project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_project_for_team(body, team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TeamGidProjectsBody body: The new project to create. (required) - :param str team_gid: Globally unique identifier for the team. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_project_for_team_with_http_info(body, team_gid, **kwargs) # noqa: E501 - else: - (data) = self.create_project_for_team_with_http_info(body, team_gid, **kwargs) # noqa: E501 - return data - - def create_project_for_team_with_http_info(self, body, team_gid, **kwargs): # noqa: E501 - """Create a project in a team # noqa: E501 - - Creates a project shared with the given team. Returns the full record of the newly created project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_project_for_team_with_http_info(body, team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TeamGidProjectsBody body: The new project to create. (required) - :param str team_gid: Globally unique identifier for the team. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'team_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_project_for_team" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_project_for_team`") # noqa: E501 - # verify the required parameter 'team_gid' is set - if ('team_gid' not in params or - params['team_gid'] is None): - raise ValueError("Missing the required parameter `team_gid` when calling `create_project_for_team`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'team_gid' in params: - path_params['team_gid'] = params['team_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/teams/{team_gid}/projects', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_project_for_workspace(self, body, workspace_gid, **kwargs): # noqa: E501 - """Create a project in a workspace # noqa: E501 - - Creates a project in the workspace. If the workspace for your project is an organization, you must also supply a team to share the project with. Returns the full record of the newly created project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_project_for_workspace(body, workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WorkspaceGidProjectsBody body: The new project to create. (required) - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_project_for_workspace_with_http_info(body, workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.create_project_for_workspace_with_http_info(body, workspace_gid, **kwargs) # noqa: E501 - return data - - def create_project_for_workspace_with_http_info(self, body, workspace_gid, **kwargs): # noqa: E501 - """Create a project in a workspace # noqa: E501 - - Creates a project in the workspace. If the workspace for your project is an organization, you must also supply a team to share the project with. Returns the full record of the newly created project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_project_for_workspace_with_http_info(body, workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WorkspaceGidProjectsBody body: The new project to create. (required) - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'workspace_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_project_for_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_project_for_workspace`") # noqa: E501 - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `create_project_for_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}/projects', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_project(self, project_gid, **kwargs): # noqa: E501 - """Delete a project # noqa: E501 - - A specific, existing project can be deleted by making a DELETE request on the URL for that project. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_project(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_project_with_http_info(project_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_project_with_http_info(project_gid, **kwargs) # noqa: E501 - return data - - def delete_project_with_http_info(self, project_gid, **kwargs): # noqa: E501 - """Delete a project # noqa: E501 - - A specific, existing project can be deleted by making a DELETE request on the URL for that project. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_project_with_http_info(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `delete_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def duplicate_project(self, project_gid, **kwargs): # noqa: E501 - """Duplicate a project # noqa: E501 - - Creates and returns a job that will asynchronously handle the duplication. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.duplicate_project(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param ProjectGidDuplicateBody body: Describes the duplicate's name and the elements that will be duplicated. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: JobResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.duplicate_project_with_http_info(project_gid, **kwargs) # noqa: E501 - else: - (data) = self.duplicate_project_with_http_info(project_gid, **kwargs) # noqa: E501 - return data - - def duplicate_project_with_http_info(self, project_gid, **kwargs): # noqa: E501 - """Duplicate a project # noqa: E501 - - Creates and returns a job that will asynchronously handle the duplication. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.duplicate_project_with_http_info(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param ProjectGidDuplicateBody body: Describes the duplicate's name and the elements that will be duplicated. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: JobResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_gid', 'body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method duplicate_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `duplicate_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/duplicate', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='JobResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_project(self, project_gid, **kwargs): # noqa: E501 - """Get a project # noqa: E501 - - Returns the complete project record for a single project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_project_with_http_info(project_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_project_with_http_info(project_gid, **kwargs) # noqa: E501 - return data - - def get_project_with_http_info(self, project_gid, **kwargs): # noqa: E501 - """Get a project # noqa: E501 - - Returns the complete project record for a single project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_project_with_http_info(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `get_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_projects(self, **kwargs): # noqa: E501 - """Get multiple projects # noqa: E501 - - Returns the compact project records for some filtered set of projects. Use one or more of the parameters provided to filter the projects returned. *Note: This endpoint may timeout for large domains. Try filtering by team!* # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_projects(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str workspace: The workspace or organization to filter projects on. - :param str team: The team to filter projects on. - :param bool archived: Only return projects whose `archived` field takes on the value of this parameter. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_projects_with_http_info(**kwargs) # noqa: E501 - else: - (data) = self.get_projects_with_http_info(**kwargs) # noqa: E501 - return data - - def get_projects_with_http_info(self, **kwargs): # noqa: E501 - """Get multiple projects # noqa: E501 - - Returns the compact project records for some filtered set of projects. Use one or more of the parameters provided to filter the projects returned. *Note: This endpoint may timeout for large domains. Try filtering by team!* # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_projects_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str workspace: The workspace or organization to filter projects on. - :param str team: The team to filter projects on. - :param bool archived: Only return projects whose `archived` field takes on the value of this parameter. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['limit', 'offset', 'workspace', 'team', 'archived', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_projects" % key - ) - params[key] = val - del params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'team' in params: - query_params.append(('team', params['team'])) # noqa: E501 - if 'archived' in params: - query_params.append(('archived', params['archived'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_projects_for_task(self, task_gid, **kwargs): # noqa: E501 - """Get projects a task is in # noqa: E501 - - Returns a compact representation of all of the projects the task is in. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_projects_for_task(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_projects_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_projects_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - return data - - def get_projects_for_task_with_http_info(self, task_gid, **kwargs): # noqa: E501 - """Get projects a task is in # noqa: E501 - - Returns a compact representation of all of the projects the task is in. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_projects_for_task_with_http_info(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['task_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_projects_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `get_projects_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/projects', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_projects_for_team(self, team_gid, **kwargs): # noqa: E501 - """Get a team's projects # noqa: E501 - - Returns the compact project records for all projects in the team. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_projects_for_team(team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str team_gid: Globally unique identifier for the team. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param bool archived: Only return projects whose `archived` field takes on the value of this parameter. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_projects_for_team_with_http_info(team_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_projects_for_team_with_http_info(team_gid, **kwargs) # noqa: E501 - return data - - def get_projects_for_team_with_http_info(self, team_gid, **kwargs): # noqa: E501 - """Get a team's projects # noqa: E501 - - Returns the compact project records for all projects in the team. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_projects_for_team_with_http_info(team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str team_gid: Globally unique identifier for the team. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param bool archived: Only return projects whose `archived` field takes on the value of this parameter. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['team_gid', 'limit', 'offset', 'archived', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_projects_for_team" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'team_gid' is set - if ('team_gid' not in params or - params['team_gid'] is None): - raise ValueError("Missing the required parameter `team_gid` when calling `get_projects_for_team`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'team_gid' in params: - path_params['team_gid'] = params['team_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'archived' in params: - query_params.append(('archived', params['archived'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/teams/{team_gid}/projects', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_projects_for_workspace(self, workspace_gid, **kwargs): # noqa: E501 - """Get all projects in a workspace # noqa: E501 - - Returns the compact project records for all projects in the workspace. *Note: This endpoint may timeout for large domains. Prefer the `/teams/{team_gid}/projects` endpoint.* # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_projects_for_workspace(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param bool archived: Only return projects whose `archived` field takes on the value of this parameter. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_projects_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_projects_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - return data - - def get_projects_for_workspace_with_http_info(self, workspace_gid, **kwargs): # noqa: E501 - """Get all projects in a workspace # noqa: E501 - - Returns the compact project records for all projects in the workspace. *Note: This endpoint may timeout for large domains. Prefer the `/teams/{team_gid}/projects` endpoint.* # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_projects_for_workspace_with_http_info(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param bool archived: Only return projects whose `archived` field takes on the value of this parameter. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace_gid', 'limit', 'offset', 'archived', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_projects_for_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `get_projects_for_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'archived' in params: - query_params.append(('archived', params['archived'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}/projects', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_task_counts_for_project(self, project_gid, **kwargs): # noqa: E501 - """Get task count of a project # noqa: E501 - - Get an object that holds task count fields. **All fields are excluded by default**. You must [opt in](/docs/inputoutput-options) using `opt_fields` to get any information from this endpoint. This endpoint has an additional [rate limit](/docs/rate-limits) and each field counts especially high against our [cost limits](/docs/rate-limits#cost-limits). Milestones are just tasks, so they are included in the `num_tasks`, `num_incomplete_tasks`, and `num_completed_tasks` counts. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_task_counts_for_project(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskCountResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_task_counts_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_task_counts_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - return data - - def get_task_counts_for_project_with_http_info(self, project_gid, **kwargs): # noqa: E501 - """Get task count of a project # noqa: E501 - - Get an object that holds task count fields. **All fields are excluded by default**. You must [opt in](/docs/inputoutput-options) using `opt_fields` to get any information from this endpoint. This endpoint has an additional [rate limit](/docs/rate-limits) and each field counts especially high against our [cost limits](/docs/rate-limits#cost-limits). Milestones are just tasks, so they are included in the `num_tasks`, `num_incomplete_tasks`, and `num_completed_tasks` counts. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_task_counts_for_project_with_http_info(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskCountResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_task_counts_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `get_task_counts_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/task_counts', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskCountResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def project_save_as_template(self, body, project_gid, **kwargs): # noqa: E501 - """Create a project template from a project # noqa: E501 - - Creates and returns a job that will asynchronously handle the project template creation. Note that while the resulting project template can be accessed with the API, it won't be visible in the Asana UI until Project Templates 2.0 is launched in the app. See more in [this forum post](https://forum.asana.com/t/a-new-api-for-project-templates/156432). # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.project_save_as_template(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidSaveAsTemplateBody body: Describes the inputs used for creating a project template, such as the resulting project template's name, which team it should be created in. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: JobResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.project_save_as_template_with_http_info(body, project_gid, **kwargs) # noqa: E501 - else: - (data) = self.project_save_as_template_with_http_info(body, project_gid, **kwargs) # noqa: E501 - return data - - def project_save_as_template_with_http_info(self, body, project_gid, **kwargs): # noqa: E501 - """Create a project template from a project # noqa: E501 - - Creates and returns a job that will asynchronously handle the project template creation. Note that while the resulting project template can be accessed with the API, it won't be visible in the Asana UI until Project Templates 2.0 is launched in the app. See more in [this forum post](https://forum.asana.com/t/a-new-api-for-project-templates/156432). # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.project_save_as_template_with_http_info(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidSaveAsTemplateBody body: Describes the inputs used for creating a project template, such as the resulting project template's name, which team it should be created in. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: JobResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'project_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method project_save_as_template" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `project_save_as_template`") # noqa: E501 - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `project_save_as_template`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/saveAsTemplate', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='JobResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_custom_field_setting_for_project(self, body, project_gid, **kwargs): # noqa: E501 - """Remove a custom field from a project # noqa: E501 - - Removes a custom field setting from a project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_custom_field_setting_for_project(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidRemoveCustomFieldSettingBody body: Information about the custom field setting being removed. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_custom_field_setting_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_custom_field_setting_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - return data - - def remove_custom_field_setting_for_project_with_http_info(self, body, project_gid, **kwargs): # noqa: E501 - """Remove a custom field from a project # noqa: E501 - - Removes a custom field setting from a project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_custom_field_setting_for_project_with_http_info(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidRemoveCustomFieldSettingBody body: Information about the custom field setting being removed. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'project_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_custom_field_setting_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_custom_field_setting_for_project`") # noqa: E501 - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `remove_custom_field_setting_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/removeCustomFieldSetting', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_followers_for_project(self, body, project_gid, **kwargs): # noqa: E501 - """Remove followers from a project # noqa: E501 - - Removes the specified list of users from following the project, this will not affect project membership status. Returns the updated project record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_followers_for_project(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidRemoveFollowersBody body: Information about the followers being removed. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_followers_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_followers_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - return data - - def remove_followers_for_project_with_http_info(self, body, project_gid, **kwargs): # noqa: E501 - """Remove followers from a project # noqa: E501 - - Removes the specified list of users from following the project, this will not affect project membership status. Returns the updated project record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_followers_for_project_with_http_info(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidRemoveFollowersBody body: Information about the followers being removed. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'project_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_followers_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_followers_for_project`") # noqa: E501 - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `remove_followers_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/removeFollowers', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_members_for_project(self, body, project_gid, **kwargs): # noqa: E501 - """Remove users from a project # noqa: E501 - - Removes the specified list of users from members of the project. Returns the updated project record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_members_for_project(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidRemoveMembersBody body: Information about the members being removed. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_members_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_members_for_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - return data - - def remove_members_for_project_with_http_info(self, body, project_gid, **kwargs): # noqa: E501 - """Remove users from a project # noqa: E501 - - Removes the specified list of users from members of the project. Returns the updated project record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_members_for_project_with_http_info(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectGidRemoveMembersBody body: Information about the members being removed. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'project_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_members_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_members_for_project`") # noqa: E501 - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `remove_members_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/removeMembers', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_project(self, body, project_gid, **kwargs): # noqa: E501 - """Update a project # noqa: E501 - - A specific, existing project can be updated by making a PUT request on the URL for that project. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the task. Returns the complete updated project record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_project(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectsProjectGidBody body: The updated fields for the project. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_project_with_http_info(body, project_gid, **kwargs) # noqa: E501 - return data - - def update_project_with_http_info(self, body, project_gid, **kwargs): # noqa: E501 - """Update a project # noqa: E501 - - A specific, existing project can be updated by making a PUT request on the URL for that project. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the task. Returns the complete updated project record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_project_with_http_info(body, project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param ProjectsProjectGidBody body: The updated fields for the project. (required) - :param str project_gid: Globally unique identifier for the project. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: ProjectResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'project_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `update_project`") # noqa: E501 - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `update_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='ProjectResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/rules_api.py b/asana/api/rules_api.py deleted file mode 100644 index 3968cd38..00000000 --- a/asana/api/rules_api.py +++ /dev/null @@ -1,142 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class RulesApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def trigger_rule(self, body, rule_trigger_gid, **kwargs): # noqa: E501 - """Trigger a rule # noqa: E501 - - Trigger a rule which uses an [\"incoming web request\"](/docs/incoming-web-requests) trigger. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.trigger_rule(body, rule_trigger_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param RuleTriggerGidRunBody body: A dictionary of variables accessible from within the rule. (required) - :param str rule_trigger_gid: The ID of the incoming web request trigger. This value is a path parameter that is automatically generated for the API endpoint. (required) - :return: RuleTriggerResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.trigger_rule_with_http_info(body, rule_trigger_gid, **kwargs) # noqa: E501 - else: - (data) = self.trigger_rule_with_http_info(body, rule_trigger_gid, **kwargs) # noqa: E501 - return data - - def trigger_rule_with_http_info(self, body, rule_trigger_gid, **kwargs): # noqa: E501 - """Trigger a rule # noqa: E501 - - Trigger a rule which uses an [\"incoming web request\"](/docs/incoming-web-requests) trigger. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.trigger_rule_with_http_info(body, rule_trigger_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param RuleTriggerGidRunBody body: A dictionary of variables accessible from within the rule. (required) - :param str rule_trigger_gid: The ID of the incoming web request trigger. This value is a path parameter that is automatically generated for the API endpoint. (required) - :return: RuleTriggerResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'rule_trigger_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method trigger_rule" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `trigger_rule`") # noqa: E501 - # verify the required parameter 'rule_trigger_gid' is set - if ('rule_trigger_gid' not in params or - params['rule_trigger_gid'] is None): - raise ValueError("Missing the required parameter `rule_trigger_gid` when calling `trigger_rule`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'rule_trigger_gid' in params: - path_params['rule_trigger_gid'] = params['rule_trigger_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/rule_triggers/{rule_trigger_gid}/run', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='RuleTriggerResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/sections_api.py b/asana/api/sections_api.py deleted file mode 100644 index 20f4453b..00000000 --- a/asana/api/sections_api.py +++ /dev/null @@ -1,772 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class SectionsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def add_task_for_section(self, section_gid, **kwargs): # noqa: E501 - """Add task to section # noqa: E501 - - Add a task to a specific, existing section. This will remove the task from other sections of the project. The task will be inserted at the top of a section unless an insert_before or insert_after parameter is declared. This does not work for separators (tasks with the resource_subtype of section). # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_task_for_section(section_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str section_gid: The globally unique identifier for the section. (required) - :param SectionGidAddTaskBody body: The task and optionally the insert location. - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_task_for_section_with_http_info(section_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_task_for_section_with_http_info(section_gid, **kwargs) # noqa: E501 - return data - - def add_task_for_section_with_http_info(self, section_gid, **kwargs): # noqa: E501 - """Add task to section # noqa: E501 - - Add a task to a specific, existing section. This will remove the task from other sections of the project. The task will be inserted at the top of a section unless an insert_before or insert_after parameter is declared. This does not work for separators (tasks with the resource_subtype of section). # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_task_for_section_with_http_info(section_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str section_gid: The globally unique identifier for the section. (required) - :param SectionGidAddTaskBody body: The task and optionally the insert location. - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['section_gid', 'body'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_task_for_section" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'section_gid' is set - if ('section_gid' not in params or - params['section_gid'] is None): - raise ValueError("Missing the required parameter `section_gid` when calling `add_task_for_section`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'section_gid' in params: - path_params['section_gid'] = params['section_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/sections/{section_gid}/addTask', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_section_for_project(self, project_gid, **kwargs): # noqa: E501 - """Create a section in a project # noqa: E501 - - Creates a new section in a project. Returns the full record of the newly created section. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_section_for_project(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param ProjectGidSectionsBody body: The section to create. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: SectionResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_section_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - else: - (data) = self.create_section_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - return data - - def create_section_for_project_with_http_info(self, project_gid, **kwargs): # noqa: E501 - """Create a section in a project # noqa: E501 - - Creates a new section in a project. Returns the full record of the newly created section. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_section_for_project_with_http_info(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param ProjectGidSectionsBody body: The section to create. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: SectionResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_gid', 'body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_section_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `create_section_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/sections', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='SectionResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_section(self, section_gid, **kwargs): # noqa: E501 - """Delete a section # noqa: E501 - - A specific, existing section can be deleted by making a DELETE request on the URL for that section. Note that sections must be empty to be deleted. The last remaining section cannot be deleted. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_section(section_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str section_gid: The globally unique identifier for the section. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_section_with_http_info(section_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_section_with_http_info(section_gid, **kwargs) # noqa: E501 - return data - - def delete_section_with_http_info(self, section_gid, **kwargs): # noqa: E501 - """Delete a section # noqa: E501 - - A specific, existing section can be deleted by making a DELETE request on the URL for that section. Note that sections must be empty to be deleted. The last remaining section cannot be deleted. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_section_with_http_info(section_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str section_gid: The globally unique identifier for the section. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['section_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_section" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'section_gid' is set - if ('section_gid' not in params or - params['section_gid'] is None): - raise ValueError("Missing the required parameter `section_gid` when calling `delete_section`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'section_gid' in params: - path_params['section_gid'] = params['section_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/sections/{section_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_section(self, section_gid, **kwargs): # noqa: E501 - """Get a section # noqa: E501 - - Returns the complete record for a single section. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_section(section_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str section_gid: The globally unique identifier for the section. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: SectionResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_section_with_http_info(section_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_section_with_http_info(section_gid, **kwargs) # noqa: E501 - return data - - def get_section_with_http_info(self, section_gid, **kwargs): # noqa: E501 - """Get a section # noqa: E501 - - Returns the complete record for a single section. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_section_with_http_info(section_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str section_gid: The globally unique identifier for the section. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: SectionResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['section_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_section" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'section_gid' is set - if ('section_gid' not in params or - params['section_gid'] is None): - raise ValueError("Missing the required parameter `section_gid` when calling `get_section`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'section_gid' in params: - path_params['section_gid'] = params['section_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/sections/{section_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='SectionResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_sections_for_project(self, project_gid, **kwargs): # noqa: E501 - """Get sections in a project # noqa: E501 - - Returns the compact records for all sections in the specified project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_sections_for_project(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: SectionResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_sections_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_sections_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - return data - - def get_sections_for_project_with_http_info(self, project_gid, **kwargs): # noqa: E501 - """Get sections in a project # noqa: E501 - - Returns the compact records for all sections in the specified project. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_sections_for_project_with_http_info(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: SectionResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_sections_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `get_sections_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/sections', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='SectionResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def insert_section_for_project(self, project_gid, **kwargs): # noqa: E501 - """Move or Insert sections # noqa: E501 - - Move sections relative to each other. One of `before_section` or `after_section` is required. Sections cannot be moved between projects. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.insert_section_for_project(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param SectionsInsertBody body: The section's move action. - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.insert_section_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - else: - (data) = self.insert_section_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - return data - - def insert_section_for_project_with_http_info(self, project_gid, **kwargs): # noqa: E501 - """Move or Insert sections # noqa: E501 - - Move sections relative to each other. One of `before_section` or `after_section` is required. Sections cannot be moved between projects. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.insert_section_for_project_with_http_info(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param SectionsInsertBody body: The section's move action. - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_gid', 'body'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method insert_section_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `insert_section_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/sections/insert', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_section(self, section_gid, **kwargs): # noqa: E501 - """Update a section # noqa: E501 - - A specific, existing section can be updated by making a PUT request on the URL for that project. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. (note that at this time, the only field that can be updated is the `name` field.) When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the task. Returns the complete updated section record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_section(section_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str section_gid: The globally unique identifier for the section. (required) - :param SectionsSectionGidBody body: The section to create. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: SectionResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_section_with_http_info(section_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_section_with_http_info(section_gid, **kwargs) # noqa: E501 - return data - - def update_section_with_http_info(self, section_gid, **kwargs): # noqa: E501 - """Update a section # noqa: E501 - - A specific, existing section can be updated by making a PUT request on the URL for that project. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. (note that at this time, the only field that can be updated is the `name` field.) When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the task. Returns the complete updated section record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_section_with_http_info(section_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str section_gid: The globally unique identifier for the section. (required) - :param SectionsSectionGidBody body: The section to create. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: SectionResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['section_gid', 'body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_section" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'section_gid' is set - if ('section_gid' not in params or - params['section_gid'] is None): - raise ValueError("Missing the required parameter `section_gid` when calling `update_section`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'section_gid' in params: - path_params['section_gid'] = params['section_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/sections/{section_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='SectionResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/status_updates_api.py b/asana/api/status_updates_api.py deleted file mode 100644 index ac732fab..00000000 --- a/asana/api/status_updates_api.py +++ /dev/null @@ -1,460 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class StatusUpdatesApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_status_for_object(self, body, **kwargs): # noqa: E501 - """Create a status update # noqa: E501 - - Creates a new status update on an object. Returns the full record of the newly created status update. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_status_for_object(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param StatusUpdatesBody body: The status update to create. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StatusUpdateResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_status_for_object_with_http_info(body, **kwargs) # noqa: E501 - else: - (data) = self.create_status_for_object_with_http_info(body, **kwargs) # noqa: E501 - return data - - def create_status_for_object_with_http_info(self, body, **kwargs): # noqa: E501 - """Create a status update # noqa: E501 - - Creates a new status update on an object. Returns the full record of the newly created status update. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_status_for_object_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param StatusUpdatesBody body: The status update to create. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StatusUpdateResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_status_for_object" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_status_for_object`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/status_updates', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='StatusUpdateResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_status(self, status_update_gid, **kwargs): # noqa: E501 - """Delete a status update # noqa: E501 - - Deletes a specific, existing status update. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_status(status_update_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str status_update_gid: The status update to get. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_status_with_http_info(status_update_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_status_with_http_info(status_update_gid, **kwargs) # noqa: E501 - return data - - def delete_status_with_http_info(self, status_update_gid, **kwargs): # noqa: E501 - """Delete a status update # noqa: E501 - - Deletes a specific, existing status update. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_status_with_http_info(status_update_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str status_update_gid: The status update to get. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['status_update_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_status" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'status_update_gid' is set - if ('status_update_gid' not in params or - params['status_update_gid'] is None): - raise ValueError("Missing the required parameter `status_update_gid` when calling `delete_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'status_update_gid' in params: - path_params['status_update_gid'] = params['status_update_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/status_updates/{status_update_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_status(self, status_update_gid, **kwargs): # noqa: E501 - """Get a status update # noqa: E501 - - Returns the complete record for a single status update. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_status(status_update_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str status_update_gid: The status update to get. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StatusUpdateResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_status_with_http_info(status_update_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_status_with_http_info(status_update_gid, **kwargs) # noqa: E501 - return data - - def get_status_with_http_info(self, status_update_gid, **kwargs): # noqa: E501 - """Get a status update # noqa: E501 - - Returns the complete record for a single status update. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_status_with_http_info(status_update_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str status_update_gid: The status update to get. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StatusUpdateResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['status_update_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_status" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'status_update_gid' is set - if ('status_update_gid' not in params or - params['status_update_gid'] is None): - raise ValueError("Missing the required parameter `status_update_gid` when calling `get_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'status_update_gid' in params: - path_params['status_update_gid'] = params['status_update_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/status_updates/{status_update_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='StatusUpdateResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_statuses_for_object(self, parent, **kwargs): # noqa: E501 - """Get status updates from an object # noqa: E501 - - Returns the compact status update records for all updates on the object. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_statuses_for_object(parent, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str parent: Globally unique identifier for object to fetch statuses from. Must be a GID for a project, portfolio, or goal. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param datetime created_since: Only return statuses that have been created since the given time. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StatusUpdateResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_statuses_for_object_with_http_info(parent, **kwargs) # noqa: E501 - else: - (data) = self.get_statuses_for_object_with_http_info(parent, **kwargs) # noqa: E501 - return data - - def get_statuses_for_object_with_http_info(self, parent, **kwargs): # noqa: E501 - """Get status updates from an object # noqa: E501 - - Returns the compact status update records for all updates on the object. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_statuses_for_object_with_http_info(parent, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str parent: Globally unique identifier for object to fetch statuses from. Must be a GID for a project, portfolio, or goal. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param datetime created_since: Only return statuses that have been created since the given time. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StatusUpdateResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['parent', 'limit', 'offset', 'created_since', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_statuses_for_object" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'parent' is set - if ('parent' not in params or - params['parent'] is None): - raise ValueError("Missing the required parameter `parent` when calling `get_statuses_for_object`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'parent' in params: - query_params.append(('parent', params['parent'])) # noqa: E501 - if 'created_since' in params: - query_params.append(('created_since', params['created_since'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/status_updates', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='StatusUpdateResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/stories_api.py b/asana/api/stories_api.py deleted file mode 100644 index 83a4d728..00000000 --- a/asana/api/stories_api.py +++ /dev/null @@ -1,570 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class StoriesApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_story_for_task(self, body, task_gid, **kwargs): # noqa: E501 - """Create a story on a task # noqa: E501 - - Adds a story to a task. This endpoint currently only allows for comment stories to be created. The comment will be authored by the currently authenticated user, and timestamped when the server receives the request. Returns the full record for the new story added to the task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_story_for_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidStoriesBody body: The story to create. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StoryResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_story_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.create_story_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def create_story_for_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Create a story on a task # noqa: E501 - - Adds a story to a task. This endpoint currently only allows for comment stories to be created. The comment will be authored by the currently authenticated user, and timestamped when the server receives the request. Returns the full record for the new story added to the task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_story_for_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidStoriesBody body: The story to create. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StoryResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_story_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_story_for_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `create_story_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/stories', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='StoryResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_story(self, story_gid, **kwargs): # noqa: E501 - """Delete a story # noqa: E501 - - Deletes a story. A user can only delete stories they have created. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_story(story_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str story_gid: Globally unique identifier for the story. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_story_with_http_info(story_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_story_with_http_info(story_gid, **kwargs) # noqa: E501 - return data - - def delete_story_with_http_info(self, story_gid, **kwargs): # noqa: E501 - """Delete a story # noqa: E501 - - Deletes a story. A user can only delete stories they have created. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_story_with_http_info(story_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str story_gid: Globally unique identifier for the story. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['story_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_story" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'story_gid' is set - if ('story_gid' not in params or - params['story_gid'] is None): - raise ValueError("Missing the required parameter `story_gid` when calling `delete_story`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'story_gid' in params: - path_params['story_gid'] = params['story_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/stories/{story_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_stories_for_task(self, task_gid, **kwargs): # noqa: E501 - """Get stories from a task # noqa: E501 - - Returns the compact records for all stories on the task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_stories_for_task(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StoryResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_stories_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_stories_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - return data - - def get_stories_for_task_with_http_info(self, task_gid, **kwargs): # noqa: E501 - """Get stories from a task # noqa: E501 - - Returns the compact records for all stories on the task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_stories_for_task_with_http_info(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StoryResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['task_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_stories_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `get_stories_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/stories', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='StoryResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_story(self, story_gid, **kwargs): # noqa: E501 - """Get a story # noqa: E501 - - Returns the full record for a single story. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_story(story_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str story_gid: Globally unique identifier for the story. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StoryResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_story_with_http_info(story_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_story_with_http_info(story_gid, **kwargs) # noqa: E501 - return data - - def get_story_with_http_info(self, story_gid, **kwargs): # noqa: E501 - """Get a story # noqa: E501 - - Returns the full record for a single story. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_story_with_http_info(story_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str story_gid: Globally unique identifier for the story. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StoryResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['story_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_story" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'story_gid' is set - if ('story_gid' not in params or - params['story_gid'] is None): - raise ValueError("Missing the required parameter `story_gid` when calling `get_story`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'story_gid' in params: - path_params['story_gid'] = params['story_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/stories/{story_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='StoryResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_story(self, body, story_gid, **kwargs): # noqa: E501 - """Update a story # noqa: E501 - - Updates the story and returns the full record for the updated story. Only comment stories can have their text updated, and only comment stories and attachment stories can be pinned. Only one of `text` and `html_text` can be specified. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_story(body, story_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param StoriesStoryGidBody body: The comment story to update. (required) - :param str story_gid: Globally unique identifier for the story. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StoryResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_story_with_http_info(body, story_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_story_with_http_info(body, story_gid, **kwargs) # noqa: E501 - return data - - def update_story_with_http_info(self, body, story_gid, **kwargs): # noqa: E501 - """Update a story # noqa: E501 - - Updates the story and returns the full record for the updated story. Only comment stories can have their text updated, and only comment stories and attachment stories can be pinned. Only one of `text` and `html_text` can be specified. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_story_with_http_info(body, story_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param StoriesStoryGidBody body: The comment story to update. (required) - :param str story_gid: Globally unique identifier for the story. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: StoryResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'story_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_story" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `update_story`") # noqa: E501 - # verify the required parameter 'story_gid' is set - if ('story_gid' not in params or - params['story_gid'] is None): - raise ValueError("Missing the required parameter `story_gid` when calling `update_story`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'story_gid' in params: - path_params['story_gid'] = params['story_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/stories/{story_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='StoryResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/tags_api.py b/asana/api/tags_api.py deleted file mode 100644 index 726dd5c0..00000000 --- a/asana/api/tags_api.py +++ /dev/null @@ -1,880 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class TagsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_tag(self, body, **kwargs): # noqa: E501 - """Create a tag # noqa: E501 - - Creates a new tag in a workspace or organization. Every tag is required to be created in a specific workspace or organization, and this cannot be changed once set. Note that you can use the workspace parameter regardless of whether or not it is an organization. Returns the full record of the newly created tag. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_tag(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TagsBody body: The tag to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_tag_with_http_info(body, **kwargs) # noqa: E501 - else: - (data) = self.create_tag_with_http_info(body, **kwargs) # noqa: E501 - return data - - def create_tag_with_http_info(self, body, **kwargs): # noqa: E501 - """Create a tag # noqa: E501 - - Creates a new tag in a workspace or organization. Every tag is required to be created in a specific workspace or organization, and this cannot be changed once set. Note that you can use the workspace parameter regardless of whether or not it is an organization. Returns the full record of the newly created tag. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_tag_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TagsBody body: The tag to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_tag" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_tag`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tags', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TagResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_tag_for_workspace(self, body, workspace_gid, **kwargs): # noqa: E501 - """Create a tag in a workspace # noqa: E501 - - Creates a new tag in a workspace or organization. Every tag is required to be created in a specific workspace or organization, and this cannot be changed once set. Note that you can use the workspace parameter regardless of whether or not it is an organization. Returns the full record of the newly created tag. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_tag_for_workspace(body, workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WorkspaceGidTagsBody body: The tag to create. (required) - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_tag_for_workspace_with_http_info(body, workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.create_tag_for_workspace_with_http_info(body, workspace_gid, **kwargs) # noqa: E501 - return data - - def create_tag_for_workspace_with_http_info(self, body, workspace_gid, **kwargs): # noqa: E501 - """Create a tag in a workspace # noqa: E501 - - Creates a new tag in a workspace or organization. Every tag is required to be created in a specific workspace or organization, and this cannot be changed once set. Note that you can use the workspace parameter regardless of whether or not it is an organization. Returns the full record of the newly created tag. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_tag_for_workspace_with_http_info(body, workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WorkspaceGidTagsBody body: The tag to create. (required) - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'workspace_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_tag_for_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_tag_for_workspace`") # noqa: E501 - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `create_tag_for_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}/tags', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TagResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_tag(self, tag_gid, **kwargs): # noqa: E501 - """Delete a tag # noqa: E501 - - A specific, existing tag can be deleted by making a DELETE request on the URL for that tag. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_tag(tag_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str tag_gid: Globally unique identifier for the tag. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_tag_with_http_info(tag_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_tag_with_http_info(tag_gid, **kwargs) # noqa: E501 - return data - - def delete_tag_with_http_info(self, tag_gid, **kwargs): # noqa: E501 - """Delete a tag # noqa: E501 - - A specific, existing tag can be deleted by making a DELETE request on the URL for that tag. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_tag_with_http_info(tag_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str tag_gid: Globally unique identifier for the tag. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['tag_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_tag" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'tag_gid' is set - if ('tag_gid' not in params or - params['tag_gid'] is None): - raise ValueError("Missing the required parameter `tag_gid` when calling `delete_tag`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'tag_gid' in params: - path_params['tag_gid'] = params['tag_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tags/{tag_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_tag(self, tag_gid, **kwargs): # noqa: E501 - """Get a tag # noqa: E501 - - Returns the complete tag record for a single tag. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tag(tag_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str tag_gid: Globally unique identifier for the tag. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_tag_with_http_info(tag_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_tag_with_http_info(tag_gid, **kwargs) # noqa: E501 - return data - - def get_tag_with_http_info(self, tag_gid, **kwargs): # noqa: E501 - """Get a tag # noqa: E501 - - Returns the complete tag record for a single tag. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tag_with_http_info(tag_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str tag_gid: Globally unique identifier for the tag. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['tag_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_tag" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'tag_gid' is set - if ('tag_gid' not in params or - params['tag_gid'] is None): - raise ValueError("Missing the required parameter `tag_gid` when calling `get_tag`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'tag_gid' in params: - path_params['tag_gid'] = params['tag_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tags/{tag_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TagResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_tags(self, **kwargs): # noqa: E501 - """Get multiple tags # noqa: E501 - - Returns the compact tag records for some filtered set of tags. Use one or more of the parameters provided to filter the tags returned. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tags(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str workspace: The workspace to filter tags on. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_tags_with_http_info(**kwargs) # noqa: E501 - else: - (data) = self.get_tags_with_http_info(**kwargs) # noqa: E501 - return data - - def get_tags_with_http_info(self, **kwargs): # noqa: E501 - """Get multiple tags # noqa: E501 - - Returns the compact tag records for some filtered set of tags. Use one or more of the parameters provided to filter the tags returned. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tags_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str workspace: The workspace to filter tags on. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['limit', 'offset', 'workspace', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_tags" % key - ) - params[key] = val - del params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tags', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TagResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_tags_for_task(self, task_gid, **kwargs): # noqa: E501 - """Get a task's tags # noqa: E501 - - Get a compact representation of all of the tags the task has. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tags_for_task(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_tags_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_tags_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - return data - - def get_tags_for_task_with_http_info(self, task_gid, **kwargs): # noqa: E501 - """Get a task's tags # noqa: E501 - - Get a compact representation of all of the tags the task has. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tags_for_task_with_http_info(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['task_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_tags_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `get_tags_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/tags', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TagResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_tags_for_workspace(self, workspace_gid, **kwargs): # noqa: E501 - """Get tags in a workspace # noqa: E501 - - Returns the compact tag records for some filtered set of tags. Use one or more of the parameters provided to filter the tags returned. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tags_for_workspace(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_tags_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_tags_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - return data - - def get_tags_for_workspace_with_http_info(self, workspace_gid, **kwargs): # noqa: E501 - """Get tags in a workspace # noqa: E501 - - Returns the compact tag records for some filtered set of tags. Use one or more of the parameters provided to filter the tags returned. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tags_for_workspace_with_http_info(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_tags_for_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `get_tags_for_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}/tags', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TagResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_tag(self, tag_gid, **kwargs): # noqa: E501 - """Update a tag # noqa: E501 - - Updates the properties of a tag. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the tag. Returns the complete updated tag record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_tag(tag_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str tag_gid: Globally unique identifier for the tag. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_tag_with_http_info(tag_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_tag_with_http_info(tag_gid, **kwargs) # noqa: E501 - return data - - def update_tag_with_http_info(self, tag_gid, **kwargs): # noqa: E501 - """Update a tag # noqa: E501 - - Updates the properties of a tag. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the tag. Returns the complete updated tag record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_tag_with_http_info(tag_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str tag_gid: Globally unique identifier for the tag. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TagResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['tag_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_tag" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'tag_gid' is set - if ('tag_gid' not in params or - params['tag_gid'] is None): - raise ValueError("Missing the required parameter `tag_gid` when calling `update_tag`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'tag_gid' in params: - path_params['tag_gid'] = params['tag_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tags/{tag_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TagResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/task_templates_api.py b/asana/api/task_templates_api.py deleted file mode 100644 index 0862ad0c..00000000 --- a/asana/api/task_templates_api.py +++ /dev/null @@ -1,351 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class TaskTemplatesApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def get_task_template(self, task_template_gid, **kwargs): # noqa: E501 - """Get a task template # noqa: E501 - - Returns the complete task template record for a single task template. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_task_template(task_template_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_template_gid: Globally unique identifier for the task template. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskTemplateResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_task_template_with_http_info(task_template_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_task_template_with_http_info(task_template_gid, **kwargs) # noqa: E501 - return data - - def get_task_template_with_http_info(self, task_template_gid, **kwargs): # noqa: E501 - """Get a task template # noqa: E501 - - Returns the complete task template record for a single task template. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_task_template_with_http_info(task_template_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_template_gid: Globally unique identifier for the task template. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskTemplateResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['task_template_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_task_template" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'task_template_gid' is set - if ('task_template_gid' not in params or - params['task_template_gid'] is None): - raise ValueError("Missing the required parameter `task_template_gid` when calling `get_task_template`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_template_gid' in params: - path_params['task_template_gid'] = params['task_template_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/task_templates/{task_template_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskTemplateResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_task_templates(self, **kwargs): # noqa: E501 - """Get multiple task templates # noqa: E501 - - Returns the compact task template records for some filtered set of task templates. You must specify a `project` # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_task_templates(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str project: The project to filter task templates on. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskTemplateResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_task_templates_with_http_info(**kwargs) # noqa: E501 - else: - (data) = self.get_task_templates_with_http_info(**kwargs) # noqa: E501 - return data - - def get_task_templates_with_http_info(self, **kwargs): # noqa: E501 - """Get multiple task templates # noqa: E501 - - Returns the compact task template records for some filtered set of task templates. You must specify a `project` # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_task_templates_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str project: The project to filter task templates on. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskTemplateResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['limit', 'offset', 'project', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_task_templates" % key - ) - params[key] = val - del params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'project' in params: - query_params.append(('project', params['project'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/task_templates', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskTemplateResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def instantiate_task(self, task_template_gid, **kwargs): # noqa: E501 - """Instantiate a task from a task template # noqa: E501 - - Creates and returns a job that will asynchronously handle the task instantiation. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.instantiate_task(task_template_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_template_gid: Globally unique identifier for the task template. (required) - :param TaskTemplateGidInstantiateTaskBody body: Describes the inputs used for instantiating a task - the task's name. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: JobResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.instantiate_task_with_http_info(task_template_gid, **kwargs) # noqa: E501 - else: - (data) = self.instantiate_task_with_http_info(task_template_gid, **kwargs) # noqa: E501 - return data - - def instantiate_task_with_http_info(self, task_template_gid, **kwargs): # noqa: E501 - """Instantiate a task from a task template # noqa: E501 - - Creates and returns a job that will asynchronously handle the task instantiation. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.instantiate_task_with_http_info(task_template_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_template_gid: Globally unique identifier for the task template. (required) - :param TaskTemplateGidInstantiateTaskBody body: Describes the inputs used for instantiating a task - the task's name. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: JobResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['task_template_gid', 'body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method instantiate_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'task_template_gid' is set - if ('task_template_gid' not in params or - params['task_template_gid'] is None): - raise ValueError("Missing the required parameter `task_template_gid` when calling `instantiate_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_template_gid' in params: - path_params['task_template_gid'] = params['task_template_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/task_templates/{task_template_gid}/instantiateTask', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='JobResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/tasks_api.py b/asana/api/tasks_api.py deleted file mode 100644 index cbb9bbb6..00000000 --- a/asana/api/tasks_api.py +++ /dev/null @@ -1,3124 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class TasksApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def add_dependencies_for_task(self, body, task_gid, **kwargs): # noqa: E501 - """Set dependencies for a task # noqa: E501 - - Marks a set of tasks as dependencies of this task, if they are not already dependencies. *A task can have at most 30 dependents and dependencies combined*. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_dependencies_for_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidAddDependenciesBody body: The list of tasks to set as dependencies. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_dependencies_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_dependencies_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def add_dependencies_for_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Set dependencies for a task # noqa: E501 - - Marks a set of tasks as dependencies of this task, if they are not already dependencies. *A task can have at most 30 dependents and dependencies combined*. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_dependencies_for_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidAddDependenciesBody body: The list of tasks to set as dependencies. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_dependencies_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_dependencies_for_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `add_dependencies_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/addDependencies', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def add_dependents_for_task(self, body, task_gid, **kwargs): # noqa: E501 - """Set dependents for a task # noqa: E501 - - Marks a set of tasks as dependents of this task, if they are not already dependents. *A task can have at most 30 dependents and dependencies combined*. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_dependents_for_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidAddDependentsBody body: The list of tasks to add as dependents. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_dependents_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_dependents_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def add_dependents_for_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Set dependents for a task # noqa: E501 - - Marks a set of tasks as dependents of this task, if they are not already dependents. *A task can have at most 30 dependents and dependencies combined*. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_dependents_for_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidAddDependentsBody body: The list of tasks to add as dependents. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_dependents_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_dependents_for_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `add_dependents_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/addDependents', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def add_followers_for_task(self, body, task_gid, **kwargs): # noqa: E501 - """Add followers to a task # noqa: E501 - - Adds followers to a task. Returns an empty data block. Each task can be associated with zero or more followers in the system. Requests to add/remove followers, if successful, will return the complete updated task record, described above. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_followers_for_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidAddFollowersBody body: The followers to add to the task. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_followers_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_followers_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def add_followers_for_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Add followers to a task # noqa: E501 - - Adds followers to a task. Returns an empty data block. Each task can be associated with zero or more followers in the system. Requests to add/remove followers, if successful, will return the complete updated task record, described above. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_followers_for_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidAddFollowersBody body: The followers to add to the task. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_followers_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_followers_for_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `add_followers_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/addFollowers', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def add_project_for_task(self, body, task_gid, **kwargs): # noqa: E501 - """Add a project to a task # noqa: E501 - - Adds the task to the specified project, in the optional location specified. If no location arguments are given, the task will be added to the end of the project. `addProject` can also be used to reorder a task within a project or section that already contains it. At most one of `insert_before`, `insert_after`, or `section` should be specified. Inserting into a section in an non-order-dependent way can be done by specifying section, otherwise, to insert within a section in a particular place, specify `insert_before` or `insert_after` and a task within the section to anchor the position of this task. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_project_for_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidAddProjectBody body: The project to add the task to. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_project_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_project_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def add_project_for_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Add a project to a task # noqa: E501 - - Adds the task to the specified project, in the optional location specified. If no location arguments are given, the task will be added to the end of the project. `addProject` can also be used to reorder a task within a project or section that already contains it. At most one of `insert_before`, `insert_after`, or `section` should be specified. Inserting into a section in an non-order-dependent way can be done by specifying section, otherwise, to insert within a section in a particular place, specify `insert_before` or `insert_after` and a task within the section to anchor the position of this task. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_project_for_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidAddProjectBody body: The project to add the task to. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_project_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_project_for_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `add_project_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/addProject', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def add_tag_for_task(self, body, task_gid, **kwargs): # noqa: E501 - """Add a tag to a task # noqa: E501 - - Adds a tag to a task. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_tag_for_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidAddTagBody body: The tag to add to the task. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_tag_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_tag_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def add_tag_for_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Add a tag to a task # noqa: E501 - - Adds a tag to a task. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_tag_for_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidAddTagBody body: The tag to add to the task. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_tag_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_tag_for_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `add_tag_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/addTag', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_subtask_for_task(self, body, task_gid, **kwargs): # noqa: E501 - """Create a subtask # noqa: E501 - - Creates a new subtask and adds it to the parent task. Returns the full record for the newly created subtask. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_subtask_for_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidSubtasksBody body: The new subtask to create. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_subtask_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.create_subtask_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def create_subtask_for_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Create a subtask # noqa: E501 - - Creates a new subtask and adds it to the parent task. Returns the full record for the newly created subtask. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_subtask_for_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidSubtasksBody body: The new subtask to create. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_subtask_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_subtask_for_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `create_subtask_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/subtasks', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_task(self, body, **kwargs): # noqa: E501 - """Create a task # noqa: E501 - - Creating a new task is as easy as POSTing to the `/tasks` endpoint with a data block containing the fields you’d like to set on the task. Any unspecified fields will take on default values. Every task is required to be created in a specific workspace, and this workspace cannot be changed once set. The workspace need not be set explicitly if you specify `projects` or a `parent` task instead. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_task(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TasksBody body: The task to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_task_with_http_info(body, **kwargs) # noqa: E501 - else: - (data) = self.create_task_with_http_info(body, **kwargs) # noqa: E501 - return data - - def create_task_with_http_info(self, body, **kwargs): # noqa: E501 - """Create a task # noqa: E501 - - Creating a new task is as easy as POSTing to the `/tasks` endpoint with a data block containing the fields you’d like to set on the task. Any unspecified fields will take on default values. Every task is required to be created in a specific workspace, and this workspace cannot be changed once set. The workspace need not be set explicitly if you specify `projects` or a `parent` task instead. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_task_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TasksBody body: The task to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_task(self, task_gid, **kwargs): # noqa: E501 - """Delete a task # noqa: E501 - - A specific, existing task can be deleted by making a DELETE request on the URL for that task. Deleted tasks go into the “trash” of the user making the delete request. Tasks can be recovered from the trash within a period of 30 days; afterward they are completely removed from the system. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_task(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_task_with_http_info(task_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_task_with_http_info(task_gid, **kwargs) # noqa: E501 - return data - - def delete_task_with_http_info(self, task_gid, **kwargs): # noqa: E501 - """Delete a task # noqa: E501 - - A specific, existing task can be deleted by making a DELETE request on the URL for that task. Deleted tasks go into the “trash” of the user making the delete request. Tasks can be recovered from the trash within a period of 30 days; afterward they are completely removed from the system. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_task_with_http_info(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['task_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `delete_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def duplicate_task(self, body, task_gid, **kwargs): # noqa: E501 - """Duplicate a task # noqa: E501 - - Creates and returns a job that will asynchronously handle the duplication. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.duplicate_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidDuplicateBody body: Describes the duplicate's name and the fields that will be duplicated. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: JobResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.duplicate_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.duplicate_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def duplicate_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Duplicate a task # noqa: E501 - - Creates and returns a job that will asynchronously handle the duplication. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.duplicate_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidDuplicateBody body: Describes the duplicate's name and the fields that will be duplicated. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: JobResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method duplicate_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `duplicate_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `duplicate_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/duplicate', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='JobResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_dependencies_for_task(self, task_gid, **kwargs): # noqa: E501 - """Get dependencies from a task # noqa: E501 - - Returns the compact representations of all of the dependencies of a task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_dependencies_for_task(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_dependencies_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_dependencies_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - return data - - def get_dependencies_for_task_with_http_info(self, task_gid, **kwargs): # noqa: E501 - """Get dependencies from a task # noqa: E501 - - Returns the compact representations of all of the dependencies of a task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_dependencies_for_task_with_http_info(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['task_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_dependencies_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `get_dependencies_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/dependencies', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_dependents_for_task(self, task_gid, **kwargs): # noqa: E501 - """Get dependents from a task # noqa: E501 - - Returns the compact representations of all of the dependents of a task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_dependents_for_task(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_dependents_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_dependents_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - return data - - def get_dependents_for_task_with_http_info(self, task_gid, **kwargs): # noqa: E501 - """Get dependents from a task # noqa: E501 - - Returns the compact representations of all of the dependents of a task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_dependents_for_task_with_http_info(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['task_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_dependents_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `get_dependents_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/dependents', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_subtasks_for_task(self, task_gid, **kwargs): # noqa: E501 - """Get subtasks from a task # noqa: E501 - - Returns a compact representation of all of the subtasks of a task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_subtasks_for_task(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_subtasks_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_subtasks_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - return data - - def get_subtasks_for_task_with_http_info(self, task_gid, **kwargs): # noqa: E501 - """Get subtasks from a task # noqa: E501 - - Returns a compact representation of all of the subtasks of a task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_subtasks_for_task_with_http_info(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['task_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_subtasks_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `get_subtasks_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/subtasks', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_task(self, task_gid, **kwargs): # noqa: E501 - """Get a task # noqa: E501 - - Returns the complete task record for a single task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_task(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_task_with_http_info(task_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_task_with_http_info(task_gid, **kwargs) # noqa: E501 - return data - - def get_task_with_http_info(self, task_gid, **kwargs): # noqa: E501 - """Get a task # noqa: E501 - - Returns the complete task record for a single task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_task_with_http_info(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['task_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `get_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_tasks(self, **kwargs): # noqa: E501 - """Get multiple tasks # noqa: E501 - - Returns the compact task records for some filtered set of tasks. Use one or more of the parameters provided to filter the tasks returned. You must specify a `project` or `tag` if you do not specify `assignee` and `workspace`. For more complex task retrieval, use [workspaces/{workspace_gid}/tasks/search](/reference/searchtasksforworkspace). # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tasks(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str assignee: The assignee to filter tasks on. If searching for unassigned tasks, assignee.any = null can be specified. *Note: If you specify `assignee`, you must also specify the `workspace` to filter on.* - :param str project: The project to filter tasks on. - :param str section: The section to filter tasks on. - :param str workspace: The workspace to filter tasks on. *Note: If you specify `workspace`, you must also specify the `assignee` to filter on.* - :param datetime completed_since: Only return tasks that are either incomplete or that have been completed since this time. - :param datetime modified_since: Only return tasks that have been modified since the given time. *Note: A task is considered “modified” if any of its properties change, or associations between it and other objects are modified (e.g. a task being added to a project). A task is not considered modified just because another object it is associated with (e.g. a subtask) is modified. Actions that count as modifying the task include assigning, renaming, completing, and adding stories.* - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_tasks_with_http_info(**kwargs) # noqa: E501 - else: - (data) = self.get_tasks_with_http_info(**kwargs) # noqa: E501 - return data - - def get_tasks_with_http_info(self, **kwargs): # noqa: E501 - """Get multiple tasks # noqa: E501 - - Returns the compact task records for some filtered set of tasks. Use one or more of the parameters provided to filter the tasks returned. You must specify a `project` or `tag` if you do not specify `assignee` and `workspace`. For more complex task retrieval, use [workspaces/{workspace_gid}/tasks/search](/reference/searchtasksforworkspace). # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tasks_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str assignee: The assignee to filter tasks on. If searching for unassigned tasks, assignee.any = null can be specified. *Note: If you specify `assignee`, you must also specify the `workspace` to filter on.* - :param str project: The project to filter tasks on. - :param str section: The section to filter tasks on. - :param str workspace: The workspace to filter tasks on. *Note: If you specify `workspace`, you must also specify the `assignee` to filter on.* - :param datetime completed_since: Only return tasks that are either incomplete or that have been completed since this time. - :param datetime modified_since: Only return tasks that have been modified since the given time. *Note: A task is considered “modified” if any of its properties change, or associations between it and other objects are modified (e.g. a task being added to a project). A task is not considered modified just because another object it is associated with (e.g. a subtask) is modified. Actions that count as modifying the task include assigning, renaming, completing, and adding stories.* - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['limit', 'offset', 'assignee', 'project', 'section', 'workspace', 'completed_since', 'modified_since', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_tasks" % key - ) - params[key] = val - del params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'assignee' in params: - query_params.append(('assignee', params['assignee'])) # noqa: E501 - if 'project' in params: - query_params.append(('project', params['project'])) # noqa: E501 - if 'section' in params: - query_params.append(('section', params['section'])) # noqa: E501 - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'completed_since' in params: - query_params.append(('completed_since', params['completed_since'])) # noqa: E501 - if 'modified_since' in params: - query_params.append(('modified_since', params['modified_since'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_tasks_for_project(self, project_gid, **kwargs): # noqa: E501 - """Get tasks from a project # noqa: E501 - - Returns the compact task records for all tasks within the given project, ordered by their priority within the project. Tasks can exist in more than one project at a time. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tasks_for_project(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param str completed_since: Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_tasks_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_tasks_for_project_with_http_info(project_gid, **kwargs) # noqa: E501 - return data - - def get_tasks_for_project_with_http_info(self, project_gid, **kwargs): # noqa: E501 - """Get tasks from a project # noqa: E501 - - Returns the compact task records for all tasks within the given project, ordered by their priority within the project. Tasks can exist in more than one project at a time. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tasks_for_project_with_http_info(project_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str project_gid: Globally unique identifier for the project. (required) - :param str completed_since: Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['project_gid', 'completed_since', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_tasks_for_project" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'project_gid' is set - if ('project_gid' not in params or - params['project_gid'] is None): - raise ValueError("Missing the required parameter `project_gid` when calling `get_tasks_for_project`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'project_gid' in params: - path_params['project_gid'] = params['project_gid'] # noqa: E501 - - query_params = [] - if 'completed_since' in params: - query_params.append(('completed_since', params['completed_since'])) # noqa: E501 - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/projects/{project_gid}/tasks', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_tasks_for_section(self, section_gid, **kwargs): # noqa: E501 - """Get tasks from a section # noqa: E501 - - *Board view only*: Returns the compact section records for all tasks within the given section. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tasks_for_section(section_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str section_gid: The globally unique identifier for the section. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str completed_since: Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_tasks_for_section_with_http_info(section_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_tasks_for_section_with_http_info(section_gid, **kwargs) # noqa: E501 - return data - - def get_tasks_for_section_with_http_info(self, section_gid, **kwargs): # noqa: E501 - """Get tasks from a section # noqa: E501 - - *Board view only*: Returns the compact section records for all tasks within the given section. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tasks_for_section_with_http_info(section_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str section_gid: The globally unique identifier for the section. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str completed_since: Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['section_gid', 'limit', 'offset', 'completed_since', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_tasks_for_section" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'section_gid' is set - if ('section_gid' not in params or - params['section_gid'] is None): - raise ValueError("Missing the required parameter `section_gid` when calling `get_tasks_for_section`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'section_gid' in params: - path_params['section_gid'] = params['section_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'completed_since' in params: - query_params.append(('completed_since', params['completed_since'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/sections/{section_gid}/tasks', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_tasks_for_tag(self, tag_gid, **kwargs): # noqa: E501 - """Get tasks from a tag # noqa: E501 - - Returns the compact task records for all tasks with the given tag. Tasks can have more than one tag at a time. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tasks_for_tag(tag_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str tag_gid: Globally unique identifier for the tag. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_tasks_for_tag_with_http_info(tag_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_tasks_for_tag_with_http_info(tag_gid, **kwargs) # noqa: E501 - return data - - def get_tasks_for_tag_with_http_info(self, tag_gid, **kwargs): # noqa: E501 - """Get tasks from a tag # noqa: E501 - - Returns the compact task records for all tasks with the given tag. Tasks can have more than one tag at a time. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tasks_for_tag_with_http_info(tag_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str tag_gid: Globally unique identifier for the tag. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['tag_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_tasks_for_tag" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'tag_gid' is set - if ('tag_gid' not in params or - params['tag_gid'] is None): - raise ValueError("Missing the required parameter `tag_gid` when calling `get_tasks_for_tag`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'tag_gid' in params: - path_params['tag_gid'] = params['tag_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tags/{tag_gid}/tasks', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_tasks_for_user_task_list(self, user_task_list_gid, **kwargs): # noqa: E501 - """Get tasks from a user task list # noqa: E501 - - Returns the compact list of tasks in a user’s My Tasks list. *Note: Access control is enforced for this endpoint as with all Asana API endpoints, meaning a user’s private tasks will be filtered out if the API-authenticated user does not have access to them.* *Note: Both complete and incomplete tasks are returned by default unless they are filtered out (for example, setting `completed_since=now` will return only incomplete tasks, which is the default view for “My Tasks” in Asana.)* # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tasks_for_user_task_list(user_task_list_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_task_list_gid: Globally unique identifier for the user task list. (required) - :param str completed_since: Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_tasks_for_user_task_list_with_http_info(user_task_list_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_tasks_for_user_task_list_with_http_info(user_task_list_gid, **kwargs) # noqa: E501 - return data - - def get_tasks_for_user_task_list_with_http_info(self, user_task_list_gid, **kwargs): # noqa: E501 - """Get tasks from a user task list # noqa: E501 - - Returns the compact list of tasks in a user’s My Tasks list. *Note: Access control is enforced for this endpoint as with all Asana API endpoints, meaning a user’s private tasks will be filtered out if the API-authenticated user does not have access to them.* *Note: Both complete and incomplete tasks are returned by default unless they are filtered out (for example, setting `completed_since=now` will return only incomplete tasks, which is the default view for “My Tasks” in Asana.)* # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_tasks_for_user_task_list_with_http_info(user_task_list_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_task_list_gid: Globally unique identifier for the user task list. (required) - :param str completed_since: Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['user_task_list_gid', 'completed_since', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_tasks_for_user_task_list" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'user_task_list_gid' is set - if ('user_task_list_gid' not in params or - params['user_task_list_gid'] is None): - raise ValueError("Missing the required parameter `user_task_list_gid` when calling `get_tasks_for_user_task_list`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'user_task_list_gid' in params: - path_params['user_task_list_gid'] = params['user_task_list_gid'] # noqa: E501 - - query_params = [] - if 'completed_since' in params: - query_params.append(('completed_since', params['completed_since'])) # noqa: E501 - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/user_task_lists/{user_task_list_gid}/tasks', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_dependencies_for_task(self, body, task_gid, **kwargs): # noqa: E501 - """Unlink dependencies from a task # noqa: E501 - - Unlinks a set of dependencies from this task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_dependencies_for_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidRemoveDependenciesBody body: The list of tasks to unlink as dependencies. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_dependencies_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_dependencies_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def remove_dependencies_for_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Unlink dependencies from a task # noqa: E501 - - Unlinks a set of dependencies from this task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_dependencies_for_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidRemoveDependenciesBody body: The list of tasks to unlink as dependencies. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_dependencies_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_dependencies_for_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `remove_dependencies_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/removeDependencies', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_dependents_for_task(self, body, task_gid, **kwargs): # noqa: E501 - """Unlink dependents from a task # noqa: E501 - - Unlinks a set of dependents from this task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_dependents_for_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidRemoveDependentsBody body: The list of tasks to remove as dependents. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_dependents_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_dependents_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def remove_dependents_for_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Unlink dependents from a task # noqa: E501 - - Unlinks a set of dependents from this task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_dependents_for_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidRemoveDependentsBody body: The list of tasks to remove as dependents. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_dependents_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_dependents_for_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `remove_dependents_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/removeDependents', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_follower_for_task(self, body, task_gid, **kwargs): # noqa: E501 - """Remove followers from a task # noqa: E501 - - Removes each of the specified followers from the task if they are following. Returns the complete, updated record for the affected task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_follower_for_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidRemoveFollowersBody body: The followers to remove from the task. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_follower_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_follower_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def remove_follower_for_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Remove followers from a task # noqa: E501 - - Removes each of the specified followers from the task if they are following. Returns the complete, updated record for the affected task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_follower_for_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidRemoveFollowersBody body: The followers to remove from the task. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_follower_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_follower_for_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `remove_follower_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/removeFollowers', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_project_for_task(self, body, task_gid, **kwargs): # noqa: E501 - """Remove a project from a task # noqa: E501 - - Removes the task from the specified project. The task will still exist in the system, but it will not be in the project anymore. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_project_for_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidRemoveProjectBody body: The project to remove the task from. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_project_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_project_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def remove_project_for_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Remove a project from a task # noqa: E501 - - Removes the task from the specified project. The task will still exist in the system, but it will not be in the project anymore. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_project_for_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidRemoveProjectBody body: The project to remove the task from. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_project_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_project_for_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `remove_project_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/removeProject', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_tag_for_task(self, body, task_gid, **kwargs): # noqa: E501 - """Remove a tag from a task # noqa: E501 - - Removes a tag from a task. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_tag_for_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidRemoveTagBody body: The tag to remove from the task. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_tag_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_tag_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def remove_tag_for_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Remove a tag from a task # noqa: E501 - - Removes a tag from a task. Returns an empty data block. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_tag_for_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidRemoveTagBody body: The tag to remove from the task. (required) - :param str task_gid: The task to operate on. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_tag_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_tag_for_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `remove_tag_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/removeTag', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def search_tasks_for_workspace(self, workspace_gid, **kwargs): # noqa: E501 - """Search tasks in a workspace # noqa: E501 - - To mirror the functionality of the Asana web app's advanced search feature, the Asana API has a task search endpoint that allows you to build complex filters to find and retrieve the exact data you need. #### Premium access Like the Asana web product's advance search feature, this search endpoint will only be available to premium Asana users. A user is premium if any of the following is true: - The workspace in which the search is being performed is a premium workspace - The user is a member of a premium team inside the workspace Even if a user is only a member of a premium team inside a non-premium workspace, search will allow them to find data anywhere in the workspace, not just inside the premium team. Making a search request using credentials of a non-premium user will result in a `402 Payment Required` error. #### Pagination Search results are not stable; repeating the same query multiple times may return the data in a different order, even if the data do not change. Because of this, the traditional [pagination](https://developers.asana.com/docs/#pagination) available elsewhere in the Asana API is not available here. However, you can paginate manually by sorting the search results by their creation time and then modifying each subsequent query to exclude data you have already seen. Page sizes are limited to a maximum of 100 items, and can be specified by the `limit` query parameter. #### Eventual consistency Changes in Asana (regardless of whether they’re made though the web product or the API) are forwarded to our search infrastructure to be indexed. This process can take between 10 and 60 seconds to complete under normal operation, and longer during some production incidents. Making a change to a task that would alter its presence in a particular search query will not be reflected immediately. This is also true of the advanced search feature in the web product. #### Rate limits You may receive a `429 Too Many Requests` response if you hit any of our [rate limits](https://developers.asana.com/docs/#rate-limits). #### Custom field parameters | Parameter name | Custom field type | Accepted type | |---|---|---| | custom_fields.{gid}.is_set | All | Boolean | | custom_fields.{gid}.value | Text | String | | custom_fields.{gid}.value | Number | Number | | custom_fields.{gid}.value | Enum | Enum option ID | | custom_fields.{gid}.starts_with | Text only | String | | custom_fields.{gid}.ends_with | Text only | String | | custom_fields.{gid}.contains | Text only | String | | custom_fields.{gid}.less_than | Number only | Number | | custom_fields.{gid}.greater_than | Number only | Number | For example, if the gid of the custom field is 12345, these query parameter to find tasks where it is set would be `custom_fields.12345.is_set=true`. To match an exact value for an enum custom field, use the gid of the desired enum option and not the name of the enum option: `custom_fields.12345.value=67890`. **Not Supported**: searching for multiple exact matches of a custom field, searching for multi-enum custom field *Note: If you specify `projects.any` and `sections.any`, you will receive tasks for the project **and** tasks for the section. If you're looking for only tasks in a section, omit the `projects.any` from the request.* # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.search_tasks_for_workspace(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param str text: Performs full-text search on both task name and description - :param str resource_subtype: Filters results by the task's resource_subtype - :param str assignee_any: Comma-separated list of user identifiers - :param str assignee_not: Comma-separated list of user identifiers - :param str portfolios_any: Comma-separated list of portfolio IDs - :param str projects_any: Comma-separated list of project IDs - :param str projects_not: Comma-separated list of project IDs - :param str projects_all: Comma-separated list of project IDs - :param str sections_any: Comma-separated list of section or column IDs - :param str sections_not: Comma-separated list of section or column IDs - :param str sections_all: Comma-separated list of section or column IDs - :param str tags_any: Comma-separated list of tag IDs - :param str tags_not: Comma-separated list of tag IDs - :param str tags_all: Comma-separated list of tag IDs - :param str teams_any: Comma-separated list of team IDs - :param str followers_not: Comma-separated list of user identifiers - :param str created_by_any: Comma-separated list of user identifiers - :param str created_by_not: Comma-separated list of user identifiers - :param str assigned_by_any: Comma-separated list of user identifiers - :param str assigned_by_not: Comma-separated list of user identifiers - :param str liked_by_not: Comma-separated list of user identifiers - :param str commented_on_by_not: Comma-separated list of user identifiers - :param date due_on_before: ISO 8601 date string - :param date due_on_after: ISO 8601 date string - :param date due_on: ISO 8601 date string or `null` - :param datetime due_at_before: ISO 8601 datetime string - :param datetime due_at_after: ISO 8601 datetime string - :param date start_on_before: ISO 8601 date string - :param date start_on_after: ISO 8601 date string - :param date start_on: ISO 8601 date string or `null` - :param date created_on_before: ISO 8601 date string - :param date created_on_after: ISO 8601 date string - :param date created_on: ISO 8601 date string or `null` - :param datetime created_at_before: ISO 8601 datetime string - :param datetime created_at_after: ISO 8601 datetime string - :param date completed_on_before: ISO 8601 date string - :param date completed_on_after: ISO 8601 date string - :param date completed_on: ISO 8601 date string or `null` - :param datetime completed_at_before: ISO 8601 datetime string - :param datetime completed_at_after: ISO 8601 datetime string - :param date modified_on_before: ISO 8601 date string - :param date modified_on_after: ISO 8601 date string - :param date modified_on: ISO 8601 date string or `null` - :param datetime modified_at_before: ISO 8601 datetime string - :param datetime modified_at_after: ISO 8601 datetime string - :param bool is_blocking: Filter to incomplete tasks with dependents - :param bool is_blocked: Filter to tasks with incomplete dependencies - :param bool has_attachment: Filter to tasks with attachments - :param bool completed: Filter to completed tasks - :param bool is_subtask: Filter to subtasks - :param str sort_by: One of `due_date`, `created_at`, `completed_at`, `likes`, or `modified_at`, defaults to `modified_at` - :param bool sort_ascending: Default `false` - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.search_tasks_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.search_tasks_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - return data - - def search_tasks_for_workspace_with_http_info(self, workspace_gid, **kwargs): # noqa: E501 - """Search tasks in a workspace # noqa: E501 - - To mirror the functionality of the Asana web app's advanced search feature, the Asana API has a task search endpoint that allows you to build complex filters to find and retrieve the exact data you need. #### Premium access Like the Asana web product's advance search feature, this search endpoint will only be available to premium Asana users. A user is premium if any of the following is true: - The workspace in which the search is being performed is a premium workspace - The user is a member of a premium team inside the workspace Even if a user is only a member of a premium team inside a non-premium workspace, search will allow them to find data anywhere in the workspace, not just inside the premium team. Making a search request using credentials of a non-premium user will result in a `402 Payment Required` error. #### Pagination Search results are not stable; repeating the same query multiple times may return the data in a different order, even if the data do not change. Because of this, the traditional [pagination](https://developers.asana.com/docs/#pagination) available elsewhere in the Asana API is not available here. However, you can paginate manually by sorting the search results by their creation time and then modifying each subsequent query to exclude data you have already seen. Page sizes are limited to a maximum of 100 items, and can be specified by the `limit` query parameter. #### Eventual consistency Changes in Asana (regardless of whether they’re made though the web product or the API) are forwarded to our search infrastructure to be indexed. This process can take between 10 and 60 seconds to complete under normal operation, and longer during some production incidents. Making a change to a task that would alter its presence in a particular search query will not be reflected immediately. This is also true of the advanced search feature in the web product. #### Rate limits You may receive a `429 Too Many Requests` response if you hit any of our [rate limits](https://developers.asana.com/docs/#rate-limits). #### Custom field parameters | Parameter name | Custom field type | Accepted type | |---|---|---| | custom_fields.{gid}.is_set | All | Boolean | | custom_fields.{gid}.value | Text | String | | custom_fields.{gid}.value | Number | Number | | custom_fields.{gid}.value | Enum | Enum option ID | | custom_fields.{gid}.starts_with | Text only | String | | custom_fields.{gid}.ends_with | Text only | String | | custom_fields.{gid}.contains | Text only | String | | custom_fields.{gid}.less_than | Number only | Number | | custom_fields.{gid}.greater_than | Number only | Number | For example, if the gid of the custom field is 12345, these query parameter to find tasks where it is set would be `custom_fields.12345.is_set=true`. To match an exact value for an enum custom field, use the gid of the desired enum option and not the name of the enum option: `custom_fields.12345.value=67890`. **Not Supported**: searching for multiple exact matches of a custom field, searching for multi-enum custom field *Note: If you specify `projects.any` and `sections.any`, you will receive tasks for the project **and** tasks for the section. If you're looking for only tasks in a section, omit the `projects.any` from the request.* # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.search_tasks_for_workspace_with_http_info(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param str text: Performs full-text search on both task name and description - :param str resource_subtype: Filters results by the task's resource_subtype - :param str assignee_any: Comma-separated list of user identifiers - :param str assignee_not: Comma-separated list of user identifiers - :param str portfolios_any: Comma-separated list of portfolio IDs - :param str projects_any: Comma-separated list of project IDs - :param str projects_not: Comma-separated list of project IDs - :param str projects_all: Comma-separated list of project IDs - :param str sections_any: Comma-separated list of section or column IDs - :param str sections_not: Comma-separated list of section or column IDs - :param str sections_all: Comma-separated list of section or column IDs - :param str tags_any: Comma-separated list of tag IDs - :param str tags_not: Comma-separated list of tag IDs - :param str tags_all: Comma-separated list of tag IDs - :param str teams_any: Comma-separated list of team IDs - :param str followers_not: Comma-separated list of user identifiers - :param str created_by_any: Comma-separated list of user identifiers - :param str created_by_not: Comma-separated list of user identifiers - :param str assigned_by_any: Comma-separated list of user identifiers - :param str assigned_by_not: Comma-separated list of user identifiers - :param str liked_by_not: Comma-separated list of user identifiers - :param str commented_on_by_not: Comma-separated list of user identifiers - :param date due_on_before: ISO 8601 date string - :param date due_on_after: ISO 8601 date string - :param date due_on: ISO 8601 date string or `null` - :param datetime due_at_before: ISO 8601 datetime string - :param datetime due_at_after: ISO 8601 datetime string - :param date start_on_before: ISO 8601 date string - :param date start_on_after: ISO 8601 date string - :param date start_on: ISO 8601 date string or `null` - :param date created_on_before: ISO 8601 date string - :param date created_on_after: ISO 8601 date string - :param date created_on: ISO 8601 date string or `null` - :param datetime created_at_before: ISO 8601 datetime string - :param datetime created_at_after: ISO 8601 datetime string - :param date completed_on_before: ISO 8601 date string - :param date completed_on_after: ISO 8601 date string - :param date completed_on: ISO 8601 date string or `null` - :param datetime completed_at_before: ISO 8601 datetime string - :param datetime completed_at_after: ISO 8601 datetime string - :param date modified_on_before: ISO 8601 date string - :param date modified_on_after: ISO 8601 date string - :param date modified_on: ISO 8601 date string or `null` - :param datetime modified_at_before: ISO 8601 datetime string - :param datetime modified_at_after: ISO 8601 datetime string - :param bool is_blocking: Filter to incomplete tasks with dependents - :param bool is_blocked: Filter to tasks with incomplete dependencies - :param bool has_attachment: Filter to tasks with attachments - :param bool completed: Filter to completed tasks - :param bool is_subtask: Filter to subtasks - :param str sort_by: One of `due_date`, `created_at`, `completed_at`, `likes`, or `modified_at`, defaults to `modified_at` - :param bool sort_ascending: Default `false` - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace_gid', 'text', 'resource_subtype', 'assignee_any', 'assignee_not', 'portfolios_any', 'projects_any', 'projects_not', 'projects_all', 'sections_any', 'sections_not', 'sections_all', 'tags_any', 'tags_not', 'tags_all', 'teams_any', 'followers_not', 'created_by_any', 'created_by_not', 'assigned_by_any', 'assigned_by_not', 'liked_by_not', 'commented_on_by_not', 'due_on_before', 'due_on_after', 'due_on', 'due_at_before', 'due_at_after', 'start_on_before', 'start_on_after', 'start_on', 'created_on_before', 'created_on_after', 'created_on', 'created_at_before', 'created_at_after', 'completed_on_before', 'completed_on_after', 'completed_on', 'completed_at_before', 'completed_at_after', 'modified_on_before', 'modified_on_after', 'modified_on', 'modified_at_before', 'modified_at_after', 'is_blocking', 'is_blocked', 'has_attachment', 'completed', 'is_subtask', 'sort_by', 'sort_ascending', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - matchSnakeCase = '^custom_fields_(.*?)_.*$' - custom_fields_query_param_keys = [] - for key, val in six.iteritems(params['kwargs']): - # Do not throw an error if the user provides custom field query parameters - if (re.match(matchSnakeCase, key)): - custom_field_gid = re.search(matchSnakeCase, key).group(1) - custom_field_query_param_key = key.replace(f'custom_fields_{custom_field_gid}_', f'custom_fields.{custom_field_gid}.') - params[custom_field_query_param_key] = val - custom_fields_query_param_keys.append(custom_field_query_param_key) - continue - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method search_tasks_for_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `search_tasks_for_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'text' in params: - query_params.append(('text', params['text'])) # noqa: E501 - if 'resource_subtype' in params: - query_params.append(('resource_subtype', params['resource_subtype'])) # noqa: E501 - if 'assignee_any' in params: - query_params.append(('assignee.any', params['assignee_any'])) # noqa: E501 - if 'assignee_not' in params: - query_params.append(('assignee.not', params['assignee_not'])) # noqa: E501 - if 'portfolios_any' in params: - query_params.append(('portfolios.any', params['portfolios_any'])) # noqa: E501 - if 'projects_any' in params: - query_params.append(('projects.any', params['projects_any'])) # noqa: E501 - if 'projects_not' in params: - query_params.append(('projects.not', params['projects_not'])) # noqa: E501 - if 'projects_all' in params: - query_params.append(('projects.all', params['projects_all'])) # noqa: E501 - if 'sections_any' in params: - query_params.append(('sections.any', params['sections_any'])) # noqa: E501 - if 'sections_not' in params: - query_params.append(('sections.not', params['sections_not'])) # noqa: E501 - if 'sections_all' in params: - query_params.append(('sections.all', params['sections_all'])) # noqa: E501 - if 'tags_any' in params: - query_params.append(('tags.any', params['tags_any'])) # noqa: E501 - if 'tags_not' in params: - query_params.append(('tags.not', params['tags_not'])) # noqa: E501 - if 'tags_all' in params: - query_params.append(('tags.all', params['tags_all'])) # noqa: E501 - if 'teams_any' in params: - query_params.append(('teams.any', params['teams_any'])) # noqa: E501 - if 'followers_not' in params: - query_params.append(('followers.not', params['followers_not'])) # noqa: E501 - if 'created_by_any' in params: - query_params.append(('created_by.any', params['created_by_any'])) # noqa: E501 - if 'created_by_not' in params: - query_params.append(('created_by.not', params['created_by_not'])) # noqa: E501 - if 'assigned_by_any' in params: - query_params.append(('assigned_by.any', params['assigned_by_any'])) # noqa: E501 - if 'assigned_by_not' in params: - query_params.append(('assigned_by.not', params['assigned_by_not'])) # noqa: E501 - if 'liked_by_not' in params: - query_params.append(('liked_by.not', params['liked_by_not'])) # noqa: E501 - if 'commented_on_by_not' in params: - query_params.append(('commented_on_by.not', params['commented_on_by_not'])) # noqa: E501 - if 'due_on_before' in params: - query_params.append(('due_on.before', params['due_on_before'])) # noqa: E501 - if 'due_on_after' in params: - query_params.append(('due_on.after', params['due_on_after'])) # noqa: E501 - if 'due_on' in params: - query_params.append(('due_on', params['due_on'])) # noqa: E501 - if 'due_at_before' in params: - query_params.append(('due_at.before', params['due_at_before'])) # noqa: E501 - if 'due_at_after' in params: - query_params.append(('due_at.after', params['due_at_after'])) # noqa: E501 - if 'start_on_before' in params: - query_params.append(('start_on.before', params['start_on_before'])) # noqa: E501 - if 'start_on_after' in params: - query_params.append(('start_on.after', params['start_on_after'])) # noqa: E501 - if 'start_on' in params: - query_params.append(('start_on', params['start_on'])) # noqa: E501 - if 'created_on_before' in params: - query_params.append(('created_on.before', params['created_on_before'])) # noqa: E501 - if 'created_on_after' in params: - query_params.append(('created_on.after', params['created_on_after'])) # noqa: E501 - if 'created_on' in params: - query_params.append(('created_on', params['created_on'])) # noqa: E501 - if 'created_at_before' in params: - query_params.append(('created_at.before', params['created_at_before'])) # noqa: E501 - if 'created_at_after' in params: - query_params.append(('created_at.after', params['created_at_after'])) # noqa: E501 - if 'completed_on_before' in params: - query_params.append(('completed_on.before', params['completed_on_before'])) # noqa: E501 - if 'completed_on_after' in params: - query_params.append(('completed_on.after', params['completed_on_after'])) # noqa: E501 - if 'completed_on' in params: - query_params.append(('completed_on', params['completed_on'])) # noqa: E501 - if 'completed_at_before' in params: - query_params.append(('completed_at.before', params['completed_at_before'])) # noqa: E501 - if 'completed_at_after' in params: - query_params.append(('completed_at.after', params['completed_at_after'])) # noqa: E501 - if 'modified_on_before' in params: - query_params.append(('modified_on.before', params['modified_on_before'])) # noqa: E501 - if 'modified_on_after' in params: - query_params.append(('modified_on.after', params['modified_on_after'])) # noqa: E501 - if 'modified_on' in params: - query_params.append(('modified_on', params['modified_on'])) # noqa: E501 - if 'modified_at_before' in params: - query_params.append(('modified_at.before', params['modified_at_before'])) # noqa: E501 - if 'modified_at_after' in params: - query_params.append(('modified_at.after', params['modified_at_after'])) # noqa: E501 - if 'is_blocking' in params: - query_params.append(('is_blocking', params['is_blocking'])) # noqa: E501 - if 'is_blocked' in params: - query_params.append(('is_blocked', params['is_blocked'])) # noqa: E501 - if 'has_attachment' in params: - query_params.append(('has_attachment', params['has_attachment'])) # noqa: E501 - if 'completed' in params: - query_params.append(('completed', params['completed'])) # noqa: E501 - if 'is_subtask' in params: - query_params.append(('is_subtask', params['is_subtask'])) # noqa: E501 - if 'sort_by' in params: - query_params.append(('sort_by', params['sort_by'])) # noqa: E501 - if 'sort_ascending' in params: - query_params.append(('sort_ascending', params['sort_ascending'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - # Checks if the user provided custom field query parameters and adds it to the request - for key in custom_fields_query_param_keys: - query_params.append((key, params[key])) # noqa: E501 - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}/tasks/search', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def set_parent_for_task(self, body, task_gid, **kwargs): # noqa: E501 - """Set the parent of a task # noqa: E501 - - parent, or no parent task at all. Returns an empty data block. When using `insert_before` and `insert_after`, at most one of those two options can be specified, and they must already be subtasks of the parent. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.set_parent_for_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidSetParentBody body: The new parent of the subtask. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.set_parent_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.set_parent_for_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def set_parent_for_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Set the parent of a task # noqa: E501 - - parent, or no parent task at all. Returns an empty data block. When using `insert_before` and `insert_after`, at most one of those two options can be specified, and they must already be subtasks of the parent. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.set_parent_for_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidSetParentBody body: The new parent of the subtask. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method set_parent_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `set_parent_for_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `set_parent_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/setParent', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_task(self, body, task_gid, **kwargs): # noqa: E501 - """Update a task # noqa: E501 - - A specific, existing task can be updated by making a PUT request on the URL for that task. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the task. Returns the complete updated task record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_task(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TasksTaskGidBody body: The task to update. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_task_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def update_task_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Update a task # noqa: E501 - - A specific, existing task can be updated by making a PUT request on the URL for that task. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the task. Returns the complete updated task record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_task_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TasksTaskGidBody body: The task to update. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TaskResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `update_task`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `update_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TaskResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/team_memberships_api.py b/asana/api/team_memberships_api.py deleted file mode 100644 index 073e3668..00000000 --- a/asana/api/team_memberships_api.py +++ /dev/null @@ -1,477 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class TeamMembershipsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def get_team_membership(self, team_membership_gid, **kwargs): # noqa: E501 - """Get a team membership # noqa: E501 - - Returns the complete team membership record for a single team membership. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_team_membership(team_membership_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str team_membership_gid: (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamMembershipResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_team_membership_with_http_info(team_membership_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_team_membership_with_http_info(team_membership_gid, **kwargs) # noqa: E501 - return data - - def get_team_membership_with_http_info(self, team_membership_gid, **kwargs): # noqa: E501 - """Get a team membership # noqa: E501 - - Returns the complete team membership record for a single team membership. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_team_membership_with_http_info(team_membership_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str team_membership_gid: (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamMembershipResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['team_membership_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_team_membership" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'team_membership_gid' is set - if ('team_membership_gid' not in params or - params['team_membership_gid'] is None): - raise ValueError("Missing the required parameter `team_membership_gid` when calling `get_team_membership`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'team_membership_gid' in params: - path_params['team_membership_gid'] = params['team_membership_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/team_memberships/{team_membership_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TeamMembershipResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_team_memberships(self, **kwargs): # noqa: E501 - """Get team memberships # noqa: E501 - - Returns compact team membership records. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_team_memberships(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str team: Globally unique identifier for the team. - :param str user: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. This parameter must be used with the workspace parameter. - :param str workspace: Globally unique identifier for the workspace. This parameter must be used with the user parameter. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_team_memberships_with_http_info(**kwargs) # noqa: E501 - else: - (data) = self.get_team_memberships_with_http_info(**kwargs) # noqa: E501 - return data - - def get_team_memberships_with_http_info(self, **kwargs): # noqa: E501 - """Get team memberships # noqa: E501 - - Returns compact team membership records. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_team_memberships_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str team: Globally unique identifier for the team. - :param str user: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. This parameter must be used with the workspace parameter. - :param str workspace: Globally unique identifier for the workspace. This parameter must be used with the user parameter. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['limit', 'offset', 'team', 'user', 'workspace', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_team_memberships" % key - ) - params[key] = val - del params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'team' in params: - query_params.append(('team', params['team'])) # noqa: E501 - if 'user' in params: - query_params.append(('user', params['user'])) # noqa: E501 - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/team_memberships', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TeamMembershipResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_team_memberships_for_team(self, team_gid, **kwargs): # noqa: E501 - """Get memberships from a team # noqa: E501 - - Returns the compact team memberships for the team. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_team_memberships_for_team(team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str team_gid: Globally unique identifier for the team. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_team_memberships_for_team_with_http_info(team_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_team_memberships_for_team_with_http_info(team_gid, **kwargs) # noqa: E501 - return data - - def get_team_memberships_for_team_with_http_info(self, team_gid, **kwargs): # noqa: E501 - """Get memberships from a team # noqa: E501 - - Returns the compact team memberships for the team. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_team_memberships_for_team_with_http_info(team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str team_gid: Globally unique identifier for the team. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['team_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_team_memberships_for_team" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'team_gid' is set - if ('team_gid' not in params or - params['team_gid'] is None): - raise ValueError("Missing the required parameter `team_gid` when calling `get_team_memberships_for_team`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'team_gid' in params: - path_params['team_gid'] = params['team_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/teams/{team_gid}/team_memberships', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TeamMembershipResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_team_memberships_for_user(self, user_gid, workspace, **kwargs): # noqa: E501 - """Get memberships from a user # noqa: E501 - - Returns the compact team membership records for the user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_team_memberships_for_user(user_gid, workspace, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_gid: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (required) - :param str workspace: Globally unique identifier for the workspace. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_team_memberships_for_user_with_http_info(user_gid, workspace, **kwargs) # noqa: E501 - else: - (data) = self.get_team_memberships_for_user_with_http_info(user_gid, workspace, **kwargs) # noqa: E501 - return data - - def get_team_memberships_for_user_with_http_info(self, user_gid, workspace, **kwargs): # noqa: E501 - """Get memberships from a user # noqa: E501 - - Returns the compact team membership records for the user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_team_memberships_for_user_with_http_info(user_gid, workspace, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_gid: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (required) - :param str workspace: Globally unique identifier for the workspace. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['user_gid', 'workspace', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_team_memberships_for_user" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'user_gid' is set - if ('user_gid' not in params or - params['user_gid'] is None): - raise ValueError("Missing the required parameter `user_gid` when calling `get_team_memberships_for_user`") # noqa: E501 - # verify the required parameter 'workspace' is set - if ('workspace' not in params or - params['workspace'] is None): - raise ValueError("Missing the required parameter `workspace` when calling `get_team_memberships_for_user`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'user_gid' in params: - path_params['user_gid'] = params['user_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/users/{user_gid}/team_memberships', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TeamMembershipResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/teams_api.py b/asana/api/teams_api.py deleted file mode 100644 index a4e32f12..00000000 --- a/asana/api/teams_api.py +++ /dev/null @@ -1,806 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class TeamsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def add_user_for_team(self, body, team_gid, **kwargs): # noqa: E501 - """Add a user to a team # noqa: E501 - - The user making this call must be a member of the team in order to add others. The user being added must exist in the same organization as the team. Returns the complete team membership record for the newly added user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_user_for_team(body, team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TeamGidAddUserBody body: The user to add to the team. (required) - :param str team_gid: Globally unique identifier for the team. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamMembershipResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_user_for_team_with_http_info(body, team_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_user_for_team_with_http_info(body, team_gid, **kwargs) # noqa: E501 - return data - - def add_user_for_team_with_http_info(self, body, team_gid, **kwargs): # noqa: E501 - """Add a user to a team # noqa: E501 - - The user making this call must be a member of the team in order to add others. The user being added must exist in the same organization as the team. Returns the complete team membership record for the newly added user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_user_for_team_with_http_info(body, team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TeamGidAddUserBody body: The user to add to the team. (required) - :param str team_gid: Globally unique identifier for the team. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamMembershipResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'team_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_user_for_team" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_user_for_team`") # noqa: E501 - # verify the required parameter 'team_gid' is set - if ('team_gid' not in params or - params['team_gid'] is None): - raise ValueError("Missing the required parameter `team_gid` when calling `add_user_for_team`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'team_gid' in params: - path_params['team_gid'] = params['team_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/teams/{team_gid}/addUser', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TeamMembershipResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_team(self, body, **kwargs): # noqa: E501 - """Create a team # noqa: E501 - - Creates a team within the current workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_team(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TeamsBody body: The team to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_team_with_http_info(body, **kwargs) # noqa: E501 - else: - (data) = self.create_team_with_http_info(body, **kwargs) # noqa: E501 - return data - - def create_team_with_http_info(self, body, **kwargs): # noqa: E501 - """Create a team # noqa: E501 - - Creates a team within the current workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_team_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TeamsBody body: The team to create. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_team" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_team`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/teams', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TeamResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_team(self, team_gid, **kwargs): # noqa: E501 - """Get a team # noqa: E501 - - Returns the full record for a single team. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_team(team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str team_gid: Globally unique identifier for the team. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_team_with_http_info(team_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_team_with_http_info(team_gid, **kwargs) # noqa: E501 - return data - - def get_team_with_http_info(self, team_gid, **kwargs): # noqa: E501 - """Get a team # noqa: E501 - - Returns the full record for a single team. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_team_with_http_info(team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str team_gid: Globally unique identifier for the team. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['team_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_team" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'team_gid' is set - if ('team_gid' not in params or - params['team_gid'] is None): - raise ValueError("Missing the required parameter `team_gid` when calling `get_team`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'team_gid' in params: - path_params['team_gid'] = params['team_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/teams/{team_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TeamResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_teams_for_user(self, user_gid, organization, **kwargs): # noqa: E501 - """Get teams for a user # noqa: E501 - - Returns the compact records for all teams to which the given user is assigned. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_teams_for_user(user_gid, organization, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_gid: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (required) - :param str organization: The workspace or organization to filter teams on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_teams_for_user_with_http_info(user_gid, organization, **kwargs) # noqa: E501 - else: - (data) = self.get_teams_for_user_with_http_info(user_gid, organization, **kwargs) # noqa: E501 - return data - - def get_teams_for_user_with_http_info(self, user_gid, organization, **kwargs): # noqa: E501 - """Get teams for a user # noqa: E501 - - Returns the compact records for all teams to which the given user is assigned. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_teams_for_user_with_http_info(user_gid, organization, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_gid: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (required) - :param str organization: The workspace or organization to filter teams on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['user_gid', 'organization', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_teams_for_user" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'user_gid' is set - if ('user_gid' not in params or - params['user_gid'] is None): - raise ValueError("Missing the required parameter `user_gid` when calling `get_teams_for_user`") # noqa: E501 - # verify the required parameter 'organization' is set - if ('organization' not in params or - params['organization'] is None): - raise ValueError("Missing the required parameter `organization` when calling `get_teams_for_user`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'user_gid' in params: - path_params['user_gid'] = params['user_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'organization' in params: - query_params.append(('organization', params['organization'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/users/{user_gid}/teams', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TeamResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_teams_for_workspace(self, workspace_gid, **kwargs): # noqa: E501 - """Get teams in a workspace # noqa: E501 - - Returns the compact records for all teams in the workspace visible to the authorized user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_teams_for_workspace(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_teams_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_teams_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - return data - - def get_teams_for_workspace_with_http_info(self, workspace_gid, **kwargs): # noqa: E501 - """Get teams in a workspace # noqa: E501 - - Returns the compact records for all teams in the workspace visible to the authorized user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_teams_for_workspace_with_http_info(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_teams_for_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `get_teams_for_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}/teams', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TeamResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_user_for_team(self, body, team_gid, **kwargs): # noqa: E501 - """Remove a user from a team # noqa: E501 - - The user making this call must be a member of the team in order to remove themselves or others. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_user_for_team(body, team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TeamGidRemoveUserBody body: The user to remove from the team. (required) - :param str team_gid: Globally unique identifier for the team. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_user_for_team_with_http_info(body, team_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_user_for_team_with_http_info(body, team_gid, **kwargs) # noqa: E501 - return data - - def remove_user_for_team_with_http_info(self, body, team_gid, **kwargs): # noqa: E501 - """Remove a user from a team # noqa: E501 - - The user making this call must be a member of the team in order to remove themselves or others. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_user_for_team_with_http_info(body, team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TeamGidRemoveUserBody body: The user to remove from the team. (required) - :param str team_gid: Globally unique identifier for the team. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'team_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_user_for_team" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_user_for_team`") # noqa: E501 - # verify the required parameter 'team_gid' is set - if ('team_gid' not in params or - params['team_gid'] is None): - raise ValueError("Missing the required parameter `team_gid` when calling `remove_user_for_team`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'team_gid' in params: - path_params['team_gid'] = params['team_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/teams/{team_gid}/removeUser', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_team(self, body, team_gid, **kwargs): # noqa: E501 - """Update a team # noqa: E501 - - Updates a team within the current workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_team(body, team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TeamsTeamGidBody body: The team to update. (required) - :param str team_gid: Globally unique identifier for the team. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_team_with_http_info(body, team_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_team_with_http_info(body, team_gid, **kwargs) # noqa: E501 - return data - - def update_team_with_http_info(self, body, team_gid, **kwargs): # noqa: E501 - """Update a team # noqa: E501 - - Updates a team within the current workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_team_with_http_info(body, team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TeamsTeamGidBody body: The team to update. (required) - :param str team_gid: Globally unique identifier for the team. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TeamResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'team_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_team" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `update_team`") # noqa: E501 - # verify the required parameter 'team_gid' is set - if ('team_gid' not in params or - params['team_gid'] is None): - raise ValueError("Missing the required parameter `team_gid` when calling `update_team`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'team_gid' in params: - path_params['team_gid'] = params['team_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/teams/{team_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TeamResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/time_periods_api.py b/asana/api/time_periods_api.py deleted file mode 100644 index 48b92f11..00000000 --- a/asana/api/time_periods_api.py +++ /dev/null @@ -1,253 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class TimePeriodsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def get_time_period(self, time_period_gid, **kwargs): # noqa: E501 - """Get a time period # noqa: E501 - - Returns the full record for a single time period. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_time_period(time_period_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str time_period_gid: Globally unique identifier for the time period. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TimePeriodResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_time_period_with_http_info(time_period_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_time_period_with_http_info(time_period_gid, **kwargs) # noqa: E501 - return data - - def get_time_period_with_http_info(self, time_period_gid, **kwargs): # noqa: E501 - """Get a time period # noqa: E501 - - Returns the full record for a single time period. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_time_period_with_http_info(time_period_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str time_period_gid: Globally unique identifier for the time period. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TimePeriodResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['time_period_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_time_period" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'time_period_gid' is set - if ('time_period_gid' not in params or - params['time_period_gid'] is None): - raise ValueError("Missing the required parameter `time_period_gid` when calling `get_time_period`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'time_period_gid' in params: - path_params['time_period_gid'] = params['time_period_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/time_periods/{time_period_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TimePeriodResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_time_periods(self, workspace, **kwargs): # noqa: E501 - """Get time periods # noqa: E501 - - Returns compact time period records. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_time_periods(workspace, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace: Globally unique identifier for the workspace. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param date start_on: ISO 8601 date string - :param date end_on: ISO 8601 date string - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TimePeriodResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_time_periods_with_http_info(workspace, **kwargs) # noqa: E501 - else: - (data) = self.get_time_periods_with_http_info(workspace, **kwargs) # noqa: E501 - return data - - def get_time_periods_with_http_info(self, workspace, **kwargs): # noqa: E501 - """Get time periods # noqa: E501 - - Returns compact time period records. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_time_periods_with_http_info(workspace, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace: Globally unique identifier for the workspace. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param date start_on: ISO 8601 date string - :param date end_on: ISO 8601 date string - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TimePeriodResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace', 'limit', 'offset', 'start_on', 'end_on', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_time_periods" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace' is set - if ('workspace' not in params or - params['workspace'] is None): - raise ValueError("Missing the required parameter `workspace` when calling `get_time_periods`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'start_on' in params: - query_params.append(('start_on', params['start_on'])) # noqa: E501 - if 'end_on' in params: - query_params.append(('end_on', params['end_on'])) # noqa: E501 - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/time_periods', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TimePeriodResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/time_tracking_entries_api.py b/asana/api/time_tracking_entries_api.py deleted file mode 100644 index e6362cfa..00000000 --- a/asana/api/time_tracking_entries_api.py +++ /dev/null @@ -1,570 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class TimeTrackingEntriesApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_time_tracking_entry(self, body, task_gid, **kwargs): # noqa: E501 - """Create a time tracking entry # noqa: E501 - - Creates a time tracking entry on a given task. Returns the record of the newly created time tracking entry. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_time_tracking_entry(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidTimeTrackingEntriesBody body: Information about the time tracking entry. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TimeTrackingEntryBaseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_time_tracking_entry_with_http_info(body, task_gid, **kwargs) # noqa: E501 - else: - (data) = self.create_time_tracking_entry_with_http_info(body, task_gid, **kwargs) # noqa: E501 - return data - - def create_time_tracking_entry_with_http_info(self, body, task_gid, **kwargs): # noqa: E501 - """Create a time tracking entry # noqa: E501 - - Creates a time tracking entry on a given task. Returns the record of the newly created time tracking entry. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_time_tracking_entry_with_http_info(body, task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TaskGidTimeTrackingEntriesBody body: Information about the time tracking entry. (required) - :param str task_gid: The task to operate on. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TimeTrackingEntryBaseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'task_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_time_tracking_entry" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_time_tracking_entry`") # noqa: E501 - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `create_time_tracking_entry`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/time_tracking_entries', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TimeTrackingEntryBaseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_time_tracking_entry(self, time_tracking_entry_gid, **kwargs): # noqa: E501 - """Delete a time tracking entry # noqa: E501 - - A specific, existing time tracking entry can be deleted by making a `DELETE` request on the URL for that time tracking entry. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_time_tracking_entry(time_tracking_entry_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str time_tracking_entry_gid: Globally unique identifier for the time tracking entry. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_time_tracking_entry_with_http_info(time_tracking_entry_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_time_tracking_entry_with_http_info(time_tracking_entry_gid, **kwargs) # noqa: E501 - return data - - def delete_time_tracking_entry_with_http_info(self, time_tracking_entry_gid, **kwargs): # noqa: E501 - """Delete a time tracking entry # noqa: E501 - - A specific, existing time tracking entry can be deleted by making a `DELETE` request on the URL for that time tracking entry. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_time_tracking_entry_with_http_info(time_tracking_entry_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str time_tracking_entry_gid: Globally unique identifier for the time tracking entry. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['time_tracking_entry_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_time_tracking_entry" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'time_tracking_entry_gid' is set - if ('time_tracking_entry_gid' not in params or - params['time_tracking_entry_gid'] is None): - raise ValueError("Missing the required parameter `time_tracking_entry_gid` when calling `delete_time_tracking_entry`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'time_tracking_entry_gid' in params: - path_params['time_tracking_entry_gid'] = params['time_tracking_entry_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/time_tracking_entries/{time_tracking_entry_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_time_tracking_entries_for_task(self, task_gid, **kwargs): # noqa: E501 - """Get time tracking entries for a task # noqa: E501 - - Returns time tracking entries for a given task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_time_tracking_entries_for_task(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TimeTrackingEntryCompactArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_time_tracking_entries_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_time_tracking_entries_for_task_with_http_info(task_gid, **kwargs) # noqa: E501 - return data - - def get_time_tracking_entries_for_task_with_http_info(self, task_gid, **kwargs): # noqa: E501 - """Get time tracking entries for a task # noqa: E501 - - Returns time tracking entries for a given task. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_time_tracking_entries_for_task_with_http_info(task_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str task_gid: The task to operate on. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TimeTrackingEntryCompactArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['task_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_time_tracking_entries_for_task" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'task_gid' is set - if ('task_gid' not in params or - params['task_gid'] is None): - raise ValueError("Missing the required parameter `task_gid` when calling `get_time_tracking_entries_for_task`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'task_gid' in params: - path_params['task_gid'] = params['task_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/tasks/{task_gid}/time_tracking_entries', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TimeTrackingEntryCompactArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_time_tracking_entry(self, time_tracking_entry_gid, **kwargs): # noqa: E501 - """Get a time tracking entry # noqa: E501 - - Returns the complete time tracking entry record for a single time tracking entry. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_time_tracking_entry(time_tracking_entry_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str time_tracking_entry_gid: Globally unique identifier for the time tracking entry. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TimeTrackingEntryBaseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_time_tracking_entry_with_http_info(time_tracking_entry_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_time_tracking_entry_with_http_info(time_tracking_entry_gid, **kwargs) # noqa: E501 - return data - - def get_time_tracking_entry_with_http_info(self, time_tracking_entry_gid, **kwargs): # noqa: E501 - """Get a time tracking entry # noqa: E501 - - Returns the complete time tracking entry record for a single time tracking entry. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_time_tracking_entry_with_http_info(time_tracking_entry_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str time_tracking_entry_gid: Globally unique identifier for the time tracking entry. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TimeTrackingEntryBaseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['time_tracking_entry_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_time_tracking_entry" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'time_tracking_entry_gid' is set - if ('time_tracking_entry_gid' not in params or - params['time_tracking_entry_gid'] is None): - raise ValueError("Missing the required parameter `time_tracking_entry_gid` when calling `get_time_tracking_entry`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'time_tracking_entry_gid' in params: - path_params['time_tracking_entry_gid'] = params['time_tracking_entry_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/time_tracking_entries/{time_tracking_entry_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TimeTrackingEntryBaseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_time_tracking_entry(self, body, time_tracking_entry_gid, **kwargs): # noqa: E501 - """Update a time tracking entry # noqa: E501 - - A specific, existing time tracking entry can be updated by making a `PUT` request on the URL for that time tracking entry. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the task. Returns the complete updated time tracking entry record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_time_tracking_entry(body, time_tracking_entry_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TimeTrackingEntriesTimeTrackingEntryGidBody body: The updated fields for the time tracking entry. (required) - :param str time_tracking_entry_gid: Globally unique identifier for the time tracking entry. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TimeTrackingEntryBaseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_time_tracking_entry_with_http_info(body, time_tracking_entry_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_time_tracking_entry_with_http_info(body, time_tracking_entry_gid, **kwargs) # noqa: E501 - return data - - def update_time_tracking_entry_with_http_info(self, body, time_tracking_entry_gid, **kwargs): # noqa: E501 - """Update a time tracking entry # noqa: E501 - - A specific, existing time tracking entry can be updated by making a `PUT` request on the URL for that time tracking entry. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the task. Returns the complete updated time tracking entry record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_time_tracking_entry_with_http_info(body, time_tracking_entry_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param TimeTrackingEntriesTimeTrackingEntryGidBody body: The updated fields for the time tracking entry. (required) - :param str time_tracking_entry_gid: Globally unique identifier for the time tracking entry. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: TimeTrackingEntryBaseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'time_tracking_entry_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_time_tracking_entry" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `update_time_tracking_entry`") # noqa: E501 - # verify the required parameter 'time_tracking_entry_gid' is set - if ('time_tracking_entry_gid' not in params or - params['time_tracking_entry_gid'] is None): - raise ValueError("Missing the required parameter `time_tracking_entry_gid` when calling `update_time_tracking_entry`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'time_tracking_entry_gid' in params: - path_params['time_tracking_entry_gid'] = params['time_tracking_entry_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/time_tracking_entries/{time_tracking_entry_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='TimeTrackingEntryBaseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/typeahead_api.py b/asana/api/typeahead_api.py deleted file mode 100644 index 6b937f13..00000000 --- a/asana/api/typeahead_api.py +++ /dev/null @@ -1,155 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class TypeaheadApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def typeahead_for_workspace(self, workspace_gid, resource_type, **kwargs): # noqa: E501 - """Get objects via typeahead # noqa: E501 - - Retrieves objects in the workspace based via an auto-completion/typeahead search algorithm. This feature is meant to provide results quickly, so do not rely on this API to provide extremely accurate search results. The result set is limited to a single page of results with a maximum size, so you won’t be able to fetch large numbers of results. The typeahead search API provides search for objects from a single workspace. This endpoint should be used to query for objects when creating an auto-completion/typeahead search feature. This API is meant to provide results quickly and should not be relied upon for accurate or exhaustive search results. The results sets are limited in size and cannot be paginated. Queries return a compact representation of each object which is typically the gid and name fields. Interested in a specific set of fields or all of the fields?! Of course you are. Use field selectors to manipulate what data is included in a response. Resources with type `user` are returned in order of most contacted to least contacted. This is determined by task assignments, adding the user to projects, and adding the user as a follower to tasks, messages, etc. Resources with type `project` are returned in order of recency. This is determined when the user visits the project, is added to the project, and completes tasks in the project. Resources with type `task` are returned with priority placed on tasks the user is following, but no guarantee on the order of those tasks. Resources with type `project_template` are returned with priority placed on favorited project templates. Leaving the `query` string empty or omitted will give you results, still following the resource ordering above. This could be used to list users or projects that are relevant for the requesting user's api token. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.typeahead_for_workspace(workspace_gid, resource_type, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param str resource_type: The type of values the typeahead should return. You can choose from one of the following: `custom_field`, `project`, `project_template`, `portfolio`, `tag`, `task`, and `user`. Note that unlike in the names of endpoints, the types listed here are in singular form (e.g. `task`). Using multiple types is not yet supported. (required) - :param str type: *Deprecated: new integrations should prefer the resource_type field.* - :param str query: The string that will be used to search for relevant objects. If an empty string is passed in, the API will return results. - :param int count: The number of results to return. The default is 20 if this parameter is omitted, with a minimum of 1 and a maximum of 100. If there are fewer results found than requested, all will be returned. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: AsanaNamedResourceArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.typeahead_for_workspace_with_http_info(workspace_gid, resource_type, **kwargs) # noqa: E501 - else: - (data) = self.typeahead_for_workspace_with_http_info(workspace_gid, resource_type, **kwargs) # noqa: E501 - return data - - def typeahead_for_workspace_with_http_info(self, workspace_gid, resource_type, **kwargs): # noqa: E501 - """Get objects via typeahead # noqa: E501 - - Retrieves objects in the workspace based via an auto-completion/typeahead search algorithm. This feature is meant to provide results quickly, so do not rely on this API to provide extremely accurate search results. The result set is limited to a single page of results with a maximum size, so you won’t be able to fetch large numbers of results. The typeahead search API provides search for objects from a single workspace. This endpoint should be used to query for objects when creating an auto-completion/typeahead search feature. This API is meant to provide results quickly and should not be relied upon for accurate or exhaustive search results. The results sets are limited in size and cannot be paginated. Queries return a compact representation of each object which is typically the gid and name fields. Interested in a specific set of fields or all of the fields?! Of course you are. Use field selectors to manipulate what data is included in a response. Resources with type `user` are returned in order of most contacted to least contacted. This is determined by task assignments, adding the user to projects, and adding the user as a follower to tasks, messages, etc. Resources with type `project` are returned in order of recency. This is determined when the user visits the project, is added to the project, and completes tasks in the project. Resources with type `task` are returned with priority placed on tasks the user is following, but no guarantee on the order of those tasks. Resources with type `project_template` are returned with priority placed on favorited project templates. Leaving the `query` string empty or omitted will give you results, still following the resource ordering above. This could be used to list users or projects that are relevant for the requesting user's api token. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.typeahead_for_workspace_with_http_info(workspace_gid, resource_type, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param str resource_type: The type of values the typeahead should return. You can choose from one of the following: `custom_field`, `project`, `project_template`, `portfolio`, `tag`, `task`, and `user`. Note that unlike in the names of endpoints, the types listed here are in singular form (e.g. `task`). Using multiple types is not yet supported. (required) - :param str type: *Deprecated: new integrations should prefer the resource_type field.* - :param str query: The string that will be used to search for relevant objects. If an empty string is passed in, the API will return results. - :param int count: The number of results to return. The default is 20 if this parameter is omitted, with a minimum of 1 and a maximum of 100. If there are fewer results found than requested, all will be returned. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: AsanaNamedResourceArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace_gid', 'resource_type', 'type', 'query', 'count', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method typeahead_for_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `typeahead_for_workspace`") # noqa: E501 - # verify the required parameter 'resource_type' is set - if ('resource_type' not in params or - params['resource_type'] is None): - raise ValueError("Missing the required parameter `resource_type` when calling `typeahead_for_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'resource_type' in params: - query_params.append(('resource_type', params['resource_type'])) # noqa: E501 - if 'type' in params: - query_params.append(('type', params['type'])) # noqa: E501 - if 'query' in params: - query_params.append(('query', params['query'])) # noqa: E501 - if 'count' in params: - query_params.append(('count', params['count'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}/typeahead', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='AsanaNamedResourceArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/user_task_lists_api.py b/asana/api/user_task_lists_api.py deleted file mode 100644 index 33ec1fe0..00000000 --- a/asana/api/user_task_lists_api.py +++ /dev/null @@ -1,245 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class UserTaskListsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def get_user_task_list(self, user_task_list_gid, **kwargs): # noqa: E501 - """Get a user task list # noqa: E501 - - Returns the full record for a user task list. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_user_task_list(user_task_list_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_task_list_gid: Globally unique identifier for the user task list. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserTaskListResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_user_task_list_with_http_info(user_task_list_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_user_task_list_with_http_info(user_task_list_gid, **kwargs) # noqa: E501 - return data - - def get_user_task_list_with_http_info(self, user_task_list_gid, **kwargs): # noqa: E501 - """Get a user task list # noqa: E501 - - Returns the full record for a user task list. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_user_task_list_with_http_info(user_task_list_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_task_list_gid: Globally unique identifier for the user task list. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserTaskListResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['user_task_list_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_user_task_list" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'user_task_list_gid' is set - if ('user_task_list_gid' not in params or - params['user_task_list_gid'] is None): - raise ValueError("Missing the required parameter `user_task_list_gid` when calling `get_user_task_list`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'user_task_list_gid' in params: - path_params['user_task_list_gid'] = params['user_task_list_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/user_task_lists/{user_task_list_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='UserTaskListResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_user_task_list_for_user(self, user_gid, workspace, **kwargs): # noqa: E501 - """Get a user's task list # noqa: E501 - - Returns the full record for a user's task list. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_user_task_list_for_user(user_gid, workspace, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_gid: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (required) - :param str workspace: The workspace in which to get the user task list. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserTaskListResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_user_task_list_for_user_with_http_info(user_gid, workspace, **kwargs) # noqa: E501 - else: - (data) = self.get_user_task_list_for_user_with_http_info(user_gid, workspace, **kwargs) # noqa: E501 - return data - - def get_user_task_list_for_user_with_http_info(self, user_gid, workspace, **kwargs): # noqa: E501 - """Get a user's task list # noqa: E501 - - Returns the full record for a user's task list. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_user_task_list_for_user_with_http_info(user_gid, workspace, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_gid: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (required) - :param str workspace: The workspace in which to get the user task list. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserTaskListResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['user_gid', 'workspace', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_user_task_list_for_user" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'user_gid' is set - if ('user_gid' not in params or - params['user_gid'] is None): - raise ValueError("Missing the required parameter `user_gid` when calling `get_user_task_list_for_user`") # noqa: E501 - # verify the required parameter 'workspace' is set - if ('workspace' not in params or - params['workspace'] is None): - raise ValueError("Missing the required parameter `workspace` when calling `get_user_task_list_for_user`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'user_gid' in params: - path_params['user_gid'] = params['user_gid'] # noqa: E501 - - query_params = [] - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/users/{user_gid}/user_task_list', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='UserTaskListResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/users_api.py b/asana/api/users_api.py deleted file mode 100644 index 7520715e..00000000 --- a/asana/api/users_api.py +++ /dev/null @@ -1,583 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class UsersApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def get_favorites_for_user(self, user_gid, resource_type, workspace, **kwargs): # noqa: E501 - """Get a user's favorites # noqa: E501 - - Returns all of a user's favorites in the given workspace, of the given type. Results are given in order (The same order as Asana's sidebar). # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_favorites_for_user(user_gid, resource_type, workspace, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_gid: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (required) - :param str resource_type: The resource type of favorites to be returned. (required) - :param str workspace: The workspace in which to get favorites. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: AsanaNamedResourceArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_favorites_for_user_with_http_info(user_gid, resource_type, workspace, **kwargs) # noqa: E501 - else: - (data) = self.get_favorites_for_user_with_http_info(user_gid, resource_type, workspace, **kwargs) # noqa: E501 - return data - - def get_favorites_for_user_with_http_info(self, user_gid, resource_type, workspace, **kwargs): # noqa: E501 - """Get a user's favorites # noqa: E501 - - Returns all of a user's favorites in the given workspace, of the given type. Results are given in order (The same order as Asana's sidebar). # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_favorites_for_user_with_http_info(user_gid, resource_type, workspace, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_gid: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (required) - :param str resource_type: The resource type of favorites to be returned. (required) - :param str workspace: The workspace in which to get favorites. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: AsanaNamedResourceArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['user_gid', 'resource_type', 'workspace', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_favorites_for_user" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'user_gid' is set - if ('user_gid' not in params or - params['user_gid'] is None): - raise ValueError("Missing the required parameter `user_gid` when calling `get_favorites_for_user`") # noqa: E501 - # verify the required parameter 'resource_type' is set - if ('resource_type' not in params or - params['resource_type'] is None): - raise ValueError("Missing the required parameter `resource_type` when calling `get_favorites_for_user`") # noqa: E501 - # verify the required parameter 'workspace' is set - if ('workspace' not in params or - params['workspace'] is None): - raise ValueError("Missing the required parameter `workspace` when calling `get_favorites_for_user`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'user_gid' in params: - path_params['user_gid'] = params['user_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'resource_type' in params: - query_params.append(('resource_type', params['resource_type'])) # noqa: E501 - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/users/{user_gid}/favorites', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='AsanaNamedResourceArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_user(self, user_gid, **kwargs): # noqa: E501 - """Get a user # noqa: E501 - - Returns the full user record for the single user with the provided ID. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_user(user_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_gid: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_user_with_http_info(user_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_user_with_http_info(user_gid, **kwargs) # noqa: E501 - return data - - def get_user_with_http_info(self, user_gid, **kwargs): # noqa: E501 - """Get a user # noqa: E501 - - Returns the full user record for the single user with the provided ID. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_user_with_http_info(user_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_gid: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['user_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_user" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'user_gid' is set - if ('user_gid' not in params or - params['user_gid'] is None): - raise ValueError("Missing the required parameter `user_gid` when calling `get_user`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'user_gid' in params: - path_params['user_gid'] = params['user_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/users/{user_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='UserResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_users(self, **kwargs): # noqa: E501 - """Get multiple users # noqa: E501 - - Returns the user records for all users in all workspaces and organizations accessible to the authenticated user. Accepts an optional workspace ID parameter. Results are sorted by user ID. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_users(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace: The workspace or organization ID to filter users on. - :param str team: The team ID to filter users on. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_users_with_http_info(**kwargs) # noqa: E501 - else: - (data) = self.get_users_with_http_info(**kwargs) # noqa: E501 - return data - - def get_users_with_http_info(self, **kwargs): # noqa: E501 - """Get multiple users # noqa: E501 - - Returns the user records for all users in all workspaces and organizations accessible to the authenticated user. Accepts an optional workspace ID parameter. Results are sorted by user ID. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_users_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace: The workspace or organization ID to filter users on. - :param str team: The team ID to filter users on. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace', 'team', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_users" % key - ) - params[key] = val - del params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'team' in params: - query_params.append(('team', params['team'])) # noqa: E501 - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/users', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='UserResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_users_for_team(self, team_gid, **kwargs): # noqa: E501 - """Get users in a team # noqa: E501 - - Returns the compact records for all users that are members of the team. Results are sorted alphabetically and limited to 2000. For more results use the `/users` endpoint. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_users_for_team(team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str team_gid: Globally unique identifier for the team. (required) - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_users_for_team_with_http_info(team_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_users_for_team_with_http_info(team_gid, **kwargs) # noqa: E501 - return data - - def get_users_for_team_with_http_info(self, team_gid, **kwargs): # noqa: E501 - """Get users in a team # noqa: E501 - - Returns the compact records for all users that are members of the team. Results are sorted alphabetically and limited to 2000. For more results use the `/users` endpoint. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_users_for_team_with_http_info(team_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str team_gid: Globally unique identifier for the team. (required) - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['team_gid', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_users_for_team" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'team_gid' is set - if ('team_gid' not in params or - params['team_gid'] is None): - raise ValueError("Missing the required parameter `team_gid` when calling `get_users_for_team`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'team_gid' in params: - path_params['team_gid'] = params['team_gid'] # noqa: E501 - - query_params = [] - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/teams/{team_gid}/users', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='UserResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_users_for_workspace(self, workspace_gid, **kwargs): # noqa: E501 - """Get users in a workspace or organization # noqa: E501 - - Returns the compact records for all users in the specified workspace or organization. Results are sorted alphabetically and limited to 2000. For more results use the `/users` endpoint. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_users_for_workspace(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_users_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_users_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - return data - - def get_users_for_workspace_with_http_info(self, workspace_gid, **kwargs): # noqa: E501 - """Get users in a workspace or organization # noqa: E501 - - Returns the compact records for all users in the specified workspace or organization. Results are sorted alphabetically and limited to 2000. For more results use the `/users` endpoint. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_users_for_workspace_with_http_info(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace_gid', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_users_for_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `get_users_for_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}/users', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='UserResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/webhooks_api.py b/asana/api/webhooks_api.py deleted file mode 100644 index 2eb70fb6..00000000 --- a/asana/api/webhooks_api.py +++ /dev/null @@ -1,566 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class WebhooksApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_webhook(self, body, **kwargs): # noqa: E501 - """Establish a webhook # noqa: E501 - - Establishing a webhook is a two-part process. First, a simple HTTP POST request initiates the creation similar to creating any other resource. Next, in the middle of this request comes the confirmation handshake. When a webhook is created, we will send a test POST to the target with an `X-Hook-Secret` header. The target must respond with a `200 OK` or `204 No Content` and a matching `X-Hook-Secret` header to confirm that this webhook subscription is indeed expected. We strongly recommend storing this secret to be used to verify future webhook event signatures. The POST request to create the webhook will then return with the status of the request. If you do not acknowledge the webhook’s confirmation handshake it will fail to setup, and you will receive an error in response to your attempt to create it. This means you need to be able to receive and complete the webhook *while* the POST request is in-flight (in other words, have a server that can handle requests asynchronously). Invalid hostnames like localhost will recieve a 403 Forbidden status code. ``` # Request curl -H \"Authorization: Bearer \" \\ -X POST https://app.asana.com/api/1.0/webhooks \\ -d \"resource=8675309\" \\ -d \"target=https://example.com/receive-webhook/7654\" ``` ``` # Handshake sent to https://example.com/ POST /receive-webhook/7654 X-Hook-Secret: b537207f20cbfa02357cf448134da559e8bd39d61597dcd5631b8012eae53e81 ``` ``` # Handshake response sent by example.com HTTP/1.1 200 X-Hook-Secret: b537207f20cbfa02357cf448134da559e8bd39d61597dcd5631b8012eae53e81 ``` ``` # Response HTTP/1.1 201 { \"data\": { \"gid\": \"43214\", \"resource\": { \"gid\": \"8675309\", \"name\": \"Bugs\" }, \"target\": \"https://example.com/receive-webhook/7654\", \"active\": false, \"last_success_at\": null, \"last_failure_at\": null, \"last_failure_content\": null } } ``` # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_webhook(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WebhooksBody body: The webhook workspace and target. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WebhookResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.create_webhook_with_http_info(body, **kwargs) # noqa: E501 - else: - (data) = self.create_webhook_with_http_info(body, **kwargs) # noqa: E501 - return data - - def create_webhook_with_http_info(self, body, **kwargs): # noqa: E501 - """Establish a webhook # noqa: E501 - - Establishing a webhook is a two-part process. First, a simple HTTP POST request initiates the creation similar to creating any other resource. Next, in the middle of this request comes the confirmation handshake. When a webhook is created, we will send a test POST to the target with an `X-Hook-Secret` header. The target must respond with a `200 OK` or `204 No Content` and a matching `X-Hook-Secret` header to confirm that this webhook subscription is indeed expected. We strongly recommend storing this secret to be used to verify future webhook event signatures. The POST request to create the webhook will then return with the status of the request. If you do not acknowledge the webhook’s confirmation handshake it will fail to setup, and you will receive an error in response to your attempt to create it. This means you need to be able to receive and complete the webhook *while* the POST request is in-flight (in other words, have a server that can handle requests asynchronously). Invalid hostnames like localhost will recieve a 403 Forbidden status code. ``` # Request curl -H \"Authorization: Bearer \" \\ -X POST https://app.asana.com/api/1.0/webhooks \\ -d \"resource=8675309\" \\ -d \"target=https://example.com/receive-webhook/7654\" ``` ``` # Handshake sent to https://example.com/ POST /receive-webhook/7654 X-Hook-Secret: b537207f20cbfa02357cf448134da559e8bd39d61597dcd5631b8012eae53e81 ``` ``` # Handshake response sent by example.com HTTP/1.1 200 X-Hook-Secret: b537207f20cbfa02357cf448134da559e8bd39d61597dcd5631b8012eae53e81 ``` ``` # Response HTTP/1.1 201 { \"data\": { \"gid\": \"43214\", \"resource\": { \"gid\": \"8675309\", \"name\": \"Bugs\" }, \"target\": \"https://example.com/receive-webhook/7654\", \"active\": false, \"last_success_at\": null, \"last_failure_at\": null, \"last_failure_content\": null } } ``` # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_webhook_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WebhooksBody body: The webhook workspace and target. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WebhookResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method create_webhook" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `create_webhook`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/webhooks', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='WebhookResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_webhook(self, webhook_gid, **kwargs): # noqa: E501 - """Delete a webhook # noqa: E501 - - This method *permanently* removes a webhook. Note that it may be possible to receive a request that was already in flight after deleting the webhook, but no further requests will be issued. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_webhook(webhook_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str webhook_gid: Globally unique identifier for the webhook. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.delete_webhook_with_http_info(webhook_gid, **kwargs) # noqa: E501 - else: - (data) = self.delete_webhook_with_http_info(webhook_gid, **kwargs) # noqa: E501 - return data - - def delete_webhook_with_http_info(self, webhook_gid, **kwargs): # noqa: E501 - """Delete a webhook # noqa: E501 - - This method *permanently* removes a webhook. Note that it may be possible to receive a request that was already in flight after deleting the webhook, but no further requests will be issued. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_webhook_with_http_info(webhook_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str webhook_gid: Globally unique identifier for the webhook. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['webhook_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_webhook" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'webhook_gid' is set - if ('webhook_gid' not in params or - params['webhook_gid'] is None): - raise ValueError("Missing the required parameter `webhook_gid` when calling `delete_webhook`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'webhook_gid' in params: - path_params['webhook_gid'] = params['webhook_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/webhooks/{webhook_gid}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_webhook(self, webhook_gid, **kwargs): # noqa: E501 - """Get a webhook # noqa: E501 - - Returns the full record for the given webhook. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_webhook(webhook_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str webhook_gid: Globally unique identifier for the webhook. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WebhookResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_webhook_with_http_info(webhook_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_webhook_with_http_info(webhook_gid, **kwargs) # noqa: E501 - return data - - def get_webhook_with_http_info(self, webhook_gid, **kwargs): # noqa: E501 - """Get a webhook # noqa: E501 - - Returns the full record for the given webhook. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_webhook_with_http_info(webhook_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str webhook_gid: Globally unique identifier for the webhook. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WebhookResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['webhook_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_webhook" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'webhook_gid' is set - if ('webhook_gid' not in params or - params['webhook_gid'] is None): - raise ValueError("Missing the required parameter `webhook_gid` when calling `get_webhook`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'webhook_gid' in params: - path_params['webhook_gid'] = params['webhook_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/webhooks/{webhook_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='WebhookResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_webhooks(self, workspace, **kwargs): # noqa: E501 - """Get multiple webhooks # noqa: E501 - - Get the compact representation of all webhooks your app has registered for the authenticated user in the given workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_webhooks(workspace, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace: The workspace to query for webhooks in. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str resource: Only return webhooks for the given resource. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WebhookResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_webhooks_with_http_info(workspace, **kwargs) # noqa: E501 - else: - (data) = self.get_webhooks_with_http_info(workspace, **kwargs) # noqa: E501 - return data - - def get_webhooks_with_http_info(self, workspace, **kwargs): # noqa: E501 - """Get multiple webhooks # noqa: E501 - - Get the compact representation of all webhooks your app has registered for the authenticated user in the given workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_webhooks_with_http_info(workspace, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace: The workspace to query for webhooks in. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param str resource: Only return webhooks for the given resource. - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WebhookResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace', 'limit', 'offset', 'resource', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_webhooks" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace' is set - if ('workspace' not in params or - params['workspace'] is None): - raise ValueError("Missing the required parameter `workspace` when calling `get_webhooks`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'workspace' in params: - query_params.append(('workspace', params['workspace'])) # noqa: E501 - if 'resource' in params: - query_params.append(('resource', params['resource'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/webhooks', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='WebhookResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_webhook(self, body, webhook_gid, **kwargs): # noqa: E501 - """Update a webhook # noqa: E501 - - An existing webhook's filters can be updated by making a PUT request on the URL for that webhook. Note that the webhook's previous `filters` array will be completely overwritten by the `filters` sent in the PUT request. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_webhook(body, webhook_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WebhooksWebhookGidBody body: The updated filters for the webhook. (required) - :param str webhook_gid: Globally unique identifier for the webhook. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WebhookResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_webhook_with_http_info(body, webhook_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_webhook_with_http_info(body, webhook_gid, **kwargs) # noqa: E501 - return data - - def update_webhook_with_http_info(self, body, webhook_gid, **kwargs): # noqa: E501 - """Update a webhook # noqa: E501 - - An existing webhook's filters can be updated by making a PUT request on the URL for that webhook. Note that the webhook's previous `filters` array will be completely overwritten by the `filters` sent in the PUT request. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_webhook_with_http_info(body, webhook_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WebhooksWebhookGidBody body: The updated filters for the webhook. (required) - :param str webhook_gid: Globally unique identifier for the webhook. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WebhookResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'webhook_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_webhook" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `update_webhook`") # noqa: E501 - # verify the required parameter 'webhook_gid' is set - if ('webhook_gid' not in params or - params['webhook_gid'] is None): - raise ValueError("Missing the required parameter `webhook_gid` when calling `update_webhook`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'webhook_gid' in params: - path_params['webhook_gid'] = params['webhook_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/webhooks/{webhook_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='WebhookResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/workspace_memberships_api.py b/asana/api/workspace_memberships_api.py deleted file mode 100644 index 84573726..00000000 --- a/asana/api/workspace_memberships_api.py +++ /dev/null @@ -1,359 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class WorkspaceMembershipsApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def get_workspace_membership(self, workspace_membership_gid, **kwargs): # noqa: E501 - """Get a workspace membership # noqa: E501 - - Returns the complete workspace record for a single workspace membership. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_workspace_membership(workspace_membership_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_membership_gid: (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WorkspaceMembershipResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_workspace_membership_with_http_info(workspace_membership_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_workspace_membership_with_http_info(workspace_membership_gid, **kwargs) # noqa: E501 - return data - - def get_workspace_membership_with_http_info(self, workspace_membership_gid, **kwargs): # noqa: E501 - """Get a workspace membership # noqa: E501 - - Returns the complete workspace record for a single workspace membership. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_workspace_membership_with_http_info(workspace_membership_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_membership_gid: (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WorkspaceMembershipResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace_membership_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_workspace_membership" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace_membership_gid' is set - if ('workspace_membership_gid' not in params or - params['workspace_membership_gid'] is None): - raise ValueError("Missing the required parameter `workspace_membership_gid` when calling `get_workspace_membership`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_membership_gid' in params: - path_params['workspace_membership_gid'] = params['workspace_membership_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspace_memberships/{workspace_membership_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='WorkspaceMembershipResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_workspace_memberships_for_user(self, user_gid, **kwargs): # noqa: E501 - """Get workspace memberships for a user # noqa: E501 - - Returns the compact workspace membership records for the user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_workspace_memberships_for_user(user_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_gid: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WorkspaceMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_workspace_memberships_for_user_with_http_info(user_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_workspace_memberships_for_user_with_http_info(user_gid, **kwargs) # noqa: E501 - return data - - def get_workspace_memberships_for_user_with_http_info(self, user_gid, **kwargs): # noqa: E501 - """Get workspace memberships for a user # noqa: E501 - - Returns the compact workspace membership records for the user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_workspace_memberships_for_user_with_http_info(user_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str user_gid: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (required) - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WorkspaceMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['user_gid', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_workspace_memberships_for_user" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'user_gid' is set - if ('user_gid' not in params or - params['user_gid'] is None): - raise ValueError("Missing the required parameter `user_gid` when calling `get_workspace_memberships_for_user`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'user_gid' in params: - path_params['user_gid'] = params['user_gid'] # noqa: E501 - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/users/{user_gid}/workspace_memberships', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='WorkspaceMembershipResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_workspace_memberships_for_workspace(self, workspace_gid, **kwargs): # noqa: E501 - """Get the workspace memberships for a workspace # noqa: E501 - - Returns the compact workspace membership records for the workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_workspace_memberships_for_workspace(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param str user: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WorkspaceMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_workspace_memberships_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_workspace_memberships_for_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - return data - - def get_workspace_memberships_for_workspace_with_http_info(self, workspace_gid, **kwargs): # noqa: E501 - """Get the workspace memberships for a workspace # noqa: E501 - - Returns the compact workspace membership records for the workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_workspace_memberships_for_workspace_with_http_info(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param str user: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WorkspaceMembershipResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace_gid', 'user', 'limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_workspace_memberships_for_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `get_workspace_memberships_for_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'user' in params: - query_params.append(('user', params['user'])) # noqa: E501 - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}/workspace_memberships', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='WorkspaceMembershipResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api/workspaces_api.py b/asana/api/workspaces_api.py deleted file mode 100644 index a1732afa..00000000 --- a/asana/api/workspaces_api.py +++ /dev/null @@ -1,574 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from asana.api_client import ApiClient - - -class WorkspacesApi(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def add_user_for_workspace(self, body, workspace_gid, **kwargs): # noqa: E501 - """Add a user to a workspace or organization # noqa: E501 - - Add a user to a workspace or organization. The user can be referenced by their globally unique user ID or their email address. Returns the full user record for the invited user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_user_for_workspace(body, workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WorkspaceGidAddUserBody body: The user to add to the workspace. (required) - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserBaseResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.add_user_for_workspace_with_http_info(body, workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.add_user_for_workspace_with_http_info(body, workspace_gid, **kwargs) # noqa: E501 - return data - - def add_user_for_workspace_with_http_info(self, body, workspace_gid, **kwargs): # noqa: E501 - """Add a user to a workspace or organization # noqa: E501 - - Add a user to a workspace or organization. The user can be referenced by their globally unique user ID or their email address. Returns the full user record for the invited user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.add_user_for_workspace_with_http_info(body, workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WorkspaceGidAddUserBody body: The user to add to the workspace. (required) - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: UserBaseResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'workspace_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method add_user_for_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `add_user_for_workspace`") # noqa: E501 - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `add_user_for_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}/addUser', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='UserBaseResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_workspace(self, workspace_gid, **kwargs): # noqa: E501 - """Get a workspace # noqa: E501 - - Returns the full workspace record for a single workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_workspace(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WorkspaceResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.get_workspace_with_http_info(workspace_gid, **kwargs) # noqa: E501 - return data - - def get_workspace_with_http_info(self, workspace_gid, **kwargs): # noqa: E501 - """Get a workspace # noqa: E501 - - Returns the full workspace record for a single workspace. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_workspace_with_http_info(workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WorkspaceResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['workspace_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `get_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='WorkspaceResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_workspaces(self, **kwargs): # noqa: E501 - """Get multiple workspaces # noqa: E501 - - Returns the compact records for all workspaces visible to the authorized user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_workspaces(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WorkspaceResponseArray - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.get_workspaces_with_http_info(**kwargs) # noqa: E501 - else: - (data) = self.get_workspaces_with_http_info(**kwargs) # noqa: E501 - return data - - def get_workspaces_with_http_info(self, **kwargs): # noqa: E501 - """Get multiple workspaces # noqa: E501 - - Returns the compact records for all workspaces visible to the authorized user. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_workspaces_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool - :param int limit: Results per page. The number of objects to return per page. The value must be between 1 and 100. - :param str offset: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WorkspaceResponseArray - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['limit', 'offset', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method get_workspaces" % key - ) - params[key] = val - del params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'limit' in params: - query_params.append(('limit', params['limit'])) # noqa: E501 - if 'offset' in params: - query_params.append(('offset', params['offset'])) # noqa: E501 - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='WorkspaceResponseArray', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def remove_user_for_workspace(self, body, workspace_gid, **kwargs): # noqa: E501 - """Remove a user from a workspace or organization # noqa: E501 - - Remove a user from a workspace or organization. The user making this call must be an admin in the workspace. The user can be referenced by their globally unique user ID or their email address. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_user_for_workspace(body, workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WorkspaceGidRemoveUserBody body: The user to remove from the workspace. (required) - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.remove_user_for_workspace_with_http_info(body, workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.remove_user_for_workspace_with_http_info(body, workspace_gid, **kwargs) # noqa: E501 - return data - - def remove_user_for_workspace_with_http_info(self, body, workspace_gid, **kwargs): # noqa: E501 - """Remove a user from a workspace or organization # noqa: E501 - - Remove a user from a workspace or organization. The user making this call must be an admin in the workspace. The user can be referenced by their globally unique user ID or their email address. Returns an empty data record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.remove_user_for_workspace_with_http_info(body, workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WorkspaceGidRemoveUserBody body: The user to remove from the workspace. (required) - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :return: EmptyResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'workspace_gid'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method remove_user_for_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `remove_user_for_workspace`") # noqa: E501 - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `remove_user_for_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}/removeUser', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='EmptyResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) - - def update_workspace(self, body, workspace_gid, **kwargs): # noqa: E501 - """Update a workspace # noqa: E501 - - A specific, existing workspace can be updated by making a PUT request on the URL for that workspace. Only the fields provided in the data block will be updated; any unspecified fields will remain unchanged. Currently the only field that can be modified for a workspace is its name. Returns the complete, updated workspace record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_workspace(body, workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WorkspacesWorkspaceGidBody body: The workspace object with all updated properties. (required) - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WorkspaceResponseData - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.update_workspace_with_http_info(body, workspace_gid, **kwargs) # noqa: E501 - else: - (data) = self.update_workspace_with_http_info(body, workspace_gid, **kwargs) # noqa: E501 - return data - - def update_workspace_with_http_info(self, body, workspace_gid, **kwargs): # noqa: E501 - """Update a workspace # noqa: E501 - - A specific, existing workspace can be updated by making a PUT request on the URL for that workspace. Only the fields provided in the data block will be updated; any unspecified fields will remain unchanged. Currently the only field that can be modified for a workspace is its name. Returns the complete, updated workspace record. # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.update_workspace_with_http_info(body, workspace_gid, async_req=True) - >>> result = thread.get() - - :param async_req bool - :param WorkspacesWorkspaceGidBody body: The workspace object with all updated properties. (required) - :param str workspace_gid: Globally unique identifier for the workspace or organization. (required) - :param list[str] opt_fields: This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. - :return: WorkspaceResponseData - If the method is called asynchronously, - returns the request thread. - """ - - all_params = ['body', 'workspace_gid', 'opt_fields'] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - for key, val in six.iteritems(params['kwargs']): - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method update_workspace" % key - ) - params[key] = val - del params['kwargs'] - # verify the required parameter 'body' is set - if ('body' not in params or - params['body'] is None): - raise ValueError("Missing the required parameter `body` when calling `update_workspace`") # noqa: E501 - # verify the required parameter 'workspace_gid' is set - if ('workspace_gid' not in params or - params['workspace_gid'] is None): - raise ValueError("Missing the required parameter `workspace_gid` when calling `update_workspace`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'workspace_gid' in params: - path_params['workspace_gid'] = params['workspace_gid'] # noqa: E501 - - query_params = [] - if 'opt_fields' in params: - query_params.append(('opt_fields', params['opt_fields'])) # noqa: E501 - collection_formats['opt_fields'] = 'csv' # noqa: E501 - - - header_params = kwargs.get("header_params", {}) - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in params: - body_params = params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json; charset=UTF-8']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json; charset=UTF-8']) # noqa: E501 - - # Authentication setting - auth_settings = ['oauth2'] # noqa: E501 - - return self.api_client.call_api( - '/workspaces/{workspace_gid}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='WorkspaceResponseData', # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/asana/api_client.py b/asana/api_client.py deleted file mode 100644 index 67c425a3..00000000 --- a/asana/api_client.py +++ /dev/null @@ -1,650 +0,0 @@ -# coding: utf-8 -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" -from __future__ import absolute_import - -import logging -import datetime -import json -import mimetypes -from multiprocessing.pool import ThreadPool -import os -import platform -import re -import tempfile - -# python 2 and python 3 compatibility library -import six -from six.moves.urllib.parse import quote - -from asana.configuration import Configuration -import asana.models -from asana import rest - -from urllib.parse import urlencode - - -class ApiClient(object): - """Generic API client for Swagger client library builds. - - Swagger generic API client. This client handles the client- - server communication, and is invariant across implementations. Specifics of - the methods and models for each application are generated from the Swagger - templates. - - NOTE: This class is auto generated by the swagger code generator program. - Ref: https://github.com/swagger-api/swagger-codegen - Do not edit the class manually. - - :param configuration: .Configuration object for this client - :param header_name: a header to pass when making calls to the API. - :param header_value: a header value to pass when making calls to - the API. - :param cookie: a cookie to include in the header when making calls - to the API - """ - - PRIMITIVE_TYPES = (float, bool, bytes, six.text_type) + six.integer_types - NATIVE_TYPES_MAPPING = { - 'int': int, - 'long': int if six.PY3 else long, # noqa: F821 - 'float': float, - 'str': str, - 'bool': bool, - 'date': datetime.date, - 'datetime': datetime.datetime, - 'object': object, - } - - def __init__(self, configuration=None, header_name=None, header_value=None, - cookie=None): - if configuration is None: - configuration = Configuration() - self.configuration = configuration - - try: - self.pool = ThreadPool() - except OSError: - logging.warning('Looks like your system does not support ThreadPool but it will try without it if you do not use async requests') - self.rest_client = rest.RESTClientObject(configuration) - self.default_headers = {} - if header_name is not None: - self.default_headers[header_name] = header_value - self.cookie = cookie - # Set default User-Agent. - self.user_agent = 'Swagger-Codegen/4.0.11/python' - # Add custom header - self.default_headers['X-Asana-Client-Lib'] = urlencode( - { - 'language': 'Python', - 'version': '4.0.11', - 'language_version': platform.python_version(), - 'os': platform.system(), - 'os_version': platform.release() - } - ) - - def __del__(self): - if hasattr(self, "pool"): - self.pool.close() - self.pool.join() - - @property - def user_agent(self): - """User agent for this API client""" - return self.default_headers['User-Agent'] - - @user_agent.setter - def user_agent(self, value): - self.default_headers['User-Agent'] = value - - def set_default_header(self, header_name, header_value): - self.default_headers[header_name] = header_value - - def __call_api( - self, resource_path, method, path_params=None, - query_params=None, header_params=None, body=None, post_params=None, - files=None, response_type=None, auth_settings=None, - _return_http_data_only=None, collection_formats=None, - _preload_content=True, _request_timeout=None): - - config = self.configuration - - # header parameters - header_params = header_params or {} - header_params.update(self.default_headers) - if self.cookie: - header_params['Cookie'] = self.cookie - if header_params: - header_params = self.sanitize_for_serialization(header_params) - header_params = dict(self.parameters_to_tuples(header_params, - collection_formats)) - - # path parameters - if path_params: - path_params = self.sanitize_for_serialization(path_params) - path_params = self.parameters_to_tuples(path_params, - collection_formats) - for k, v in path_params: - # specified safe chars, encode everything - resource_path = resource_path.replace( - '{%s}' % k, - quote(str(v), safe=config.safe_chars_for_path_param) - ) - - # query parameters - if query_params: - query_params = self.sanitize_for_serialization(query_params) - query_params = self.parameters_to_tuples(query_params, - collection_formats) - - # post parameters - if post_params or files: - post_params = self.prepare_post_parameters(post_params, files) - post_params = self.sanitize_for_serialization(post_params) - post_params = self.parameters_to_tuples(post_params, - collection_formats) - - # auth setting - self.update_params_for_auth(header_params, query_params, auth_settings) - - # body - if body: - body = self.sanitize_for_serialization(body) - - # request url - url = self.configuration.host + resource_path - - # perform request and return response - response_data = self.request( - method, url, query_params=query_params, headers=header_params, - post_params=post_params, body=body, - _preload_content=_preload_content, - _request_timeout=_request_timeout) - - self.last_response = response_data - - return_data = response_data - if _preload_content: - # deserialize response data - if response_type: - return_data = self.deserialize(response_data, response_type) - else: - return_data = None - - if _return_http_data_only: - return (return_data) - else: - return (return_data, response_data.status, - response_data.getheaders()) - - def sanitize_for_serialization(self, obj): - """Builds a JSON POST object. - - If obj is None, return None. - If obj is str, int, long, float, bool, return directly. - If obj is datetime.datetime, datetime.date - convert to string in iso8601 format. - If obj is list, sanitize each element in the list. - If obj is dict, return the dict. - If obj is swagger model, return the properties dict. - - :param obj: The data to serialize. - :return: The serialized form of data. - """ - if obj is None: - return None - elif isinstance(obj, self.PRIMITIVE_TYPES): - return obj - elif isinstance(obj, list): - return [self.sanitize_for_serialization(sub_obj) - for sub_obj in obj] - elif isinstance(obj, tuple): - return tuple(self.sanitize_for_serialization(sub_obj) - for sub_obj in obj) - elif isinstance(obj, (datetime.datetime, datetime.date)): - return obj.isoformat() - - if isinstance(obj, dict): - obj_dict = obj - else: - # Convert model obj to dict except - # attributes `swagger_types`, `attribute_map` - # and attributes which value is not None. - # Convert attribute name to json key in - # model definition for request. - obj_dict = {obj.attribute_map[attr]: getattr(obj, attr) - for attr, _ in six.iteritems(obj.swagger_types) - if getattr(obj, attr) is not None} - - return {key: self.sanitize_for_serialization(val) - for key, val in six.iteritems(obj_dict)} - - def deserialize(self, response, response_type): - """Deserializes response into an object. - - :param response: RESTResponse object to be deserialized. - :param response_type: class literal for - deserialized object, or string of class name. - - :return: deserialized object. - """ - # handle file downloading - # save response body into a tmp file and return the instance - if response_type == "file": - return self.__deserialize_file(response) - - # fetch data from response object - try: - data = json.loads(response.data) - except ValueError: - data = response.data - - return self.__deserialize(data, response_type) - - def __deserialize(self, data, klass): - """Deserializes dict, list, str into an object. - - :param data: dict, list or str. - :param klass: class literal, or string of class name. - - :return: object. - """ - if data is None: - return None - - if type(klass) == str: - if klass.startswith('list['): - sub_kls = re.match(r'list\[(.*)\]', klass).group(1) - return [self.__deserialize(sub_data, sub_kls) - for sub_data in data] - - if klass.startswith('dict('): - sub_kls = re.match(r'dict\(([^,]*), (.*)\)', klass).group(2) - return {k: self.__deserialize(v, sub_kls) - for k, v in six.iteritems(data)} - - # convert str to class - if klass in self.NATIVE_TYPES_MAPPING: - klass = self.NATIVE_TYPES_MAPPING[klass] - else: - klass = getattr(asana.models, klass) - - if klass in self.PRIMITIVE_TYPES: - return self.__deserialize_primitive(data, klass) - elif klass == object: - return self.__deserialize_object(data) - elif klass == datetime.date: - return self.__deserialize_date(data) - elif klass == datetime.datetime: - return self.__deserialize_datatime(data) - else: - return self.__deserialize_model(data, klass) - - def call_api(self, resource_path, method, - path_params=None, query_params=None, header_params=None, - body=None, post_params=None, files=None, - response_type=None, auth_settings=None, async_req=None, - _return_http_data_only=None, collection_formats=None, - _preload_content=True, _request_timeout=None): - """Makes the HTTP request (synchronous) and returns deserialized data. - - To make an async request, set the async_req parameter. - - :param resource_path: Path to method endpoint. - :param method: Method to call. - :param path_params: Path parameters in the url. - :param query_params: Query parameters in the url. - :param header_params: Header parameters to be - placed in the request header. - :param body: Request body. - :param post_params dict: Request post form parameters, - for `application/x-www-form-urlencoded`, `multipart/form-data`. - :param auth_settings list: Auth Settings names for the request. - :param response: Response data type. - :param files dict: key -> filename, value -> filepath, - for `multipart/form-data`. - :param async_req bool: execute request asynchronously - :param _return_http_data_only: response data without head status code - and headers - :param collection_formats: dict of collection formats for path, query, - header, and post parameters. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: - If async_req parameter is True, - the request will be called asynchronously. - The method will return the request thread. - If parameter async_req is False or missing, - then the method will return the response directly. - """ - if not async_req: - return self.__call_api(resource_path, method, - path_params, query_params, header_params, - body, post_params, files, - response_type, auth_settings, - _return_http_data_only, collection_formats, - _preload_content, _request_timeout) - else: - thread = self.pool.apply_async(self.__call_api, (resource_path, - method, path_params, query_params, - header_params, body, - post_params, files, - response_type, auth_settings, - _return_http_data_only, - collection_formats, - _preload_content, _request_timeout)) - return thread - - def request(self, method, url, query_params=None, headers=None, - post_params=None, body=None, _preload_content=True, - _request_timeout=None): - """Makes the HTTP request using RESTClient.""" - if method == "GET": - return self.rest_client.GET(url, - query_params=query_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - headers=headers) - elif method == "HEAD": - return self.rest_client.HEAD(url, - query_params=query_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - headers=headers) - elif method == "OPTIONS": - return self.rest_client.OPTIONS(url, - query_params=query_params, - headers=headers, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - elif method == "POST": - return self.rest_client.POST(url, - query_params=query_params, - headers=headers, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - elif method == "PUT": - return self.rest_client.PUT(url, - query_params=query_params, - headers=headers, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - elif method == "PATCH": - return self.rest_client.PATCH(url, - query_params=query_params, - headers=headers, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - elif method == "DELETE": - return self.rest_client.DELETE(url, - query_params=query_params, - headers=headers, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - else: - raise ValueError( - "http method must be `GET`, `HEAD`, `OPTIONS`," - " `POST`, `PATCH`, `PUT` or `DELETE`." - ) - - def parameters_to_tuples(self, params, collection_formats): - """Get parameters as list of tuples, formatting collections. - - :param params: Parameters as dict or list of two-tuples - :param dict collection_formats: Parameter collection formats - :return: Parameters as list of tuples, collections formatted - """ - new_params = [] - if collection_formats is None: - collection_formats = {} - for k, v in six.iteritems(params) if isinstance(params, dict) else params: # noqa: E501 - if k in collection_formats: - collection_format = collection_formats[k] - if collection_format == 'multi': - new_params.extend((k, value) for value in v) - else: - if collection_format == 'ssv': - delimiter = ' ' - elif collection_format == 'tsv': - delimiter = '\t' - elif collection_format == 'pipes': - delimiter = '|' - else: # csv is the default - delimiter = ',' - new_params.append( - (k, delimiter.join(str(value) for value in v))) - else: - new_params.append((k, v)) - return new_params - - def prepare_post_parameters(self, post_params=None, files=None): - """Builds form parameters. - - :param post_params: Normal form parameters. - :param files: File parameters. - :return: Form parameters with files. - """ - params = [] - - if post_params: - params = post_params - - if files: - for k, v in six.iteritems(files): - if not v: - continue - file_names = v if type(v) is list else [v] - for n in file_names: - with open(n, 'rb') as f: - filename = os.path.basename(f.name) - filedata = f.read() - mimetype = (mimetypes.guess_type(filename)[0] or - 'application/octet-stream') - params.append( - tuple([k, tuple([filename, filedata, mimetype])])) - - return params - - def select_header_accept(self, accepts): - """Returns `Accept` based on an array of accepts provided. - - :param accepts: List of headers. - :return: Accept (e.g. application/json). - """ - if not accepts: - return - - accepts = [x.lower() for x in accepts] - - if 'application/json' in accepts: - return 'application/json' - else: - return ', '.join(accepts) - - def select_header_content_type(self, content_types): - """Returns `Content-Type` based on an array of content_types provided. - - :param content_types: List of content-types. - :return: Content-Type (e.g. application/json). - """ - if not content_types: - return 'application/json' - - content_types = [x.lower() for x in content_types] - - if 'application/json' in content_types or '*/*' in content_types: - return 'application/json' - else: - return content_types[0] - - def update_params_for_auth(self, headers, querys, auth_settings): - """Updates header and query params based on authentication setting. - - :param headers: Header parameters dict to be updated. - :param querys: Query parameters tuple list to be updated. - :param auth_settings: Authentication setting identifiers list. - """ - if not auth_settings: - return - - for auth in auth_settings: - auth_setting = self.configuration.auth_settings().get(auth) - if auth_setting: - if not auth_setting['value']: - continue - elif auth_setting['in'] == 'header': - headers[auth_setting['key']] = auth_setting['value'] - elif auth_setting['in'] == 'query': - querys.append((auth_setting['key'], auth_setting['value'])) - else: - raise ValueError( - 'Authentication token must be in `query` or `header`' - ) - - def __deserialize_file(self, response): - """Deserializes body to file - - Saves response body into a file in a temporary folder, - using the filename from the `Content-Disposition` header if provided. - - :param response: RESTResponse. - :return: file path. - """ - fd, path = tempfile.mkstemp(dir=self.configuration.temp_folder_path) - os.close(fd) - os.remove(path) - - content_disposition = response.getheader("Content-Disposition") - if content_disposition: - filename = re.search(r'filename=[\'"]?([^\'"\s]+)[\'"]?', - content_disposition).group(1) - path = os.path.join(os.path.dirname(path), filename) - response_data = response.data - with open(path, "wb") as f: - if isinstance(response_data, str): - # change str to bytes so we can write it - response_data = response_data.encode('utf-8') - f.write(response_data) - else: - f.write(response_data) - return path - - def __deserialize_primitive(self, data, klass): - """Deserializes string to primitive type. - - :param data: str. - :param klass: class literal. - - :return: int, long, float, str, bool. - """ - try: - return klass(data) - except UnicodeEncodeError: - return six.text_type(data) - except TypeError: - return data - - def __deserialize_object(self, value): - """Return a original value. - - :return: object. - """ - return value - - def __deserialize_date(self, string): - """Deserializes string to date. - - :param string: str. - :return: date. - """ - try: - from dateutil.parser import parse - return parse(string).date() - except ImportError: - return string - except ValueError: - raise rest.ApiException( - status=0, - reason="Failed to parse `{0}` as date object".format(string) - ) - - def __deserialize_datatime(self, string): - """Deserializes string to datetime. - - The string should be in iso8601 datetime format. - - :param string: str. - :return: datetime. - """ - try: - from dateutil.parser import parse - return parse(string) - except ImportError: - return string - except ValueError: - raise rest.ApiException( - status=0, - reason=( - "Failed to parse `{0}` as datetime object" - .format(string) - ) - ) - - def __hasattr(self, object, name): - return name in object.__class__.__dict__ - - def __deserialize_model(self, data, klass): - """Deserializes list or dict to model. - - :param data: dict, list. - :param klass: class literal. - :return: model object. - """ - - if not klass.swagger_types and not self.__hasattr(klass, 'get_real_child_model'): - return data - - kwargs = {} - if klass.swagger_types is not None: - for attr, attr_type in six.iteritems(klass.swagger_types): - if (data is not None and - klass.attribute_map[attr] in data and - isinstance(data, (list, dict))): - value = data[klass.attribute_map[attr]] - kwargs[attr] = self.__deserialize(value, attr_type) - - instance = klass(**kwargs) - - if (isinstance(instance, dict) and - klass.swagger_types is not None and - isinstance(data, dict)): - for key, value in data.items(): - if key not in klass.swagger_types: - instance[key] = value - if self.__hasattr(instance, 'get_real_child_model'): - klass_name = instance.get_real_child_model(data) - if klass_name: - instance = self.__deserialize(data, klass_name) - return instance diff --git a/asana/client.py b/asana/client.py new file mode 100644 index 00000000..f72b1727 --- /dev/null +++ b/asana/client.py @@ -0,0 +1,367 @@ +from types import ModuleType +import json +import platform +import time +import string +import warnings + +import requests + +from . import error, resources, session, __version__ +from .page_iterator import CollectionPageIterator +import urllib.parse as urlparse + +# Create a dict of resource classes +RESOURCE_CLASSES = {} +for name, module in resources.__dict__.items(): + classified_name = string.capwords(name, '_').replace('_', '') + if classified_name == "BatchApi": + classified_name = "BatchAPI" + if classified_name == "AuditLogApi": + classified_name = "AuditLogAPI" + if isinstance(module, ModuleType) and classified_name in module.__dict__: + RESOURCE_CLASSES[name] = module.__dict__[classified_name] + +# Create a mapping of status codes to classes +STATUS_MAP = {} +for name, Klass in error.__dict__.items(): + if isinstance(Klass, type) and issubclass(Klass, error.AsanaError): + STATUS_MAP[Klass().status] = Klass + + +class Client(object): + """Asana client class""" + + DEFAULT_OPTIONS = { + 'base_url': 'https://app.asana.com/api/1.0', + 'item_limit': None, + 'page_size': 50, + 'poll_interval': 5, + 'max_retries': 5, + 'full_payload': False, + 'iterator_type': 'items' + } + + RETRY_DELAY = 1.0 + RETRY_BACKOFF = 2.0 + + CLIENT_OPTIONS = set(DEFAULT_OPTIONS.keys()) + QUERY_OPTIONS = {'limit', 'offset', 'sync'} + REQUEST_OPTIONS = {'headers', 'params', 'data', 'files', 'verify', + 'timeout'} + API_OPTIONS = {'pretty', 'fields', 'expand', 'client_name'} + + LOG_ASANA_CHANGE_WARNINGS = True + + ALL_OPTIONS = ( + CLIENT_OPTIONS | QUERY_OPTIONS | REQUEST_OPTIONS | API_OPTIONS) + + def __init__(self, session=None, auth=None, **options): + """A :class:`Client` object for interacting with Asana's API. + + A Client object with session, optional auth handler, and options. + + """ + self.session = session or requests.Session() + self.auth = auth + self.headers = options.pop('headers', {}) + # merge the provided options (if any) with the global DEFAULTS + self.options = _merge(self.DEFAULT_OPTIONS, options) + # intializes each resource, injecting this client object into the + # constructor + for name, Klass in RESOURCE_CLASSES.items(): + setattr(self, name, Klass(self)) + + def request(self, method, path, **options): + """Dispatches a request to the Asana HTTP API""" + options = self._merge_options(options) + url = options['base_url'] + path + retry_count = 0 + request_options = self._parse_request_options(options) + self._add_version_header(request_options) + while True: + try: + try: + response = getattr(self.session, method)( + url, auth=self.auth, **request_options) + except requests.exceptions.Timeout: + raise error.RetryableAsanaError() + + self._log_asana_change_header(request_options['headers'], response.headers) + if response.status_code in STATUS_MAP: + raise STATUS_MAP[response.status_code](response) + elif 500 <= response.status_code < 600: + # Any unhandled 500 is a server error. + raise error.ServerError(response) + else: + if options['full_payload']: + return response.json() + else: + return response.json()['data'] + except error.RetryableAsanaError as e: + if retry_count < options['max_retries']: + self._handle_retryable_error(e, retry_count) + retry_count += 1 + else: + raise e + + def _log_asana_change_header(self, req_headers, res_headers): + if self.LOG_ASANA_CHANGE_WARNINGS: + change_header_key = None + + for key in res_headers: + if key.lower() == 'asana-change': + change_header_key = key + + if change_header_key is not None: + accounted_for_flags = [] + + # Grab the request's asana-enable flags + for reqHeader in req_headers: + if reqHeader.lower() == 'asana-enable': + for flag in req_headers[reqHeader].split(','): + accounted_for_flags.append(flag) + elif reqHeader.lower() == 'asana-disable': + for flag in req_headers[reqHeader].split(','): + accounted_for_flags.append(flag) + + changes = res_headers[change_header_key].split(',') + + for unsplit_change in changes: + change = unsplit_change.split(';') + + name = None + info = None + affected = None + + for unsplit_field in change: + field = unsplit_field.split('=') + + field[0] = field[0].strip() + if field[0].strip() == 'name': + name = field[1].strip() + elif field[0].strip() == 'info': + info = field[1].strip() + elif field[0].strip() == 'affected': + affected = field[1].strip() + + # Only show the error if the flag was not in the request's asana-enable header + if (name not in accounted_for_flags) & (affected == 'true'): + message = 'This request is affected by the "' + name + \ + '" deprecation. Please visit this url for more info: ' + info + \ + '\n' + 'Adding "' + name + '" to your "Asana-Enable" or ' + \ + '"Asana-Disable" header will opt in/out to this deprecation ' + \ + 'and suppress this warning.' + + warnings.warn(message) + + + def _handle_retryable_error(self, e, retry_count): + """Sleep based on the type of :class:`RetryableAsanaError`""" + if isinstance(e, error.RateLimitEnforcedError): + time.sleep(e.retry_after) + else: + time.sleep(self.RETRY_DELAY * (self.RETRY_BACKOFF ** retry_count)) + + def get(self, path, query, **options): + """Parses GET request options and dispatches a request.""" + api_options = self._parse_api_options(options, query_string=True) + query_options = self._parse_query_options(options) + parameter_options = self._parse_parameter_options(options) + + # options in the query takes precendence + query = _merge(query_options, api_options, parameter_options, query) + return self.request('get', path, params=query, **options) + + def get_collection(self, path, query, **options): + """Get a collection from a collection endpoint. + + Parses GET request options for a collection endpoint and dispatches a + request. + + """ + options = self._merge_options(options) + if options['iterator_type'] == 'items': + return CollectionPageIterator(self, path, query, options).items() + if options['iterator_type'] is None: + return self.get(path, query, **options) + raise Exception('Unknown value for "iterator_type" option: {}'.format( + str(options['iterator_type']))) + + def post(self, path, data, **options): + """Parses POST request options and dispatches a request.""" + parameter_options = self._parse_parameter_options(options) + body = { + # values in the data body takes precendence + 'data': _merge(parameter_options, data), + 'options': self._parse_api_options(options) + } + headers = _merge( + {'content-type': 'application/json'}, + options.pop('headers', {}) + ) + return self.request('post', path, data=body, headers=headers, **options) + + def put(self, path, data, **options): + """Parses PUT request options and dispatches a request.""" + parameter_options = self._parse_parameter_options(options) + body = { + # values in the data body takes precendence + 'data': _merge(parameter_options, data), + 'options': self._parse_api_options(options) + } + headers = _merge( + {'content-type': 'application/json'}, + options.pop('headers', {}) + ) + return self.request('put', path, data=body, headers=headers, **options) + + def delete(self, path, data, **options): + """Dispatches a DELETE request.""" + return self.request('delete', path, **options) + + def _merge_options(self, *objects): + """Merge option objects with the client's object. + + Merges one or more options objects with client's options and returns a + new options object. + + """ + return _merge(self.options, *objects) + + def _parse_query_options(self, options): + """Select query string options out of the provided options object""" + return self._select_options(options, self.QUERY_OPTIONS) + + def _parse_parameter_options(self, options): + """Select all unknown options. + + Select all unknown options (not query string, API, or request + options) + + """ + return self._select_options(options, self.ALL_OPTIONS, invert=True) + + def _parse_api_options(self, options, query_string=False): + """Select API options out of the provided options object. + + Selects API string options out of the provided options object and + formats for either request body (default) or query string. + + """ + api_options = self._select_options(options, self.API_OPTIONS) + if query_string: + # Prefix all options with "opt_" + query_api_options = {} + for key in api_options: + # Transform list/tuples into comma separated list + if isinstance(api_options[key], (list, tuple)): + query_api_options[ + 'opt_' + key] = ','.join(api_options[key]) + else: + query_api_options[ + 'opt_' + key] = api_options[key] + return query_api_options + else: + return api_options + + def _parse_request_options(self, options): + """Select request options out of the provided options object. + + + Select and formats options to be passed to the 'requests' library's + request methods. + + """ + request_options = self._select_options(options, self.REQUEST_OPTIONS) + if 'params' in request_options: + params = request_options['params'] + for key in params: + if isinstance(params[key], bool): + params[key] = json.dumps(params[key]) + if 'data' in request_options: + # remove empty 'options': + if 'options' in request_options['data'] and ( + len(request_options['data']['options']) == 0): + del request_options['data']['options'] + # serialize 'data' to JSON, requests doesn't do this automatically: + request_options['data'] = json.dumps(request_options['data']) + + headers = self.headers.copy() + headers.update(request_options.get('headers', {})) + request_options['headers'] = headers + return request_options + + def _select_options(self, options, keys, invert=False): + """Select the provided keys out of an options object. + + + Selects the provided keys (or everything except the provided keys) out + of an options object. + + """ + options = self._merge_options(options) + result = {} + for key in options: + if (invert and key not in keys) or (not invert and key in keys): + result[key] = options[key] + return result + + def _add_version_header(self, options): + """Add the client lib version header to the request.""" + headers = options.setdefault('headers', {}) + headers['X-Asana-Client-Lib'] = self._version_header() + + _cached_version_header = None + + def _version_header(self): + """Generate the client version header to send on each request.""" + if not self._cached_version_header: + self._cached_version_header = urlparse.urlencode( + self._version_values()) + return self._cached_version_header + + def _version_values(self): + """Generate the values to go in the client version header.""" + return { + 'language': 'Python', + 'version': __version__, + 'language_version': platform.python_version(), + 'os': platform.system(), + 'os_version': platform.release() + } + + @classmethod + def basic_auth(Klass, apiKey): + """DEPRECATED: this is only present for backwards-compatibility. + + This will be removed in the future; for new apps, prefer the + `access_token` method. + + Construct an Asana Client using a Personal Access Token as if it + were an old (removed) Asana API Key. + """ + return Klass(auth=requests.auth.HTTPBasicAuth(apiKey, '')) + + @classmethod + def access_token(Klass, accessToken): + """Construct an Asana Client with a Personal Access Token""" + return Klass( + session.AsanaOAuth2Session(token={'access_token': accessToken})) + + @classmethod + def oauth(Klass, **kwargs): + """Construct an Asana Client with Oauth credentials. + + Construct an Asana Client with OAuth credentials ('client_id' and + 'client_secret' or 'token'). + + """ + return Klass(session.AsanaOAuth2Session(**kwargs)) + + +def _merge(*objects): + """Merge one or more objects into a new object""" + result = {} + [result.update(obj) for obj in objects] + return result diff --git a/asana/configuration.py b/asana/configuration.py deleted file mode 100644 index fe7e00ad..00000000 --- a/asana/configuration.py +++ /dev/null @@ -1,253 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import copy -import logging -import multiprocessing -import sys -import urllib3 - -import six -from six.moves import http_client as httplib - - -class TypeWithDefault(type): - def __init__(cls, name, bases, dct): - super(TypeWithDefault, cls).__init__(name, bases, dct) - cls._default = None - - def __call__(cls): - if cls._default is None: - cls._default = type.__call__(cls) - return copy.copy(cls._default) - - def set_default(cls, default): - cls._default = copy.copy(default) - - -class Configuration(six.with_metaclass(TypeWithDefault, object)): - """NOTE: This class is auto generated by the swagger code generator program. - - Ref: https://github.com/swagger-api/swagger-codegen - Do not edit the class manually. - """ - - def __init__(self): - """Constructor""" - # Default Base url - self.host = "https://app.asana.com/api/1.0" - # Temp file folder for downloading files - self.temp_folder_path = None - - # Authentication Settings - # dict to store API key(s) - self.api_key = {} - # dict to store API prefix (e.g. Bearer) - self.api_key_prefix = {} - # function to refresh API key if expired - self.refresh_api_key_hook = None - # Username for HTTP basic authentication - self.username = "" - # Password for HTTP basic authentication - self.password = "" - # access token for OAuth - self.access_token = "" - # Logging Settings - self.logger = {} - self.logger["package_logger"] = logging.getLogger("asana") - self.logger["urllib3_logger"] = logging.getLogger("urllib3") - # Log format - self.logger_format = '%(asctime)s %(levelname)s %(message)s' - # Log stream handler - self.logger_stream_handler = None - # Log file handler - self.logger_file_handler = None - # Debug file location - self.logger_file = None - # Debug switch - self.debug = False - - # SSL/TLS verification - # Set this to false to skip verifying SSL certificate when calling API - # from https server. - self.verify_ssl = True - # Set this to customize the certificate file to verify the peer. - self.ssl_ca_cert = None - # client certificate file - self.cert_file = None - # client key file - self.key_file = None - # Set this to True/False to enable/disable SSL hostname verification. - self.assert_hostname = None - - # urllib3 connection pool's maximum number of connections saved - # per pool. urllib3 uses 1 connection as default value, but this is - # not the best value when you are making a lot of possibly parallel - # requests to the same host, which is often the case here. - # cpu_count * 5 is used as default value to increase performance. - self.connection_pool_maxsize = multiprocessing.cpu_count() * 5 - - # Proxy URL - self.proxy = None - # Safe chars for path_param - self.safe_chars_for_path_param = '' - - @property - def logger_file(self): - """The logger file. - - If the logger_file is None, then add stream handler and remove file - handler. Otherwise, add file handler and remove stream handler. - - :param value: The logger_file path. - :type: str - """ - return self.__logger_file - - @logger_file.setter - def logger_file(self, value): - """The logger file. - - If the logger_file is None, then add stream handler and remove file - handler. Otherwise, add file handler and remove stream handler. - - :param value: The logger_file path. - :type: str - """ - self.__logger_file = value - if self.__logger_file: - # If set logging file, - # then add file handler and remove stream handler. - self.logger_file_handler = logging.FileHandler(self.__logger_file) - self.logger_file_handler.setFormatter(self.logger_formatter) - for _, logger in six.iteritems(self.logger): - logger.addHandler(self.logger_file_handler) - if self.logger_stream_handler: - logger.removeHandler(self.logger_stream_handler) - else: - # If not set logging file, - # then add stream handler and remove file handler. - self.logger_stream_handler = logging.StreamHandler() - self.logger_stream_handler.setFormatter(self.logger_formatter) - for _, logger in six.iteritems(self.logger): - logger.addHandler(self.logger_stream_handler) - if self.logger_file_handler: - logger.removeHandler(self.logger_file_handler) - - @property - def debug(self): - """Debug status - - :param value: The debug status, True or False. - :type: bool - """ - return self.__debug - - @debug.setter - def debug(self, value): - """Debug status - - :param value: The debug status, True or False. - :type: bool - """ - self.__debug = value - if self.__debug: - # if debug status is True, turn on debug logging - for _, logger in six.iteritems(self.logger): - logger.setLevel(logging.DEBUG) - # turn on httplib debug - httplib.HTTPConnection.debuglevel = 1 - else: - # if debug status is False, turn off debug logging, - # setting log level to default `logging.WARNING` - for _, logger in six.iteritems(self.logger): - logger.setLevel(logging.WARNING) - # turn off httplib debug - httplib.HTTPConnection.debuglevel = 0 - - @property - def logger_format(self): - """The logger format. - - The logger_formatter will be updated when sets logger_format. - - :param value: The format string. - :type: str - """ - return self.__logger_format - - @logger_format.setter - def logger_format(self, value): - """The logger format. - - The logger_formatter will be updated when sets logger_format. - - :param value: The format string. - :type: str - """ - self.__logger_format = value - self.logger_formatter = logging.Formatter(self.__logger_format) - - def get_api_key_with_prefix(self, identifier): - """Gets API key (with prefix if set). - - :param identifier: The identifier of apiKey. - :return: The token for api key authentication. - """ - if self.refresh_api_key_hook: - self.refresh_api_key_hook(self) - - key = self.api_key.get(identifier) - if key: - prefix = self.api_key_prefix.get(identifier) - if prefix: - return "%s %s" % (prefix, key) - else: - return key - - def get_basic_auth_token(self): - """Gets HTTP basic authentication header (string). - - :return: The token for basic HTTP authentication. - """ - return urllib3.util.make_headers( - basic_auth=self.username + ':' + self.password - ).get('authorization') - - def auth_settings(self): - """Gets Auth Settings dict for api client. - - :return: The Auth Settings information dict. - """ - return { - 'oauth2': - { - 'type': 'oauth2', - 'in': 'header', - 'key': 'Authorization', - 'value': 'Bearer ' + self.access_token - }, - } - - def to_debug_report(self): - """Gets the essential information for debugging. - - :return: The report for debugging. - """ - return "Python SDK Debug Report:\n"\ - "OS: {env}\n"\ - "Python Version: {pyversion}\n"\ - "Version of the API: 1.0\n"\ - "SDK Package Version: 4.0.11".\ - format(env=sys.platform, pyversion=sys.version) diff --git a/asana/error.py b/asana/error.py new file mode 100644 index 00000000..71902f80 --- /dev/null +++ b/asana/error.py @@ -0,0 +1,105 @@ +class AsanaError(Exception): + """Base Asana error class""" + def __init__(self, message=None, status=None, response=None): + try: + messages = [ + error['message'] for error in response.json()['errors']] + message = message + ': ' + '; '.join(messages) + except Exception: + pass + + super(AsanaError, self).__init__(message) + + self.status = status + self.response = response + self.message = message + + +class InvalidRequestError(AsanaError): + def __init__(self, response=None): + super(InvalidRequestError, self).__init__( + message='Invalid Request', + status=400, + response=response + ) + + +class NoAuthorizationError(AsanaError): + def __init__(self, response=None): + super(NoAuthorizationError, self).__init__( + message='No Authorization', + status=401, + response=response + ) + + +class PremiumOnlyError(AsanaError): + def __init__(self, response=None): + super(PremiumOnlyError, self).__init__( + message='Payment Required', + status=402, + response=response + ) + + +class ForbiddenError(AsanaError): + def __init__(self, response=None): + super(ForbiddenError, self).__init__( + message='Forbidden', + status=403, + response=response + ) + + +class NotFoundError(AsanaError): + def __init__(self, response=None): + super(NotFoundError, self).__init__( + message='Not Found', + status=404, + response=response + ) + + +class InvalidTokenError(AsanaError): + def __init__(self, response=None): + super(InvalidTokenError, self).__init__( + message='Sync token invalid or too old', + status=412, + response=response + ) + self.sync = response is not None and response.json()['sync'] + + +class RetryableAsanaError(AsanaError): + """Base class for retryable errors. + + Base class for errors which should trigger a retry (if configured to do + so). + + """ + def __init__(self, message=None, status=None, response=None): + super(RetryableAsanaError, self).__init__( + message=message, status=status, response=response) + + +class RateLimitEnforcedError(RetryableAsanaError): + def __init__(self, response=None): + super(RateLimitEnforcedError, self).__init__( + message='Rate Limit Enforced', + status=429, + response=response + ) + self.retry_after = ( + response is not None and float(response.headers['Retry-After'])) + + +class ServerError(RetryableAsanaError): + def __init__(self, response=None): + status = 500 + if response: + status = response.status + super(ServerError, self).__init__( + message='Server Error', + status=status, + response=response + ) diff --git a/asana/models/__init__.py b/asana/models/__init__.py deleted file mode 100644 index 9db3b9f2..00000000 --- a/asana/models/__init__.py +++ /dev/null @@ -1,452 +0,0 @@ -# coding: utf-8 - -# flake8: noqa -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -# import models into model package -from asana.models.add_custom_field_setting_request import AddCustomFieldSettingRequest -from asana.models.add_followers_request import AddFollowersRequest -from asana.models.add_members_request import AddMembersRequest -from asana.models.all_of_project_response_owner import AllOfProjectResponseOwner -from asana.models.all_of_project_template_base_owner import AllOfProjectTemplateBaseOwner -from asana.models.all_of_project_template_response_owner import AllOfProjectTemplateResponseOwner -from asana.models.all_of_story_response_new_date_value import AllOfStoryResponseNewDateValue -from asana.models.all_of_story_response_old_date_value import AllOfStoryResponseOldDateValue -from asana.models.all_of_task_template_response_created_by import AllOfTaskTemplateResponseCreatedBy -from asana.models.all_of_task_template_response_project import AllOfTaskTemplateResponseProject -from asana.models.all_of_task_template_response_template import AllOfTaskTemplateResponseTemplate -from asana.models.all_of_user_task_list_base_owner import AllOfUserTaskListBaseOwner -from asana.models.all_of_user_task_list_base_workspace import AllOfUserTaskListBaseWorkspace -from asana.models.all_of_user_task_list_compact_owner import AllOfUserTaskListCompactOwner -from asana.models.all_of_user_task_list_compact_workspace import AllOfUserTaskListCompactWorkspace -from asana.models.all_of_user_task_list_request_owner import AllOfUserTaskListRequestOwner -from asana.models.all_of_user_task_list_request_workspace import AllOfUserTaskListRequestWorkspace -from asana.models.all_of_user_task_list_response_owner import AllOfUserTaskListResponseOwner -from asana.models.all_of_user_task_list_response_workspace import AllOfUserTaskListResponseWorkspace -from asana.models.all_of_workspace_membership_response_user_task_list_owner import AllOfWorkspaceMembershipResponseUserTaskListOwner -from asana.models.all_of_workspace_membership_response_user_task_list_workspace import AllOfWorkspaceMembershipResponseUserTaskListWorkspace -from asana.models.asana_named_resource import AsanaNamedResource -from asana.models.asana_named_resource_array import AsanaNamedResourceArray -from asana.models.asana_resource import AsanaResource -from asana.models.attachment_base import AttachmentBase -from asana.models.attachment_compact import AttachmentCompact -from asana.models.attachment_request import AttachmentRequest -from asana.models.attachment_response import AttachmentResponse -from asana.models.attachment_response_array import AttachmentResponseArray -from asana.models.attachment_response_data import AttachmentResponseData -from asana.models.attachment_response_parent import AttachmentResponseParent -from asana.models.attachment_response_parent_created_by import AttachmentResponseParentCreatedBy -from asana.models.audit_log_event import AuditLogEvent -from asana.models.audit_log_event_actor import AuditLogEventActor -from asana.models.audit_log_event_array import AuditLogEventArray -from asana.models.audit_log_event_context import AuditLogEventContext -from asana.models.audit_log_event_details import AuditLogEventDetails -from asana.models.audit_log_event_resource import AuditLogEventResource -from asana.models.batch_body import BatchBody -from asana.models.batch_request import BatchRequest -from asana.models.batch_request_action import BatchRequestAction -from asana.models.batch_request_actions import BatchRequestActions -from asana.models.batch_request_options import BatchRequestOptions -from asana.models.batch_response import BatchResponse -from asana.models.batch_response_array import BatchResponseArray -from asana.models.create_membership_request import CreateMembershipRequest -from asana.models.create_time_tracking_entry_request import CreateTimeTrackingEntryRequest -from asana.models.custom_field_base import CustomFieldBase -from asana.models.custom_field_base_date_value import CustomFieldBaseDateValue -from asana.models.custom_field_base_enum_options import CustomFieldBaseEnumOptions -from asana.models.custom_field_base_enum_value import CustomFieldBaseEnumValue -from asana.models.custom_field_compact import CustomFieldCompact -from asana.models.custom_field_gid_enum_options_body import CustomFieldGidEnumOptionsBody -from asana.models.custom_field_request import CustomFieldRequest -from asana.models.custom_field_response import CustomFieldResponse -from asana.models.custom_field_response_array import CustomFieldResponseArray -from asana.models.custom_field_response_created_by import CustomFieldResponseCreatedBy -from asana.models.custom_field_response_data import CustomFieldResponseData -from asana.models.custom_field_response_people_value import CustomFieldResponsePeopleValue -from asana.models.custom_field_setting_base import CustomFieldSettingBase -from asana.models.custom_field_setting_compact import CustomFieldSettingCompact -from asana.models.custom_field_setting_response import CustomFieldSettingResponse -from asana.models.custom_field_setting_response_array import CustomFieldSettingResponseArray -from asana.models.custom_field_setting_response_custom_field import CustomFieldSettingResponseCustomField -from asana.models.custom_field_setting_response_data import CustomFieldSettingResponseData -from asana.models.custom_field_setting_response_parent import CustomFieldSettingResponseParent -from asana.models.custom_field_setting_response_project import CustomFieldSettingResponseProject -from asana.models.custom_fields_body import CustomFieldsBody -from asana.models.custom_fields_custom_field_gid_body import CustomFieldsCustomFieldGidBody -from asana.models.date_variable_compact import DateVariableCompact -from asana.models.date_variable_request import DateVariableRequest -from asana.models.empty_response import EmptyResponse -from asana.models.empty_response_data import EmptyResponseData -from asana.models.enum_option import EnumOption -from asana.models.enum_option_base import EnumOptionBase -from asana.models.enum_option_data import EnumOptionData -from asana.models.enum_option_insert_request import EnumOptionInsertRequest -from asana.models.enum_option_request import EnumOptionRequest -from asana.models.enum_options_enum_option_gid_body import EnumOptionsEnumOptionGidBody -from asana.models.enum_options_insert_body import EnumOptionsInsertBody -from asana.models.error import Error -from asana.models.error_response import ErrorResponse -from asana.models.error_response_errors import ErrorResponseErrors -from asana.models.event_response import EventResponse -from asana.models.event_response_array import EventResponseArray -from asana.models.event_response_change import EventResponseChange -from asana.models.event_response_parent import EventResponseParent -from asana.models.event_response_resource import EventResponseResource -from asana.models.event_response_user import EventResponseUser -from asana.models.goal_add_subgoal_request import GoalAddSubgoalRequest -from asana.models.goal_add_supporting_relationship_request import GoalAddSupportingRelationshipRequest -from asana.models.goal_add_supporting_work_request import GoalAddSupportingWorkRequest -from asana.models.goal_base import GoalBase -from asana.models.goal_compact import GoalCompact -from asana.models.goal_gid_add_followers_body import GoalGidAddFollowersBody -from asana.models.goal_gid_add_supporting_relationship_body import GoalGidAddSupportingRelationshipBody -from asana.models.goal_gid_remove_followers_body import GoalGidRemoveFollowersBody -from asana.models.goal_gid_remove_supporting_relationship_body import GoalGidRemoveSupportingRelationshipBody -from asana.models.goal_gid_set_metric_body import GoalGidSetMetricBody -from asana.models.goal_gid_set_metric_current_value_body import GoalGidSetMetricCurrentValueBody -from asana.models.goal_membership_base import GoalMembershipBase -from asana.models.goal_membership_compact import GoalMembershipCompact -from asana.models.goal_membership_response import GoalMembershipResponse -from asana.models.goal_membership_response_user import GoalMembershipResponseUser -from asana.models.goal_membership_response_workspace import GoalMembershipResponseWorkspace -from asana.models.goal_metric_base import GoalMetricBase -from asana.models.goal_metric_current_value_request import GoalMetricCurrentValueRequest -from asana.models.goal_metric_request import GoalMetricRequest -from asana.models.goal_relationship_base import GoalRelationshipBase -from asana.models.goal_relationship_base_supported_goal import GoalRelationshipBaseSupportedGoal -from asana.models.goal_relationship_base_supporting_resource import GoalRelationshipBaseSupportingResource -from asana.models.goal_relationship_compact import GoalRelationshipCompact -from asana.models.goal_relationship_request import GoalRelationshipRequest -from asana.models.goal_relationship_response import GoalRelationshipResponse -from asana.models.goal_relationship_response_array import GoalRelationshipResponseArray -from asana.models.goal_relationship_response_data import GoalRelationshipResponseData -from asana.models.goal_relationships_goal_relationship_gid_body import GoalRelationshipsGoalRelationshipGidBody -from asana.models.goal_remove_subgoal_request import GoalRemoveSubgoalRequest -from asana.models.goal_remove_supporting_relationship_request import GoalRemoveSupportingRelationshipRequest -from asana.models.goal_request import GoalRequest -from asana.models.goal_request_base import GoalRequestBase -from asana.models.goal_response import GoalResponse -from asana.models.goal_response_array import GoalResponseArray -from asana.models.goal_response_current_status_update import GoalResponseCurrentStatusUpdate -from asana.models.goal_response_data import GoalResponseData -from asana.models.goal_response_likes import GoalResponseLikes -from asana.models.goal_response_metric import GoalResponseMetric -from asana.models.goal_response_team import GoalResponseTeam -from asana.models.goal_response_time_period import GoalResponseTimePeriod -from asana.models.goal_response_workspace import GoalResponseWorkspace -from asana.models.goal_update_request import GoalUpdateRequest -from asana.models.goals_body import GoalsBody -from asana.models.goals_goal_gid_body import GoalsGoalGidBody -from asana.models.inline_response412 import InlineResponse412 -from asana.models.inline_response412_errors import InlineResponse412Errors -from asana.models.job_base import JobBase -from asana.models.job_base_new_project import JobBaseNewProject -from asana.models.job_base_new_project_template import JobBaseNewProjectTemplate -from asana.models.job_base_new_task import JobBaseNewTask -from asana.models.job_compact import JobCompact -from asana.models.job_response import JobResponse -from asana.models.job_response_data import JobResponseData -from asana.models.like import Like -from asana.models.member_compact import MemberCompact -from asana.models.membership_compact import MembershipCompact -from asana.models.membership_compact_goal import MembershipCompactGoal -from asana.models.membership_compact_member import MembershipCompactMember -from asana.models.membership_compact_parent import MembershipCompactParent -from asana.models.membership_request import MembershipRequest -from asana.models.membership_response import MembershipResponse -from asana.models.membership_response_array import MembershipResponseArray -from asana.models.membership_response_data import MembershipResponseData -from asana.models.memberships_body import MembershipsBody -from asana.models.modify_dependencies_request import ModifyDependenciesRequest -from asana.models.modify_dependents_request import ModifyDependentsRequest -from asana.models.next_page import NextPage -from asana.models.organization_export_base import OrganizationExportBase -from asana.models.organization_export_compact import OrganizationExportCompact -from asana.models.organization_export_request import OrganizationExportRequest -from asana.models.organization_export_response import OrganizationExportResponse -from asana.models.organization_export_response_data import OrganizationExportResponseData -from asana.models.organization_exports_body import OrganizationExportsBody -from asana.models.portfolio_add_item_request import PortfolioAddItemRequest -from asana.models.portfolio_base import PortfolioBase -from asana.models.portfolio_compact import PortfolioCompact -from asana.models.portfolio_gid_add_custom_field_setting_body import PortfolioGidAddCustomFieldSettingBody -from asana.models.portfolio_gid_add_item_body import PortfolioGidAddItemBody -from asana.models.portfolio_gid_add_members_body import PortfolioGidAddMembersBody -from asana.models.portfolio_gid_remove_custom_field_setting_body import PortfolioGidRemoveCustomFieldSettingBody -from asana.models.portfolio_gid_remove_item_body import PortfolioGidRemoveItemBody -from asana.models.portfolio_gid_remove_members_body import PortfolioGidRemoveMembersBody -from asana.models.portfolio_membership_base import PortfolioMembershipBase -from asana.models.portfolio_membership_base_portfolio import PortfolioMembershipBasePortfolio -from asana.models.portfolio_membership_compact import PortfolioMembershipCompact -from asana.models.portfolio_membership_response import PortfolioMembershipResponse -from asana.models.portfolio_membership_response_array import PortfolioMembershipResponseArray -from asana.models.portfolio_membership_response_data import PortfolioMembershipResponseData -from asana.models.portfolio_remove_item_request import PortfolioRemoveItemRequest -from asana.models.portfolio_request import PortfolioRequest -from asana.models.portfolio_response import PortfolioResponse -from asana.models.portfolio_response_array import PortfolioResponseArray -from asana.models.portfolio_response_current_status_update import PortfolioResponseCurrentStatusUpdate -from asana.models.portfolio_response_custom_field_settings import PortfolioResponseCustomFieldSettings -from asana.models.portfolio_response_custom_fields import PortfolioResponseCustomFields -from asana.models.portfolio_response_data import PortfolioResponseData -from asana.models.portfolio_response_workspace import PortfolioResponseWorkspace -from asana.models.portfolios_body import PortfoliosBody -from asana.models.portfolios_portfolio_gid_body import PortfoliosPortfolioGidBody -from asana.models.preview import Preview -from asana.models.project_base import ProjectBase -from asana.models.project_base_current_status import ProjectBaseCurrentStatus -from asana.models.project_base_current_status_update import ProjectBaseCurrentStatusUpdate -from asana.models.project_brief_base import ProjectBriefBase -from asana.models.project_brief_compact import ProjectBriefCompact -from asana.models.project_brief_request import ProjectBriefRequest -from asana.models.project_brief_response import ProjectBriefResponse -from asana.models.project_brief_response_data import ProjectBriefResponseData -from asana.models.project_brief_response_project import ProjectBriefResponseProject -from asana.models.project_briefs_project_brief_gid_body import ProjectBriefsProjectBriefGidBody -from asana.models.project_compact import ProjectCompact -from asana.models.project_duplicate_request import ProjectDuplicateRequest -from asana.models.project_duplicate_request_schedule_dates import ProjectDuplicateRequestScheduleDates -from asana.models.project_gid_add_custom_field_setting_body import ProjectGidAddCustomFieldSettingBody -from asana.models.project_gid_add_followers_body import ProjectGidAddFollowersBody -from asana.models.project_gid_add_members_body import ProjectGidAddMembersBody -from asana.models.project_gid_duplicate_body import ProjectGidDuplicateBody -from asana.models.project_gid_project_briefs_body import ProjectGidProjectBriefsBody -from asana.models.project_gid_project_statuses_body import ProjectGidProjectStatusesBody -from asana.models.project_gid_remove_custom_field_setting_body import ProjectGidRemoveCustomFieldSettingBody -from asana.models.project_gid_remove_followers_body import ProjectGidRemoveFollowersBody -from asana.models.project_gid_remove_members_body import ProjectGidRemoveMembersBody -from asana.models.project_gid_save_as_template_body import ProjectGidSaveAsTemplateBody -from asana.models.project_gid_sections_body import ProjectGidSectionsBody -from asana.models.project_membership_base import ProjectMembershipBase -from asana.models.project_membership_compact import ProjectMembershipCompact -from asana.models.project_membership_compact_array import ProjectMembershipCompactArray -from asana.models.project_membership_compact_response import ProjectMembershipCompactResponse -from asana.models.project_membership_compact_response_data import ProjectMembershipCompactResponseData -from asana.models.project_membership_normal_response import ProjectMembershipNormalResponse -from asana.models.project_membership_normal_response_data import ProjectMembershipNormalResponseData -from asana.models.project_request import ProjectRequest -from asana.models.project_response import ProjectResponse -from asana.models.project_response_array import ProjectResponseArray -from asana.models.project_response_completed_by import ProjectResponseCompletedBy -from asana.models.project_response_created_from_template import ProjectResponseCreatedFromTemplate -from asana.models.project_response_data import ProjectResponseData -from asana.models.project_response_project_brief import ProjectResponseProjectBrief -from asana.models.project_response_team import ProjectResponseTeam -from asana.models.project_response_workspace import ProjectResponseWorkspace -from asana.models.project_save_as_template_request import ProjectSaveAsTemplateRequest -from asana.models.project_section_insert_request import ProjectSectionInsertRequest -from asana.models.project_status_base import ProjectStatusBase -from asana.models.project_status_compact import ProjectStatusCompact -from asana.models.project_status_request import ProjectStatusRequest -from asana.models.project_status_response import ProjectStatusResponse -from asana.models.project_status_response_array import ProjectStatusResponseArray -from asana.models.project_status_response_data import ProjectStatusResponseData -from asana.models.project_template_base import ProjectTemplateBase -from asana.models.project_template_base_requested_dates import ProjectTemplateBaseRequestedDates -from asana.models.project_template_base_requested_roles import ProjectTemplateBaseRequestedRoles -from asana.models.project_template_base_team import ProjectTemplateBaseTeam -from asana.models.project_template_compact import ProjectTemplateCompact -from asana.models.project_template_gid_instantiate_project_body import ProjectTemplateGidInstantiateProjectBody -from asana.models.project_template_instantiate_project_request import ProjectTemplateInstantiateProjectRequest -from asana.models.project_template_instantiate_project_request_requested_dates import ProjectTemplateInstantiateProjectRequestRequestedDates -from asana.models.project_template_instantiate_project_request_requested_roles import ProjectTemplateInstantiateProjectRequestRequestedRoles -from asana.models.project_template_response import ProjectTemplateResponse -from asana.models.project_template_response_array import ProjectTemplateResponseArray -from asana.models.project_template_response_data import ProjectTemplateResponseData -from asana.models.project_update_request import ProjectUpdateRequest -from asana.models.projects_body import ProjectsBody -from asana.models.projects_project_gid_body import ProjectsProjectGidBody -from asana.models.remove_custom_field_setting_request import RemoveCustomFieldSettingRequest -from asana.models.remove_followers_request import RemoveFollowersRequest -from asana.models.remove_members_request import RemoveMembersRequest -from asana.models.requested_role_request import RequestedRoleRequest -from asana.models.rule_trigger_gid_run_body import RuleTriggerGidRunBody -from asana.models.rule_trigger_request import RuleTriggerRequest -from asana.models.rule_trigger_response import RuleTriggerResponse -from asana.models.rule_trigger_response_data import RuleTriggerResponseData -from asana.models.section_base import SectionBase -from asana.models.section_compact import SectionCompact -from asana.models.section_gid_add_task_body import SectionGidAddTaskBody -from asana.models.section_request import SectionRequest -from asana.models.section_response import SectionResponse -from asana.models.section_response_array import SectionResponseArray -from asana.models.section_response_data import SectionResponseData -from asana.models.section_task_insert_request import SectionTaskInsertRequest -from asana.models.sections_insert_body import SectionsInsertBody -from asana.models.sections_section_gid_body import SectionsSectionGidBody -from asana.models.status_update_base import StatusUpdateBase -from asana.models.status_update_compact import StatusUpdateCompact -from asana.models.status_update_request import StatusUpdateRequest -from asana.models.status_update_response import StatusUpdateResponse -from asana.models.status_update_response_array import StatusUpdateResponseArray -from asana.models.status_update_response_data import StatusUpdateResponseData -from asana.models.status_update_response_parent import StatusUpdateResponseParent -from asana.models.status_updates_body import StatusUpdatesBody -from asana.models.stories_story_gid_body import StoriesStoryGidBody -from asana.models.story_base import StoryBase -from asana.models.story_compact import StoryCompact -from asana.models.story_request import StoryRequest -from asana.models.story_response import StoryResponse -from asana.models.story_response_array import StoryResponseArray -from asana.models.story_response_assignee import StoryResponseAssignee -from asana.models.story_response_custom_field import StoryResponseCustomField -from asana.models.story_response_data import StoryResponseData -from asana.models.story_response_dates import StoryResponseDates -from asana.models.story_response_old_dates import StoryResponseOldDates -from asana.models.story_response_old_enum_value import StoryResponseOldEnumValue -from asana.models.story_response_old_section import StoryResponseOldSection -from asana.models.story_response_previews import StoryResponsePreviews -from asana.models.story_response_project import StoryResponseProject -from asana.models.story_response_story import StoryResponseStory -from asana.models.story_response_tag import StoryResponseTag -from asana.models.story_response_target import StoryResponseTarget -from asana.models.story_response_task import StoryResponseTask -from asana.models.tag_base import TagBase -from asana.models.tag_compact import TagCompact -from asana.models.tag_create_tag_for_workspace_request import TagCreateTagForWorkspaceRequest -from asana.models.tag_request import TagRequest -from asana.models.tag_response import TagResponse -from asana.models.tag_response_array import TagResponseArray -from asana.models.tag_response_data import TagResponseData -from asana.models.tags_body import TagsBody -from asana.models.task_add_followers_request import TaskAddFollowersRequest -from asana.models.task_add_project_request import TaskAddProjectRequest -from asana.models.task_add_tag_request import TaskAddTagRequest -from asana.models.task_base import TaskBase -from asana.models.task_base_completed_by import TaskBaseCompletedBy -from asana.models.task_base_dependencies import TaskBaseDependencies -from asana.models.task_base_external import TaskBaseExternal -from asana.models.task_base_memberships import TaskBaseMemberships -from asana.models.task_base_section import TaskBaseSection -from asana.models.task_compact import TaskCompact -from asana.models.task_count_response import TaskCountResponse -from asana.models.task_count_response_data import TaskCountResponseData -from asana.models.task_duplicate_request import TaskDuplicateRequest -from asana.models.task_gid_add_dependencies_body import TaskGidAddDependenciesBody -from asana.models.task_gid_add_dependents_body import TaskGidAddDependentsBody -from asana.models.task_gid_add_followers_body import TaskGidAddFollowersBody -from asana.models.task_gid_add_project_body import TaskGidAddProjectBody -from asana.models.task_gid_add_tag_body import TaskGidAddTagBody -from asana.models.task_gid_duplicate_body import TaskGidDuplicateBody -from asana.models.task_gid_remove_dependencies_body import TaskGidRemoveDependenciesBody -from asana.models.task_gid_remove_dependents_body import TaskGidRemoveDependentsBody -from asana.models.task_gid_remove_followers_body import TaskGidRemoveFollowersBody -from asana.models.task_gid_remove_project_body import TaskGidRemoveProjectBody -from asana.models.task_gid_remove_tag_body import TaskGidRemoveTagBody -from asana.models.task_gid_set_parent_body import TaskGidSetParentBody -from asana.models.task_gid_stories_body import TaskGidStoriesBody -from asana.models.task_gid_subtasks_body import TaskGidSubtasksBody -from asana.models.task_gid_time_tracking_entries_body import TaskGidTimeTrackingEntriesBody -from asana.models.task_remove_followers_request import TaskRemoveFollowersRequest -from asana.models.task_remove_project_request import TaskRemoveProjectRequest -from asana.models.task_remove_tag_request import TaskRemoveTagRequest -from asana.models.task_request import TaskRequest -from asana.models.task_response import TaskResponse -from asana.models.task_response_array import TaskResponseArray -from asana.models.task_response_assignee_section import TaskResponseAssigneeSection -from asana.models.task_response_custom_fields import TaskResponseCustomFields -from asana.models.task_response_data import TaskResponseData -from asana.models.task_response_parent import TaskResponseParent -from asana.models.task_response_tags import TaskResponseTags -from asana.models.task_response_workspace import TaskResponseWorkspace -from asana.models.task_set_parent_request import TaskSetParentRequest -from asana.models.task_template_base import TaskTemplateBase -from asana.models.task_template_compact import TaskTemplateCompact -from asana.models.task_template_gid_instantiate_task_body import TaskTemplateGidInstantiateTaskBody -from asana.models.task_template_instantiate_task_request import TaskTemplateInstantiateTaskRequest -from asana.models.task_template_recipe import TaskTemplateRecipe -from asana.models.task_template_recipe_attachments import TaskTemplateRecipeAttachments -from asana.models.task_template_recipe_compact import TaskTemplateRecipeCompact -from asana.models.task_template_recipe_dependencies import TaskTemplateRecipeDependencies -from asana.models.task_template_response import TaskTemplateResponse -from asana.models.task_template_response_array import TaskTemplateResponseArray -from asana.models.task_template_response_data import TaskTemplateResponseData -from asana.models.tasks_body import TasksBody -from asana.models.tasks_task_gid_body import TasksTaskGidBody -from asana.models.team_add_user_request import TeamAddUserRequest -from asana.models.team_base import TeamBase -from asana.models.team_compact import TeamCompact -from asana.models.team_gid_add_user_body import TeamGidAddUserBody -from asana.models.team_gid_projects_body import TeamGidProjectsBody -from asana.models.team_gid_remove_user_body import TeamGidRemoveUserBody -from asana.models.team_membership_base import TeamMembershipBase -from asana.models.team_membership_compact import TeamMembershipCompact -from asana.models.team_membership_response import TeamMembershipResponse -from asana.models.team_membership_response_array import TeamMembershipResponseArray -from asana.models.team_membership_response_data import TeamMembershipResponseData -from asana.models.team_remove_user_request import TeamRemoveUserRequest -from asana.models.team_request import TeamRequest -from asana.models.team_response import TeamResponse -from asana.models.team_response_array import TeamResponseArray -from asana.models.team_response_data import TeamResponseData -from asana.models.team_response_organization import TeamResponseOrganization -from asana.models.teams_body import TeamsBody -from asana.models.teams_team_gid_body import TeamsTeamGidBody -from asana.models.template_role import TemplateRole -from asana.models.time_period_base import TimePeriodBase -from asana.models.time_period_compact import TimePeriodCompact -from asana.models.time_period_response import TimePeriodResponse -from asana.models.time_period_response_array import TimePeriodResponseArray -from asana.models.time_period_response_data import TimePeriodResponseData -from asana.models.time_tracking_entries_time_tracking_entry_gid_body import TimeTrackingEntriesTimeTrackingEntryGidBody -from asana.models.time_tracking_entry_base import TimeTrackingEntryBase -from asana.models.time_tracking_entry_base_data import TimeTrackingEntryBaseData -from asana.models.time_tracking_entry_compact import TimeTrackingEntryCompact -from asana.models.time_tracking_entry_compact_array import TimeTrackingEntryCompactArray -from asana.models.update_time_tracking_entry_request import UpdateTimeTrackingEntryRequest -from asana.models.user_base import UserBase -from asana.models.user_base_response import UserBaseResponse -from asana.models.user_base_response_data import UserBaseResponseData -from asana.models.user_base_response_photo import UserBaseResponsePhoto -from asana.models.user_compact import UserCompact -from asana.models.user_request import UserRequest -from asana.models.user_response import UserResponse -from asana.models.user_response_array import UserResponseArray -from asana.models.user_response_data import UserResponseData -from asana.models.user_task_list_base import UserTaskListBase -from asana.models.user_task_list_compact import UserTaskListCompact -from asana.models.user_task_list_request import UserTaskListRequest -from asana.models.user_task_list_response import UserTaskListResponse -from asana.models.user_task_list_response_data import UserTaskListResponseData -from asana.models.webhook_compact import WebhookCompact -from asana.models.webhook_compact_resource import WebhookCompactResource -from asana.models.webhook_filter import WebhookFilter -from asana.models.webhook_request import WebhookRequest -from asana.models.webhook_request_filters import WebhookRequestFilters -from asana.models.webhook_response import WebhookResponse -from asana.models.webhook_response_array import WebhookResponseArray -from asana.models.webhook_response_data import WebhookResponseData -from asana.models.webhook_update_request import WebhookUpdateRequest -from asana.models.webhooks_body import WebhooksBody -from asana.models.webhooks_webhook_gid_body import WebhooksWebhookGidBody -from asana.models.workspace_add_user_request import WorkspaceAddUserRequest -from asana.models.workspace_base import WorkspaceBase -from asana.models.workspace_compact import WorkspaceCompact -from asana.models.workspace_gid_add_user_body import WorkspaceGidAddUserBody -from asana.models.workspace_gid_projects_body import WorkspaceGidProjectsBody -from asana.models.workspace_gid_remove_user_body import WorkspaceGidRemoveUserBody -from asana.models.workspace_gid_tags_body import WorkspaceGidTagsBody -from asana.models.workspace_membership_base import WorkspaceMembershipBase -from asana.models.workspace_membership_compact import WorkspaceMembershipCompact -from asana.models.workspace_membership_request import WorkspaceMembershipRequest -from asana.models.workspace_membership_response import WorkspaceMembershipResponse -from asana.models.workspace_membership_response_array import WorkspaceMembershipResponseArray -from asana.models.workspace_membership_response_data import WorkspaceMembershipResponseData -from asana.models.workspace_membership_response_user_task_list import WorkspaceMembershipResponseUserTaskList -from asana.models.workspace_membership_response_vacation_dates import WorkspaceMembershipResponseVacationDates -from asana.models.workspace_remove_user_request import WorkspaceRemoveUserRequest -from asana.models.workspace_request import WorkspaceRequest -from asana.models.workspace_response import WorkspaceResponse -from asana.models.workspace_response_array import WorkspaceResponseArray -from asana.models.workspace_response_data import WorkspaceResponseData -from asana.models.workspaces_workspace_gid_body import WorkspacesWorkspaceGidBody diff --git a/asana/models/add_custom_field_setting_request.py b/asana/models/add_custom_field_setting_request.py deleted file mode 100644 index 1b7a6abb..00000000 --- a/asana/models/add_custom_field_setting_request.py +++ /dev/null @@ -1,197 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AddCustomFieldSettingRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'custom_field': 'str', - 'is_important': 'bool', - 'insert_before': 'str', - 'insert_after': 'str' - } - - attribute_map = { - 'custom_field': 'custom_field', - 'is_important': 'is_important', - 'insert_before': 'insert_before', - 'insert_after': 'insert_after' - } - - def __init__(self, custom_field=None, is_important=None, insert_before=None, insert_after=None): # noqa: E501 - """AddCustomFieldSettingRequest - a model defined in Swagger""" # noqa: E501 - self._custom_field = None - self._is_important = None - self._insert_before = None - self._insert_after = None - self.discriminator = None - self.custom_field = custom_field - if is_important is not None: - self.is_important = is_important - if insert_before is not None: - self.insert_before = insert_before - if insert_after is not None: - self.insert_after = insert_after - - @property - def custom_field(self): - """Gets the custom_field of this AddCustomFieldSettingRequest. # noqa: E501 - - The custom field to associate with this container. # noqa: E501 - - :return: The custom_field of this AddCustomFieldSettingRequest. # noqa: E501 - :rtype: str - """ - return self._custom_field - - @custom_field.setter - def custom_field(self, custom_field): - """Sets the custom_field of this AddCustomFieldSettingRequest. - - The custom field to associate with this container. # noqa: E501 - - :param custom_field: The custom_field of this AddCustomFieldSettingRequest. # noqa: E501 - :type: str - """ - if custom_field is None: - raise ValueError("Invalid value for `custom_field`, must not be `None`") # noqa: E501 - - self._custom_field = custom_field - - @property - def is_important(self): - """Gets the is_important of this AddCustomFieldSettingRequest. # noqa: E501 - - Whether this field should be considered important to this container (for instance, to display in the list view of items in the container). # noqa: E501 - - :return: The is_important of this AddCustomFieldSettingRequest. # noqa: E501 - :rtype: bool - """ - return self._is_important - - @is_important.setter - def is_important(self, is_important): - """Sets the is_important of this AddCustomFieldSettingRequest. - - Whether this field should be considered important to this container (for instance, to display in the list view of items in the container). # noqa: E501 - - :param is_important: The is_important of this AddCustomFieldSettingRequest. # noqa: E501 - :type: bool - """ - - self._is_important = is_important - - @property - def insert_before(self): - """Gets the insert_before of this AddCustomFieldSettingRequest. # noqa: E501 - - A gid of a Custom Field Setting on this container, before which the new Custom Field Setting will be added. `insert_before` and `insert_after` parameters cannot both be specified. # noqa: E501 - - :return: The insert_before of this AddCustomFieldSettingRequest. # noqa: E501 - :rtype: str - """ - return self._insert_before - - @insert_before.setter - def insert_before(self, insert_before): - """Sets the insert_before of this AddCustomFieldSettingRequest. - - A gid of a Custom Field Setting on this container, before which the new Custom Field Setting will be added. `insert_before` and `insert_after` parameters cannot both be specified. # noqa: E501 - - :param insert_before: The insert_before of this AddCustomFieldSettingRequest. # noqa: E501 - :type: str - """ - - self._insert_before = insert_before - - @property - def insert_after(self): - """Gets the insert_after of this AddCustomFieldSettingRequest. # noqa: E501 - - A gid of a Custom Field Setting on this container, after which the new Custom Field Setting will be added. `insert_before` and `insert_after` parameters cannot both be specified. # noqa: E501 - - :return: The insert_after of this AddCustomFieldSettingRequest. # noqa: E501 - :rtype: str - """ - return self._insert_after - - @insert_after.setter - def insert_after(self, insert_after): - """Sets the insert_after of this AddCustomFieldSettingRequest. - - A gid of a Custom Field Setting on this container, after which the new Custom Field Setting will be added. `insert_before` and `insert_after` parameters cannot both be specified. # noqa: E501 - - :param insert_after: The insert_after of this AddCustomFieldSettingRequest. # noqa: E501 - :type: str - """ - - self._insert_after = insert_after - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AddCustomFieldSettingRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AddCustomFieldSettingRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/add_followers_request.py b/asana/models/add_followers_request.py deleted file mode 100644 index ee2872bc..00000000 --- a/asana/models/add_followers_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AddFollowersRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'followers': 'str' - } - - attribute_map = { - 'followers': 'followers' - } - - def __init__(self, followers=None): # noqa: E501 - """AddFollowersRequest - a model defined in Swagger""" # noqa: E501 - self._followers = None - self.discriminator = None - self.followers = followers - - @property - def followers(self): - """Gets the followers of this AddFollowersRequest. # noqa: E501 - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :return: The followers of this AddFollowersRequest. # noqa: E501 - :rtype: str - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this AddFollowersRequest. - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :param followers: The followers of this AddFollowersRequest. # noqa: E501 - :type: str - """ - if followers is None: - raise ValueError("Invalid value for `followers`, must not be `None`") # noqa: E501 - - self._followers = followers - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AddFollowersRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AddFollowersRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/add_members_request.py b/asana/models/add_members_request.py deleted file mode 100644 index 7dd6f87e..00000000 --- a/asana/models/add_members_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AddMembersRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'members': 'str' - } - - attribute_map = { - 'members': 'members' - } - - def __init__(self, members=None): # noqa: E501 - """AddMembersRequest - a model defined in Swagger""" # noqa: E501 - self._members = None - self.discriminator = None - self.members = members - - @property - def members(self): - """Gets the members of this AddMembersRequest. # noqa: E501 - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :return: The members of this AddMembersRequest. # noqa: E501 - :rtype: str - """ - return self._members - - @members.setter - def members(self, members): - """Sets the members of this AddMembersRequest. - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :param members: The members of this AddMembersRequest. # noqa: E501 - :type: str - """ - if members is None: - raise ValueError("Invalid value for `members`, must not be `None`") # noqa: E501 - - self._members = members - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AddMembersRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AddMembersRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_project_response_owner.py b/asana/models/all_of_project_response_owner.py deleted file mode 100644 index 3fe0079c..00000000 --- a/asana/models/all_of_project_response_owner.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfProjectResponseOwner(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfProjectResponseOwner - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfProjectResponseOwner, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfProjectResponseOwner): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_project_template_base_owner.py b/asana/models/all_of_project_template_base_owner.py deleted file mode 100644 index 7d3a96a1..00000000 --- a/asana/models/all_of_project_template_base_owner.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfProjectTemplateBaseOwner(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfProjectTemplateBaseOwner - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfProjectTemplateBaseOwner, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfProjectTemplateBaseOwner): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_project_template_response_owner.py b/asana/models/all_of_project_template_response_owner.py deleted file mode 100644 index dcf91c24..00000000 --- a/asana/models/all_of_project_template_response_owner.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfProjectTemplateResponseOwner(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfProjectTemplateResponseOwner - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfProjectTemplateResponseOwner, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfProjectTemplateResponseOwner): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_story_response_new_date_value.py b/asana/models/all_of_story_response_new_date_value.py deleted file mode 100644 index 7181da21..00000000 --- a/asana/models/all_of_story_response_new_date_value.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfStoryResponseNewDateValue(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfStoryResponseNewDateValue - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfStoryResponseNewDateValue, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfStoryResponseNewDateValue): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_story_response_old_date_value.py b/asana/models/all_of_story_response_old_date_value.py deleted file mode 100644 index bb0a6a24..00000000 --- a/asana/models/all_of_story_response_old_date_value.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfStoryResponseOldDateValue(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfStoryResponseOldDateValue - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfStoryResponseOldDateValue, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfStoryResponseOldDateValue): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_task_template_response_created_by.py b/asana/models/all_of_task_template_response_created_by.py deleted file mode 100644 index 4ce34a34..00000000 --- a/asana/models/all_of_task_template_response_created_by.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfTaskTemplateResponseCreatedBy(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfTaskTemplateResponseCreatedBy - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfTaskTemplateResponseCreatedBy, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfTaskTemplateResponseCreatedBy): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_task_template_response_project.py b/asana/models/all_of_task_template_response_project.py deleted file mode 100644 index ae53b6c6..00000000 --- a/asana/models/all_of_task_template_response_project.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfTaskTemplateResponseProject(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfTaskTemplateResponseProject - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfTaskTemplateResponseProject, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfTaskTemplateResponseProject): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_task_template_response_template.py b/asana/models/all_of_task_template_response_template.py deleted file mode 100644 index 8981e930..00000000 --- a/asana/models/all_of_task_template_response_template.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfTaskTemplateResponseTemplate(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfTaskTemplateResponseTemplate - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfTaskTemplateResponseTemplate, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfTaskTemplateResponseTemplate): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_user_task_list_base_owner.py b/asana/models/all_of_user_task_list_base_owner.py deleted file mode 100644 index 322c1af4..00000000 --- a/asana/models/all_of_user_task_list_base_owner.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfUserTaskListBaseOwner(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfUserTaskListBaseOwner - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfUserTaskListBaseOwner, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfUserTaskListBaseOwner): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_user_task_list_base_workspace.py b/asana/models/all_of_user_task_list_base_workspace.py deleted file mode 100644 index 6e6193b2..00000000 --- a/asana/models/all_of_user_task_list_base_workspace.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfUserTaskListBaseWorkspace(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfUserTaskListBaseWorkspace - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfUserTaskListBaseWorkspace, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfUserTaskListBaseWorkspace): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_user_task_list_compact_owner.py b/asana/models/all_of_user_task_list_compact_owner.py deleted file mode 100644 index a36f855b..00000000 --- a/asana/models/all_of_user_task_list_compact_owner.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfUserTaskListCompactOwner(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfUserTaskListCompactOwner - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfUserTaskListCompactOwner, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfUserTaskListCompactOwner): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_user_task_list_compact_workspace.py b/asana/models/all_of_user_task_list_compact_workspace.py deleted file mode 100644 index 65517b42..00000000 --- a/asana/models/all_of_user_task_list_compact_workspace.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfUserTaskListCompactWorkspace(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfUserTaskListCompactWorkspace - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfUserTaskListCompactWorkspace, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfUserTaskListCompactWorkspace): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_user_task_list_request_owner.py b/asana/models/all_of_user_task_list_request_owner.py deleted file mode 100644 index e8d240f2..00000000 --- a/asana/models/all_of_user_task_list_request_owner.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfUserTaskListRequestOwner(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfUserTaskListRequestOwner - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfUserTaskListRequestOwner, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfUserTaskListRequestOwner): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_user_task_list_request_workspace.py b/asana/models/all_of_user_task_list_request_workspace.py deleted file mode 100644 index 9d9a821d..00000000 --- a/asana/models/all_of_user_task_list_request_workspace.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfUserTaskListRequestWorkspace(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfUserTaskListRequestWorkspace - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfUserTaskListRequestWorkspace, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfUserTaskListRequestWorkspace): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_user_task_list_response_owner.py b/asana/models/all_of_user_task_list_response_owner.py deleted file mode 100644 index 1c81ecad..00000000 --- a/asana/models/all_of_user_task_list_response_owner.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfUserTaskListResponseOwner(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfUserTaskListResponseOwner - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfUserTaskListResponseOwner, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfUserTaskListResponseOwner): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_user_task_list_response_workspace.py b/asana/models/all_of_user_task_list_response_workspace.py deleted file mode 100644 index b0659f7d..00000000 --- a/asana/models/all_of_user_task_list_response_workspace.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfUserTaskListResponseWorkspace(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfUserTaskListResponseWorkspace - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfUserTaskListResponseWorkspace, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfUserTaskListResponseWorkspace): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_workspace_membership_response_user_task_list_owner.py b/asana/models/all_of_workspace_membership_response_user_task_list_owner.py deleted file mode 100644 index d5345f76..00000000 --- a/asana/models/all_of_workspace_membership_response_user_task_list_owner.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfWorkspaceMembershipResponseUserTaskListOwner(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfWorkspaceMembershipResponseUserTaskListOwner - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfWorkspaceMembershipResponseUserTaskListOwner, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfWorkspaceMembershipResponseUserTaskListOwner): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/all_of_workspace_membership_response_user_task_list_workspace.py b/asana/models/all_of_workspace_membership_response_user_task_list_workspace.py deleted file mode 100644 index 9025f3eb..00000000 --- a/asana/models/all_of_workspace_membership_response_user_task_list_workspace.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AllOfWorkspaceMembershipResponseUserTaskListWorkspace(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AllOfWorkspaceMembershipResponseUserTaskListWorkspace - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AllOfWorkspaceMembershipResponseUserTaskListWorkspace, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AllOfWorkspaceMembershipResponseUserTaskListWorkspace): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/asana_named_resource.py b/asana/models/asana_named_resource.py deleted file mode 100644 index 1de183b7..00000000 --- a/asana/models/asana_named_resource.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AsanaNamedResource(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """AsanaNamedResource - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this AsanaNamedResource. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this AsanaNamedResource. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this AsanaNamedResource. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this AsanaNamedResource. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this AsanaNamedResource. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this AsanaNamedResource. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this AsanaNamedResource. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this AsanaNamedResource. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this AsanaNamedResource. # noqa: E501 - - The name of the object. # noqa: E501 - - :return: The name of this AsanaNamedResource. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this AsanaNamedResource. - - The name of the object. # noqa: E501 - - :param name: The name of this AsanaNamedResource. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AsanaNamedResource, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AsanaNamedResource): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/asana_named_resource_array.py b/asana/models/asana_named_resource_array.py deleted file mode 100644 index ea81d30c..00000000 --- a/asana/models/asana_named_resource_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AsanaNamedResourceArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[AsanaNamedResource]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """AsanaNamedResourceArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this AsanaNamedResourceArray. # noqa: E501 - - - :return: The data of this AsanaNamedResourceArray. # noqa: E501 - :rtype: list[AsanaNamedResource] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this AsanaNamedResourceArray. - - - :param data: The data of this AsanaNamedResourceArray. # noqa: E501 - :type: list[AsanaNamedResource] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this AsanaNamedResourceArray. # noqa: E501 - - - :return: The next_page of this AsanaNamedResourceArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this AsanaNamedResourceArray. - - - :param next_page: The next_page of this AsanaNamedResourceArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AsanaNamedResourceArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AsanaNamedResourceArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/asana_resource.py b/asana/models/asana_resource.py deleted file mode 100644 index 198e8419..00000000 --- a/asana/models/asana_resource.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AsanaResource(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type' - } - - def __init__(self, gid=None, resource_type=None): # noqa: E501 - """AsanaResource - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - - @property - def gid(self): - """Gets the gid of this AsanaResource. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this AsanaResource. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this AsanaResource. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this AsanaResource. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this AsanaResource. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this AsanaResource. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this AsanaResource. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this AsanaResource. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AsanaResource, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AsanaResource): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/attachment_base.py b/asana/models/attachment_base.py deleted file mode 100644 index 907cfc28..00000000 --- a/asana/models/attachment_base.py +++ /dev/null @@ -1,196 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AttachmentBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None): # noqa: E501 - """AttachmentBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - - @property - def gid(self): - """Gets the gid of this AttachmentBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this AttachmentBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this AttachmentBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this AttachmentBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this AttachmentBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this AttachmentBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this AttachmentBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this AttachmentBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this AttachmentBase. # noqa: E501 - - The name of the file. # noqa: E501 - - :return: The name of this AttachmentBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this AttachmentBase. - - The name of the file. # noqa: E501 - - :param name: The name of this AttachmentBase. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this AttachmentBase. # noqa: E501 - - The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `onedrive`, `box`, `vimeo`, and `external`. # noqa: E501 - - :return: The resource_subtype of this AttachmentBase. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this AttachmentBase. - - The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `onedrive`, `box`, `vimeo`, and `external`. # noqa: E501 - - :param resource_subtype: The resource_subtype of this AttachmentBase. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AttachmentBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AttachmentBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/attachment_compact.py b/asana/models/attachment_compact.py deleted file mode 100644 index 03d0d4d6..00000000 --- a/asana/models/attachment_compact.py +++ /dev/null @@ -1,196 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AttachmentCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None): # noqa: E501 - """AttachmentCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - - @property - def gid(self): - """Gets the gid of this AttachmentCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this AttachmentCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this AttachmentCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this AttachmentCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this AttachmentCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this AttachmentCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this AttachmentCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this AttachmentCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this AttachmentCompact. # noqa: E501 - - The name of the file. # noqa: E501 - - :return: The name of this AttachmentCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this AttachmentCompact. - - The name of the file. # noqa: E501 - - :param name: The name of this AttachmentCompact. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this AttachmentCompact. # noqa: E501 - - The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `onedrive`, `box`, `vimeo`, and `external`. # noqa: E501 - - :return: The resource_subtype of this AttachmentCompact. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this AttachmentCompact. - - The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `onedrive`, `box`, `vimeo`, and `external`. # noqa: E501 - - :param resource_subtype: The resource_subtype of this AttachmentCompact. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AttachmentCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AttachmentCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/attachment_request.py b/asana/models/attachment_request.py deleted file mode 100644 index 0802c20e..00000000 --- a/asana/models/attachment_request.py +++ /dev/null @@ -1,259 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AttachmentRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'resource_subtype': 'str', - 'file': 'str', - 'parent': 'str', - 'url': 'str', - 'name': 'str', - 'connect_to_app': 'bool' - } - - attribute_map = { - 'resource_subtype': 'resource_subtype', - 'file': 'file', - 'parent': 'parent', - 'url': 'url', - 'name': 'name', - 'connect_to_app': 'connect_to_app' - } - - def __init__(self, resource_subtype=None, file=None, parent=None, url=None, name=None, connect_to_app=None): # noqa: E501 - """AttachmentRequest - a model defined in Swagger""" # noqa: E501 - self._resource_subtype = None - self._file = None - self._parent = None - self._url = None - self._name = None - self._connect_to_app = None - self.discriminator = None - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if file is not None: - self.file = file - self.parent = parent - if url is not None: - self.url = url - if name is not None: - self.name = name - if connect_to_app is not None: - self.connect_to_app = connect_to_app - - @property - def resource_subtype(self): - """Gets the resource_subtype of this AttachmentRequest. # noqa: E501 - - The type of the attachment. Must be one of the given values. If not specified, a file attachment of type `asana` will be assumed. Note that if the value of `resource_subtype` is `external`, a `parent`, `name`, and `url` must also be provided. # noqa: E501 - - :return: The resource_subtype of this AttachmentRequest. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this AttachmentRequest. - - The type of the attachment. Must be one of the given values. If not specified, a file attachment of type `asana` will be assumed. Note that if the value of `resource_subtype` is `external`, a `parent`, `name`, and `url` must also be provided. # noqa: E501 - - :param resource_subtype: The resource_subtype of this AttachmentRequest. # noqa: E501 - :type: str - """ - allowed_values = ["asana", "dropbox", "gdrive", "onedrive", "box", "vimeo", "external"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def file(self): - """Gets the file of this AttachmentRequest. # noqa: E501 - - Required for `asana` attachments. # noqa: E501 - - :return: The file of this AttachmentRequest. # noqa: E501 - :rtype: str - """ - return self._file - - @file.setter - def file(self, file): - """Sets the file of this AttachmentRequest. - - Required for `asana` attachments. # noqa: E501 - - :param file: The file of this AttachmentRequest. # noqa: E501 - :type: str - """ - - self._file = file - - @property - def parent(self): - """Gets the parent of this AttachmentRequest. # noqa: E501 - - Required identifier of the parent task, project, or project_brief, as a string. # noqa: E501 - - :return: The parent of this AttachmentRequest. # noqa: E501 - :rtype: str - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this AttachmentRequest. - - Required identifier of the parent task, project, or project_brief, as a string. # noqa: E501 - - :param parent: The parent of this AttachmentRequest. # noqa: E501 - :type: str - """ - if parent is None: - raise ValueError("Invalid value for `parent`, must not be `None`") # noqa: E501 - - self._parent = parent - - @property - def url(self): - """Gets the url of this AttachmentRequest. # noqa: E501 - - The URL of the external resource being attached. Required for attachments of type `external`. # noqa: E501 - - :return: The url of this AttachmentRequest. # noqa: E501 - :rtype: str - """ - return self._url - - @url.setter - def url(self, url): - """Sets the url of this AttachmentRequest. - - The URL of the external resource being attached. Required for attachments of type `external`. # noqa: E501 - - :param url: The url of this AttachmentRequest. # noqa: E501 - :type: str - """ - - self._url = url - - @property - def name(self): - """Gets the name of this AttachmentRequest. # noqa: E501 - - The name of the external resource being attached. Required for attachments of type `external`. # noqa: E501 - - :return: The name of this AttachmentRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this AttachmentRequest. - - The name of the external resource being attached. Required for attachments of type `external`. # noqa: E501 - - :param name: The name of this AttachmentRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def connect_to_app(self): - """Gets the connect_to_app of this AttachmentRequest. # noqa: E501 - - *Optional*. Only relevant for external attachments with a parent task. A boolean indicating whether the current app should be connected with the attachment for the purposes of showing an app components widget. Requires the app to have been added to a project the parent task is in. # noqa: E501 - - :return: The connect_to_app of this AttachmentRequest. # noqa: E501 - :rtype: bool - """ - return self._connect_to_app - - @connect_to_app.setter - def connect_to_app(self, connect_to_app): - """Sets the connect_to_app of this AttachmentRequest. - - *Optional*. Only relevant for external attachments with a parent task. A boolean indicating whether the current app should be connected with the attachment for the purposes of showing an app components widget. Requires the app to have been added to a project the parent task is in. # noqa: E501 - - :param connect_to_app: The connect_to_app of this AttachmentRequest. # noqa: E501 - :type: bool - """ - - self._connect_to_app = connect_to_app - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AttachmentRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AttachmentRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/attachment_response.py b/asana/models/attachment_response.py deleted file mode 100644 index 7edda7ab..00000000 --- a/asana/models/attachment_response.py +++ /dev/null @@ -1,416 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AttachmentResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'created_at': 'datetime', - 'download_url': 'str', - 'permanent_url': 'str', - 'host': 'str', - 'parent': 'AttachmentResponseParent', - 'size': 'int', - 'view_url': 'str', - 'connected_to_app': 'bool' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'created_at': 'created_at', - 'download_url': 'download_url', - 'permanent_url': 'permanent_url', - 'host': 'host', - 'parent': 'parent', - 'size': 'size', - 'view_url': 'view_url', - 'connected_to_app': 'connected_to_app' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, created_at=None, download_url=None, permanent_url=None, host=None, parent=None, size=None, view_url=None, connected_to_app=None): # noqa: E501 - """AttachmentResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._created_at = None - self._download_url = None - self._permanent_url = None - self._host = None - self._parent = None - self._size = None - self._view_url = None - self._connected_to_app = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if created_at is not None: - self.created_at = created_at - if download_url is not None: - self.download_url = download_url - if permanent_url is not None: - self.permanent_url = permanent_url - if host is not None: - self.host = host - if parent is not None: - self.parent = parent - if size is not None: - self.size = size - if view_url is not None: - self.view_url = view_url - if connected_to_app is not None: - self.connected_to_app = connected_to_app - - @property - def gid(self): - """Gets the gid of this AttachmentResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this AttachmentResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this AttachmentResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this AttachmentResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this AttachmentResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this AttachmentResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this AttachmentResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this AttachmentResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this AttachmentResponse. # noqa: E501 - - The name of the file. # noqa: E501 - - :return: The name of this AttachmentResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this AttachmentResponse. - - The name of the file. # noqa: E501 - - :param name: The name of this AttachmentResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this AttachmentResponse. # noqa: E501 - - The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `onedrive`, `box`, `vimeo`, and `external`. # noqa: E501 - - :return: The resource_subtype of this AttachmentResponse. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this AttachmentResponse. - - The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `onedrive`, `box`, `vimeo`, and `external`. # noqa: E501 - - :param resource_subtype: The resource_subtype of this AttachmentResponse. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def created_at(self): - """Gets the created_at of this AttachmentResponse. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this AttachmentResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this AttachmentResponse. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this AttachmentResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def download_url(self): - """Gets the download_url of this AttachmentResponse. # noqa: E501 - - The URL containing the content of the attachment. *Note:* May be null if the attachment is hosted by [Box](https://www.box.com/) and will be null if the attachment is a Video Message hosted by [Vimeo](https://vimeo.com/). If present, this URL may only be valid for two minutes from the time of retrieval. You should avoid persisting this URL somewhere and just refresh it on demand to ensure you do not keep stale URLs. # noqa: E501 - - :return: The download_url of this AttachmentResponse. # noqa: E501 - :rtype: str - """ - return self._download_url - - @download_url.setter - def download_url(self, download_url): - """Sets the download_url of this AttachmentResponse. - - The URL containing the content of the attachment. *Note:* May be null if the attachment is hosted by [Box](https://www.box.com/) and will be null if the attachment is a Video Message hosted by [Vimeo](https://vimeo.com/). If present, this URL may only be valid for two minutes from the time of retrieval. You should avoid persisting this URL somewhere and just refresh it on demand to ensure you do not keep stale URLs. # noqa: E501 - - :param download_url: The download_url of this AttachmentResponse. # noqa: E501 - :type: str - """ - - self._download_url = download_url - - @property - def permanent_url(self): - """Gets the permanent_url of this AttachmentResponse. # noqa: E501 - - - :return: The permanent_url of this AttachmentResponse. # noqa: E501 - :rtype: str - """ - return self._permanent_url - - @permanent_url.setter - def permanent_url(self, permanent_url): - """Sets the permanent_url of this AttachmentResponse. - - - :param permanent_url: The permanent_url of this AttachmentResponse. # noqa: E501 - :type: str - """ - - self._permanent_url = permanent_url - - @property - def host(self): - """Gets the host of this AttachmentResponse. # noqa: E501 - - The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `box`, and `vimeo`. # noqa: E501 - - :return: The host of this AttachmentResponse. # noqa: E501 - :rtype: str - """ - return self._host - - @host.setter - def host(self, host): - """Sets the host of this AttachmentResponse. - - The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `box`, and `vimeo`. # noqa: E501 - - :param host: The host of this AttachmentResponse. # noqa: E501 - :type: str - """ - - self._host = host - - @property - def parent(self): - """Gets the parent of this AttachmentResponse. # noqa: E501 - - - :return: The parent of this AttachmentResponse. # noqa: E501 - :rtype: AttachmentResponseParent - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this AttachmentResponse. - - - :param parent: The parent of this AttachmentResponse. # noqa: E501 - :type: AttachmentResponseParent - """ - - self._parent = parent - - @property - def size(self): - """Gets the size of this AttachmentResponse. # noqa: E501 - - The size of the attachment in bytes. Only present when the `resource_subtype` is `asana`. # noqa: E501 - - :return: The size of this AttachmentResponse. # noqa: E501 - :rtype: int - """ - return self._size - - @size.setter - def size(self, size): - """Sets the size of this AttachmentResponse. - - The size of the attachment in bytes. Only present when the `resource_subtype` is `asana`. # noqa: E501 - - :param size: The size of this AttachmentResponse. # noqa: E501 - :type: int - """ - - self._size = size - - @property - def view_url(self): - """Gets the view_url of this AttachmentResponse. # noqa: E501 - - The URL where the attachment can be viewed, which may be friendlier to users in a browser than just directing them to a raw file. May be null if no view URL exists for the service. # noqa: E501 - - :return: The view_url of this AttachmentResponse. # noqa: E501 - :rtype: str - """ - return self._view_url - - @view_url.setter - def view_url(self, view_url): - """Sets the view_url of this AttachmentResponse. - - The URL where the attachment can be viewed, which may be friendlier to users in a browser than just directing them to a raw file. May be null if no view URL exists for the service. # noqa: E501 - - :param view_url: The view_url of this AttachmentResponse. # noqa: E501 - :type: str - """ - - self._view_url = view_url - - @property - def connected_to_app(self): - """Gets the connected_to_app of this AttachmentResponse. # noqa: E501 - - Whether the attachment is connected to the app making the request for the purposes of showing an app components widget. Only present when the `resource_subtype` is `external` or `gdrive`. # noqa: E501 - - :return: The connected_to_app of this AttachmentResponse. # noqa: E501 - :rtype: bool - """ - return self._connected_to_app - - @connected_to_app.setter - def connected_to_app(self, connected_to_app): - """Sets the connected_to_app of this AttachmentResponse. - - Whether the attachment is connected to the app making the request for the purposes of showing an app components widget. Only present when the `resource_subtype` is `external` or `gdrive`. # noqa: E501 - - :param connected_to_app: The connected_to_app of this AttachmentResponse. # noqa: E501 - :type: bool - """ - - self._connected_to_app = connected_to_app - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AttachmentResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AttachmentResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/attachment_response_array.py b/asana/models/attachment_response_array.py deleted file mode 100644 index 7cc6a682..00000000 --- a/asana/models/attachment_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AttachmentResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[AttachmentResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """AttachmentResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this AttachmentResponseArray. # noqa: E501 - - - :return: The data of this AttachmentResponseArray. # noqa: E501 - :rtype: list[AttachmentResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this AttachmentResponseArray. - - - :param data: The data of this AttachmentResponseArray. # noqa: E501 - :type: list[AttachmentResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this AttachmentResponseArray. # noqa: E501 - - - :return: The next_page of this AttachmentResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this AttachmentResponseArray. - - - :param next_page: The next_page of this AttachmentResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AttachmentResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AttachmentResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/attachment_response_data.py b/asana/models/attachment_response_data.py deleted file mode 100644 index 5b1666a9..00000000 --- a/asana/models/attachment_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AttachmentResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'AttachmentResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """AttachmentResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this AttachmentResponseData. # noqa: E501 - - - :return: The data of this AttachmentResponseData. # noqa: E501 - :rtype: AttachmentResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this AttachmentResponseData. - - - :param data: The data of this AttachmentResponseData. # noqa: E501 - :type: AttachmentResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AttachmentResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AttachmentResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/attachment_response_parent.py b/asana/models/attachment_response_parent.py deleted file mode 100644 index f575b956..00000000 --- a/asana/models/attachment_response_parent.py +++ /dev/null @@ -1,222 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AttachmentResponseParent(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'created_by': 'AttachmentResponseParentCreatedBy' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'created_by': 'created_by' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, created_by=None): # noqa: E501 - """AttachmentResponseParent - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._created_by = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if created_by is not None: - self.created_by = created_by - - @property - def gid(self): - """Gets the gid of this AttachmentResponseParent. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this AttachmentResponseParent. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this AttachmentResponseParent. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this AttachmentResponseParent. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this AttachmentResponseParent. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this AttachmentResponseParent. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this AttachmentResponseParent. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this AttachmentResponseParent. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this AttachmentResponseParent. # noqa: E501 - - The name of the task. # noqa: E501 - - :return: The name of this AttachmentResponseParent. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this AttachmentResponseParent. - - The name of the task. # noqa: E501 - - :param name: The name of this AttachmentResponseParent. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this AttachmentResponseParent. # noqa: E501 - - The resource subtype of the parent resource that the filter applies to. # noqa: E501 - - :return: The resource_subtype of this AttachmentResponseParent. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this AttachmentResponseParent. - - The resource subtype of the parent resource that the filter applies to. # noqa: E501 - - :param resource_subtype: The resource_subtype of this AttachmentResponseParent. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def created_by(self): - """Gets the created_by of this AttachmentResponseParent. # noqa: E501 - - - :return: The created_by of this AttachmentResponseParent. # noqa: E501 - :rtype: AttachmentResponseParentCreatedBy - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this AttachmentResponseParent. - - - :param created_by: The created_by of this AttachmentResponseParent. # noqa: E501 - :type: AttachmentResponseParentCreatedBy - """ - - self._created_by = created_by - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AttachmentResponseParent, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AttachmentResponseParent): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/attachment_response_parent_created_by.py b/asana/models/attachment_response_parent_created_by.py deleted file mode 100644 index 3bf4ca1a..00000000 --- a/asana/models/attachment_response_parent_created_by.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AttachmentResponseParentCreatedBy(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type' - } - - def __init__(self, gid=None, resource_type=None): # noqa: E501 - """AttachmentResponseParentCreatedBy - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - - @property - def gid(self): - """Gets the gid of this AttachmentResponseParentCreatedBy. # noqa: E501 - - Globally unique identifier of the resource. # noqa: E501 - - :return: The gid of this AttachmentResponseParentCreatedBy. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this AttachmentResponseParentCreatedBy. - - Globally unique identifier of the resource. # noqa: E501 - - :param gid: The gid of this AttachmentResponseParentCreatedBy. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this AttachmentResponseParentCreatedBy. # noqa: E501 - - The type of resource. # noqa: E501 - - :return: The resource_type of this AttachmentResponseParentCreatedBy. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this AttachmentResponseParentCreatedBy. - - The type of resource. # noqa: E501 - - :param resource_type: The resource_type of this AttachmentResponseParentCreatedBy. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AttachmentResponseParentCreatedBy, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AttachmentResponseParentCreatedBy): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/audit_log_event.py b/asana/models/audit_log_event.py deleted file mode 100644 index bb94b187..00000000 --- a/asana/models/audit_log_event.py +++ /dev/null @@ -1,302 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AuditLogEvent(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'created_at': 'datetime', - 'event_type': 'str', - 'event_category': 'str', - 'actor': 'AuditLogEventActor', - 'resource': 'AuditLogEventResource', - 'details': 'object', - 'context': 'AuditLogEventContext' - } - - attribute_map = { - 'gid': 'gid', - 'created_at': 'created_at', - 'event_type': 'event_type', - 'event_category': 'event_category', - 'actor': 'actor', - 'resource': 'resource', - 'details': 'details', - 'context': 'context' - } - - def __init__(self, gid=None, created_at=None, event_type=None, event_category=None, actor=None, resource=None, details=None, context=None): # noqa: E501 - """AuditLogEvent - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._created_at = None - self._event_type = None - self._event_category = None - self._actor = None - self._resource = None - self._details = None - self._context = None - self.discriminator = None - if gid is not None: - self.gid = gid - if created_at is not None: - self.created_at = created_at - if event_type is not None: - self.event_type = event_type - if event_category is not None: - self.event_category = event_category - if actor is not None: - self.actor = actor - if resource is not None: - self.resource = resource - if details is not None: - self.details = details - if context is not None: - self.context = context - - @property - def gid(self): - """Gets the gid of this AuditLogEvent. # noqa: E501 - - Globally unique identifier of the `AuditLogEvent`, as a string. # noqa: E501 - - :return: The gid of this AuditLogEvent. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this AuditLogEvent. - - Globally unique identifier of the `AuditLogEvent`, as a string. # noqa: E501 - - :param gid: The gid of this AuditLogEvent. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def created_at(self): - """Gets the created_at of this AuditLogEvent. # noqa: E501 - - The time the event was created. # noqa: E501 - - :return: The created_at of this AuditLogEvent. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this AuditLogEvent. - - The time the event was created. # noqa: E501 - - :param created_at: The created_at of this AuditLogEvent. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def event_type(self): - """Gets the event_type of this AuditLogEvent. # noqa: E501 - - The type of the event. # noqa: E501 - - :return: The event_type of this AuditLogEvent. # noqa: E501 - :rtype: str - """ - return self._event_type - - @event_type.setter - def event_type(self, event_type): - """Sets the event_type of this AuditLogEvent. - - The type of the event. # noqa: E501 - - :param event_type: The event_type of this AuditLogEvent. # noqa: E501 - :type: str - """ - - self._event_type = event_type - - @property - def event_category(self): - """Gets the event_category of this AuditLogEvent. # noqa: E501 - - The category that this `event_type` belongs to. # noqa: E501 - - :return: The event_category of this AuditLogEvent. # noqa: E501 - :rtype: str - """ - return self._event_category - - @event_category.setter - def event_category(self, event_category): - """Sets the event_category of this AuditLogEvent. - - The category that this `event_type` belongs to. # noqa: E501 - - :param event_category: The event_category of this AuditLogEvent. # noqa: E501 - :type: str - """ - - self._event_category = event_category - - @property - def actor(self): - """Gets the actor of this AuditLogEvent. # noqa: E501 - - - :return: The actor of this AuditLogEvent. # noqa: E501 - :rtype: AuditLogEventActor - """ - return self._actor - - @actor.setter - def actor(self, actor): - """Sets the actor of this AuditLogEvent. - - - :param actor: The actor of this AuditLogEvent. # noqa: E501 - :type: AuditLogEventActor - """ - - self._actor = actor - - @property - def resource(self): - """Gets the resource of this AuditLogEvent. # noqa: E501 - - - :return: The resource of this AuditLogEvent. # noqa: E501 - :rtype: AuditLogEventResource - """ - return self._resource - - @resource.setter - def resource(self, resource): - """Sets the resource of this AuditLogEvent. - - - :param resource: The resource of this AuditLogEvent. # noqa: E501 - :type: AuditLogEventResource - """ - - self._resource = resource - - @property - def details(self): - """Gets the details of this AuditLogEvent. # noqa: E501 - - Event specific details. The schema will vary depending on the `event_type`. # noqa: E501 - - :return: The details of this AuditLogEvent. # noqa: E501 - :rtype: object - """ - return self._details - - @details.setter - def details(self, details): - """Sets the details of this AuditLogEvent. - - Event specific details. The schema will vary depending on the `event_type`. # noqa: E501 - - :param details: The details of this AuditLogEvent. # noqa: E501 - :type: object - """ - - self._details = details - - @property - def context(self): - """Gets the context of this AuditLogEvent. # noqa: E501 - - - :return: The context of this AuditLogEvent. # noqa: E501 - :rtype: AuditLogEventContext - """ - return self._context - - @context.setter - def context(self, context): - """Sets the context of this AuditLogEvent. - - - :param context: The context of this AuditLogEvent. # noqa: E501 - :type: AuditLogEventContext - """ - - self._context = context - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AuditLogEvent, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AuditLogEvent): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/audit_log_event_actor.py b/asana/models/audit_log_event_actor.py deleted file mode 100644 index 1c73c0a0..00000000 --- a/asana/models/audit_log_event_actor.py +++ /dev/null @@ -1,202 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AuditLogEventActor(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'actor_type': 'str', - 'gid': 'str', - 'name': 'str', - 'email': 'str' - } - - attribute_map = { - 'actor_type': 'actor_type', - 'gid': 'gid', - 'name': 'name', - 'email': 'email' - } - - def __init__(self, actor_type=None, gid=None, name=None, email=None): # noqa: E501 - """AuditLogEventActor - a model defined in Swagger""" # noqa: E501 - self._actor_type = None - self._gid = None - self._name = None - self._email = None - self.discriminator = None - if actor_type is not None: - self.actor_type = actor_type - if gid is not None: - self.gid = gid - if name is not None: - self.name = name - if email is not None: - self.email = email - - @property - def actor_type(self): - """Gets the actor_type of this AuditLogEventActor. # noqa: E501 - - The type of actor. Can be one of `user`, `asana`, `asana_support`, `anonymous`, or `external_administrator`. # noqa: E501 - - :return: The actor_type of this AuditLogEventActor. # noqa: E501 - :rtype: str - """ - return self._actor_type - - @actor_type.setter - def actor_type(self, actor_type): - """Sets the actor_type of this AuditLogEventActor. - - The type of actor. Can be one of `user`, `asana`, `asana_support`, `anonymous`, or `external_administrator`. # noqa: E501 - - :param actor_type: The actor_type of this AuditLogEventActor. # noqa: E501 - :type: str - """ - allowed_values = ["user", "asana", "asana_support", "anonymous", "external_administrator"] # noqa: E501 - if actor_type not in allowed_values: - raise ValueError( - "Invalid value for `actor_type` ({0}), must be one of {1}" # noqa: E501 - .format(actor_type, allowed_values) - ) - - self._actor_type = actor_type - - @property - def gid(self): - """Gets the gid of this AuditLogEventActor. # noqa: E501 - - Globally unique identifier of the actor, if it is a user. # noqa: E501 - - :return: The gid of this AuditLogEventActor. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this AuditLogEventActor. - - Globally unique identifier of the actor, if it is a user. # noqa: E501 - - :param gid: The gid of this AuditLogEventActor. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def name(self): - """Gets the name of this AuditLogEventActor. # noqa: E501 - - The name of the actor, if it is a user. # noqa: E501 - - :return: The name of this AuditLogEventActor. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this AuditLogEventActor. - - The name of the actor, if it is a user. # noqa: E501 - - :param name: The name of this AuditLogEventActor. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def email(self): - """Gets the email of this AuditLogEventActor. # noqa: E501 - - The email of the actor, if it is a user. # noqa: E501 - - :return: The email of this AuditLogEventActor. # noqa: E501 - :rtype: str - """ - return self._email - - @email.setter - def email(self, email): - """Sets the email of this AuditLogEventActor. - - The email of the actor, if it is a user. # noqa: E501 - - :param email: The email of this AuditLogEventActor. # noqa: E501 - :type: str - """ - - self._email = email - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AuditLogEventActor, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AuditLogEventActor): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/audit_log_event_array.py b/asana/models/audit_log_event_array.py deleted file mode 100644 index d205ac14..00000000 --- a/asana/models/audit_log_event_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AuditLogEventArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[AuditLogEvent]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """AuditLogEventArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this AuditLogEventArray. # noqa: E501 - - - :return: The data of this AuditLogEventArray. # noqa: E501 - :rtype: list[AuditLogEvent] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this AuditLogEventArray. - - - :param data: The data of this AuditLogEventArray. # noqa: E501 - :type: list[AuditLogEvent] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this AuditLogEventArray. # noqa: E501 - - - :return: The next_page of this AuditLogEventArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this AuditLogEventArray. - - - :param next_page: The next_page of this AuditLogEventArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AuditLogEventArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AuditLogEventArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/audit_log_event_context.py b/asana/models/audit_log_event_context.py deleted file mode 100644 index 4119c375..00000000 --- a/asana/models/audit_log_event_context.py +++ /dev/null @@ -1,236 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AuditLogEventContext(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'context_type': 'str', - 'api_authentication_method': 'str', - 'client_ip_address': 'str', - 'user_agent': 'str', - 'oauth_app_name': 'str' - } - - attribute_map = { - 'context_type': 'context_type', - 'api_authentication_method': 'api_authentication_method', - 'client_ip_address': 'client_ip_address', - 'user_agent': 'user_agent', - 'oauth_app_name': 'oauth_app_name' - } - - def __init__(self, context_type=None, api_authentication_method=None, client_ip_address=None, user_agent=None, oauth_app_name=None): # noqa: E501 - """AuditLogEventContext - a model defined in Swagger""" # noqa: E501 - self._context_type = None - self._api_authentication_method = None - self._client_ip_address = None - self._user_agent = None - self._oauth_app_name = None - self.discriminator = None - if context_type is not None: - self.context_type = context_type - if api_authentication_method is not None: - self.api_authentication_method = api_authentication_method - if client_ip_address is not None: - self.client_ip_address = client_ip_address - if user_agent is not None: - self.user_agent = user_agent - if oauth_app_name is not None: - self.oauth_app_name = oauth_app_name - - @property - def context_type(self): - """Gets the context_type of this AuditLogEventContext. # noqa: E501 - - The type of context. Can be one of `web`, `desktop`, `mobile`, `asana_support`, `asana`, `email`, or `api`. # noqa: E501 - - :return: The context_type of this AuditLogEventContext. # noqa: E501 - :rtype: str - """ - return self._context_type - - @context_type.setter - def context_type(self, context_type): - """Sets the context_type of this AuditLogEventContext. - - The type of context. Can be one of `web`, `desktop`, `mobile`, `asana_support`, `asana`, `email`, or `api`. # noqa: E501 - - :param context_type: The context_type of this AuditLogEventContext. # noqa: E501 - :type: str - """ - allowed_values = ["web", "desktop", "mobile", "asana_support", "asana", "email", "api"] # noqa: E501 - if context_type not in allowed_values: - raise ValueError( - "Invalid value for `context_type` ({0}), must be one of {1}" # noqa: E501 - .format(context_type, allowed_values) - ) - - self._context_type = context_type - - @property - def api_authentication_method(self): - """Gets the api_authentication_method of this AuditLogEventContext. # noqa: E501 - - The authentication method used in the context of an API request. Only present if the `context_type` is `api`. Can be one of `cookie`, `oauth`, `personal_access_token`, or `service_account`. # noqa: E501 - - :return: The api_authentication_method of this AuditLogEventContext. # noqa: E501 - :rtype: str - """ - return self._api_authentication_method - - @api_authentication_method.setter - def api_authentication_method(self, api_authentication_method): - """Sets the api_authentication_method of this AuditLogEventContext. - - The authentication method used in the context of an API request. Only present if the `context_type` is `api`. Can be one of `cookie`, `oauth`, `personal_access_token`, or `service_account`. # noqa: E501 - - :param api_authentication_method: The api_authentication_method of this AuditLogEventContext. # noqa: E501 - :type: str - """ - allowed_values = ["cookie", "oauth", "personal_access_token", "service_account"] # noqa: E501 - if api_authentication_method not in allowed_values: - raise ValueError( - "Invalid value for `api_authentication_method` ({0}), must be one of {1}" # noqa: E501 - .format(api_authentication_method, allowed_values) - ) - - self._api_authentication_method = api_authentication_method - - @property - def client_ip_address(self): - """Gets the client_ip_address of this AuditLogEventContext. # noqa: E501 - - The IP address of the client that initiated the event, if applicable. # noqa: E501 - - :return: The client_ip_address of this AuditLogEventContext. # noqa: E501 - :rtype: str - """ - return self._client_ip_address - - @client_ip_address.setter - def client_ip_address(self, client_ip_address): - """Sets the client_ip_address of this AuditLogEventContext. - - The IP address of the client that initiated the event, if applicable. # noqa: E501 - - :param client_ip_address: The client_ip_address of this AuditLogEventContext. # noqa: E501 - :type: str - """ - - self._client_ip_address = client_ip_address - - @property - def user_agent(self): - """Gets the user_agent of this AuditLogEventContext. # noqa: E501 - - The user agent of the client that initiated the event, if applicable. # noqa: E501 - - :return: The user_agent of this AuditLogEventContext. # noqa: E501 - :rtype: str - """ - return self._user_agent - - @user_agent.setter - def user_agent(self, user_agent): - """Sets the user_agent of this AuditLogEventContext. - - The user agent of the client that initiated the event, if applicable. # noqa: E501 - - :param user_agent: The user_agent of this AuditLogEventContext. # noqa: E501 - :type: str - """ - - self._user_agent = user_agent - - @property - def oauth_app_name(self): - """Gets the oauth_app_name of this AuditLogEventContext. # noqa: E501 - - The name of the OAuth App that initiated the event. Only present if the `api_authentication_method` is `oauth`. # noqa: E501 - - :return: The oauth_app_name of this AuditLogEventContext. # noqa: E501 - :rtype: str - """ - return self._oauth_app_name - - @oauth_app_name.setter - def oauth_app_name(self, oauth_app_name): - """Sets the oauth_app_name of this AuditLogEventContext. - - The name of the OAuth App that initiated the event. Only present if the `api_authentication_method` is `oauth`. # noqa: E501 - - :param oauth_app_name: The oauth_app_name of this AuditLogEventContext. # noqa: E501 - :type: str - """ - - self._oauth_app_name = oauth_app_name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AuditLogEventContext, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AuditLogEventContext): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/audit_log_event_details.py b/asana/models/audit_log_event_details.py deleted file mode 100644 index aef33ae0..00000000 --- a/asana/models/audit_log_event_details.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AuditLogEventDetails(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """AuditLogEventDetails - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AuditLogEventDetails, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AuditLogEventDetails): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/audit_log_event_resource.py b/asana/models/audit_log_event_resource.py deleted file mode 100644 index 8ed18679..00000000 --- a/asana/models/audit_log_event_resource.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class AuditLogEventResource(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'resource_type': 'str', - 'resource_subtype': 'str', - 'gid': 'str', - 'name': 'str', - 'email': 'str' - } - - attribute_map = { - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'gid': 'gid', - 'name': 'name', - 'email': 'email' - } - - def __init__(self, resource_type=None, resource_subtype=None, gid=None, name=None, email=None): # noqa: E501 - """AuditLogEventResource - a model defined in Swagger""" # noqa: E501 - self._resource_type = None - self._resource_subtype = None - self._gid = None - self._name = None - self._email = None - self.discriminator = None - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if gid is not None: - self.gid = gid - if name is not None: - self.name = name - if email is not None: - self.email = email - - @property - def resource_type(self): - """Gets the resource_type of this AuditLogEventResource. # noqa: E501 - - The type of resource. # noqa: E501 - - :return: The resource_type of this AuditLogEventResource. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this AuditLogEventResource. - - The type of resource. # noqa: E501 - - :param resource_type: The resource_type of this AuditLogEventResource. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this AuditLogEventResource. # noqa: E501 - - The subtype of resource. Most resources will not have a subtype. # noqa: E501 - - :return: The resource_subtype of this AuditLogEventResource. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this AuditLogEventResource. - - The subtype of resource. Most resources will not have a subtype. # noqa: E501 - - :param resource_subtype: The resource_subtype of this AuditLogEventResource. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def gid(self): - """Gets the gid of this AuditLogEventResource. # noqa: E501 - - Globally unique identifier of the resource. # noqa: E501 - - :return: The gid of this AuditLogEventResource. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this AuditLogEventResource. - - Globally unique identifier of the resource. # noqa: E501 - - :param gid: The gid of this AuditLogEventResource. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def name(self): - """Gets the name of this AuditLogEventResource. # noqa: E501 - - The name of the resource. # noqa: E501 - - :return: The name of this AuditLogEventResource. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this AuditLogEventResource. - - The name of the resource. # noqa: E501 - - :param name: The name of this AuditLogEventResource. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def email(self): - """Gets the email of this AuditLogEventResource. # noqa: E501 - - The email of the resource, if applicable. # noqa: E501 - - :return: The email of this AuditLogEventResource. # noqa: E501 - :rtype: str - """ - return self._email - - @email.setter - def email(self, email): - """Sets the email of this AuditLogEventResource. - - The email of the resource, if applicable. # noqa: E501 - - :param email: The email of this AuditLogEventResource. # noqa: E501 - :type: str - """ - - self._email = email - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(AuditLogEventResource, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, AuditLogEventResource): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/batch_body.py b/asana/models/batch_body.py deleted file mode 100644 index 6d89636e..00000000 --- a/asana/models/batch_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class BatchBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'BatchRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """BatchBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this BatchBody. # noqa: E501 - - - :return: The data of this BatchBody. # noqa: E501 - :rtype: BatchRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this BatchBody. - - - :param data: The data of this BatchBody. # noqa: E501 - :type: BatchRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(BatchBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, BatchBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/batch_request.py b/asana/models/batch_request.py deleted file mode 100644 index e3ef5bcc..00000000 --- a/asana/models/batch_request.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class BatchRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'actions': 'list[BatchRequestActions]' - } - - attribute_map = { - 'actions': 'actions' - } - - def __init__(self, actions=None): # noqa: E501 - """BatchRequest - a model defined in Swagger""" # noqa: E501 - self._actions = None - self.discriminator = None - if actions is not None: - self.actions = actions - - @property - def actions(self): - """Gets the actions of this BatchRequest. # noqa: E501 - - - :return: The actions of this BatchRequest. # noqa: E501 - :rtype: list[BatchRequestActions] - """ - return self._actions - - @actions.setter - def actions(self, actions): - """Sets the actions of this BatchRequest. - - - :param actions: The actions of this BatchRequest. # noqa: E501 - :type: list[BatchRequestActions] - """ - - self._actions = actions - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(BatchRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, BatchRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/batch_request_action.py b/asana/models/batch_request_action.py deleted file mode 100644 index c06b8121..00000000 --- a/asana/models/batch_request_action.py +++ /dev/null @@ -1,202 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class BatchRequestAction(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'relative_path': 'str', - 'method': 'str', - 'data': 'object', - 'options': 'BatchRequestOptions' - } - - attribute_map = { - 'relative_path': 'relative_path', - 'method': 'method', - 'data': 'data', - 'options': 'options' - } - - def __init__(self, relative_path=None, method=None, data=None, options=None): # noqa: E501 - """BatchRequestAction - a model defined in Swagger""" # noqa: E501 - self._relative_path = None - self._method = None - self._data = None - self._options = None - self.discriminator = None - self.relative_path = relative_path - self.method = method - if data is not None: - self.data = data - if options is not None: - self.options = options - - @property - def relative_path(self): - """Gets the relative_path of this BatchRequestAction. # noqa: E501 - - The path of the desired endpoint relative to the API’s base URL. Query parameters are not accepted here; put them in `data` instead. # noqa: E501 - - :return: The relative_path of this BatchRequestAction. # noqa: E501 - :rtype: str - """ - return self._relative_path - - @relative_path.setter - def relative_path(self, relative_path): - """Sets the relative_path of this BatchRequestAction. - - The path of the desired endpoint relative to the API’s base URL. Query parameters are not accepted here; put them in `data` instead. # noqa: E501 - - :param relative_path: The relative_path of this BatchRequestAction. # noqa: E501 - :type: str - """ - if relative_path is None: - raise ValueError("Invalid value for `relative_path`, must not be `None`") # noqa: E501 - - self._relative_path = relative_path - - @property - def method(self): - """Gets the method of this BatchRequestAction. # noqa: E501 - - The HTTP method you wish to emulate for the action. # noqa: E501 - - :return: The method of this BatchRequestAction. # noqa: E501 - :rtype: str - """ - return self._method - - @method.setter - def method(self, method): - """Sets the method of this BatchRequestAction. - - The HTTP method you wish to emulate for the action. # noqa: E501 - - :param method: The method of this BatchRequestAction. # noqa: E501 - :type: str - """ - if method is None: - raise ValueError("Invalid value for `method`, must not be `None`") # noqa: E501 - allowed_values = ["get", "post", "put", "delete", "patch", "head"] # noqa: E501 - if method not in allowed_values: - raise ValueError( - "Invalid value for `method` ({0}), must be one of {1}" # noqa: E501 - .format(method, allowed_values) - ) - - self._method = method - - @property - def data(self): - """Gets the data of this BatchRequestAction. # noqa: E501 - - For `GET` requests, this should be a map of query parameters you would have normally passed in the URL. Options and pagination are not accepted here; put them in `options` instead. For `POST`, `PATCH`, and `PUT` methods, this should be the content you would have normally put in the data field of the body. # noqa: E501 - - :return: The data of this BatchRequestAction. # noqa: E501 - :rtype: object - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this BatchRequestAction. - - For `GET` requests, this should be a map of query parameters you would have normally passed in the URL. Options and pagination are not accepted here; put them in `options` instead. For `POST`, `PATCH`, and `PUT` methods, this should be the content you would have normally put in the data field of the body. # noqa: E501 - - :param data: The data of this BatchRequestAction. # noqa: E501 - :type: object - """ - - self._data = data - - @property - def options(self): - """Gets the options of this BatchRequestAction. # noqa: E501 - - - :return: The options of this BatchRequestAction. # noqa: E501 - :rtype: BatchRequestOptions - """ - return self._options - - @options.setter - def options(self, options): - """Sets the options of this BatchRequestAction. - - - :param options: The options of this BatchRequestAction. # noqa: E501 - :type: BatchRequestOptions - """ - - self._options = options - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(BatchRequestAction, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, BatchRequestAction): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/batch_request_actions.py b/asana/models/batch_request_actions.py deleted file mode 100644 index a70c62dd..00000000 --- a/asana/models/batch_request_actions.py +++ /dev/null @@ -1,202 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class BatchRequestActions(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'relative_path': 'str', - 'method': 'str', - 'data': 'object', - 'options': 'BatchRequestOptions' - } - - attribute_map = { - 'relative_path': 'relative_path', - 'method': 'method', - 'data': 'data', - 'options': 'options' - } - - def __init__(self, relative_path=None, method=None, data=None, options=None): # noqa: E501 - """BatchRequestActions - a model defined in Swagger""" # noqa: E501 - self._relative_path = None - self._method = None - self._data = None - self._options = None - self.discriminator = None - self.relative_path = relative_path - self.method = method - if data is not None: - self.data = data - if options is not None: - self.options = options - - @property - def relative_path(self): - """Gets the relative_path of this BatchRequestActions. # noqa: E501 - - The path of the desired endpoint relative to the API’s base URL. Query parameters are not accepted here; put them in `data` instead. # noqa: E501 - - :return: The relative_path of this BatchRequestActions. # noqa: E501 - :rtype: str - """ - return self._relative_path - - @relative_path.setter - def relative_path(self, relative_path): - """Sets the relative_path of this BatchRequestActions. - - The path of the desired endpoint relative to the API’s base URL. Query parameters are not accepted here; put them in `data` instead. # noqa: E501 - - :param relative_path: The relative_path of this BatchRequestActions. # noqa: E501 - :type: str - """ - if relative_path is None: - raise ValueError("Invalid value for `relative_path`, must not be `None`") # noqa: E501 - - self._relative_path = relative_path - - @property - def method(self): - """Gets the method of this BatchRequestActions. # noqa: E501 - - The HTTP method you wish to emulate for the action. # noqa: E501 - - :return: The method of this BatchRequestActions. # noqa: E501 - :rtype: str - """ - return self._method - - @method.setter - def method(self, method): - """Sets the method of this BatchRequestActions. - - The HTTP method you wish to emulate for the action. # noqa: E501 - - :param method: The method of this BatchRequestActions. # noqa: E501 - :type: str - """ - if method is None: - raise ValueError("Invalid value for `method`, must not be `None`") # noqa: E501 - allowed_values = ["get", "post", "put", "delete", "patch", "head"] # noqa: E501 - if method not in allowed_values: - raise ValueError( - "Invalid value for `method` ({0}), must be one of {1}" # noqa: E501 - .format(method, allowed_values) - ) - - self._method = method - - @property - def data(self): - """Gets the data of this BatchRequestActions. # noqa: E501 - - For `GET` requests, this should be a map of query parameters you would have normally passed in the URL. Options and pagination are not accepted here; put them in `options` instead. For `POST`, `PATCH`, and `PUT` methods, this should be the content you would have normally put in the data field of the body. # noqa: E501 - - :return: The data of this BatchRequestActions. # noqa: E501 - :rtype: object - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this BatchRequestActions. - - For `GET` requests, this should be a map of query parameters you would have normally passed in the URL. Options and pagination are not accepted here; put them in `options` instead. For `POST`, `PATCH`, and `PUT` methods, this should be the content you would have normally put in the data field of the body. # noqa: E501 - - :param data: The data of this BatchRequestActions. # noqa: E501 - :type: object - """ - - self._data = data - - @property - def options(self): - """Gets the options of this BatchRequestActions. # noqa: E501 - - - :return: The options of this BatchRequestActions. # noqa: E501 - :rtype: BatchRequestOptions - """ - return self._options - - @options.setter - def options(self, options): - """Sets the options of this BatchRequestActions. - - - :param options: The options of this BatchRequestActions. # noqa: E501 - :type: BatchRequestOptions - """ - - self._options = options - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(BatchRequestActions, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, BatchRequestActions): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/batch_request_options.py b/asana/models/batch_request_options.py deleted file mode 100644 index c6487fb7..00000000 --- a/asana/models/batch_request_options.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class BatchRequestOptions(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'limit': 'int', - 'offset': 'int', - 'fields': 'list[str]' - } - - attribute_map = { - 'limit': 'limit', - 'offset': 'offset', - 'fields': 'fields' - } - - def __init__(self, limit=None, offset=None, fields=None): # noqa: E501 - """BatchRequestOptions - a model defined in Swagger""" # noqa: E501 - self._limit = None - self._offset = None - self._fields = None - self.discriminator = None - if limit is not None: - self.limit = limit - if offset is not None: - self.offset = offset - if fields is not None: - self.fields = fields - - @property - def limit(self): - """Gets the limit of this BatchRequestOptions. # noqa: E501 - - Pagination limit for the request. # noqa: E501 - - :return: The limit of this BatchRequestOptions. # noqa: E501 - :rtype: int - """ - return self._limit - - @limit.setter - def limit(self, limit): - """Sets the limit of this BatchRequestOptions. - - Pagination limit for the request. # noqa: E501 - - :param limit: The limit of this BatchRequestOptions. # noqa: E501 - :type: int - """ - - self._limit = limit - - @property - def offset(self): - """Gets the offset of this BatchRequestOptions. # noqa: E501 - - Pagination offset for the request. # noqa: E501 - - :return: The offset of this BatchRequestOptions. # noqa: E501 - :rtype: int - """ - return self._offset - - @offset.setter - def offset(self, offset): - """Sets the offset of this BatchRequestOptions. - - Pagination offset for the request. # noqa: E501 - - :param offset: The offset of this BatchRequestOptions. # noqa: E501 - :type: int - """ - - self._offset = offset - - @property - def fields(self): - """Gets the fields of this BatchRequestOptions. # noqa: E501 - - The fields to retrieve in the request. # noqa: E501 - - :return: The fields of this BatchRequestOptions. # noqa: E501 - :rtype: list[str] - """ - return self._fields - - @fields.setter - def fields(self, fields): - """Sets the fields of this BatchRequestOptions. - - The fields to retrieve in the request. # noqa: E501 - - :param fields: The fields of this BatchRequestOptions. # noqa: E501 - :type: list[str] - """ - - self._fields = fields - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(BatchRequestOptions, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, BatchRequestOptions): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/batch_response.py b/asana/models/batch_response.py deleted file mode 100644 index b071d916..00000000 --- a/asana/models/batch_response.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class BatchResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'status_code': 'int', - 'headers': 'object', - 'body': 'object' - } - - attribute_map = { - 'status_code': 'status_code', - 'headers': 'headers', - 'body': 'body' - } - - def __init__(self, status_code=None, headers=None, body=None): # noqa: E501 - """BatchResponse - a model defined in Swagger""" # noqa: E501 - self._status_code = None - self._headers = None - self._body = None - self.discriminator = None - if status_code is not None: - self.status_code = status_code - if headers is not None: - self.headers = headers - if body is not None: - self.body = body - - @property - def status_code(self): - """Gets the status_code of this BatchResponse. # noqa: E501 - - The HTTP status code that the invoked endpoint returned. # noqa: E501 - - :return: The status_code of this BatchResponse. # noqa: E501 - :rtype: int - """ - return self._status_code - - @status_code.setter - def status_code(self, status_code): - """Sets the status_code of this BatchResponse. - - The HTTP status code that the invoked endpoint returned. # noqa: E501 - - :param status_code: The status_code of this BatchResponse. # noqa: E501 - :type: int - """ - - self._status_code = status_code - - @property - def headers(self): - """Gets the headers of this BatchResponse. # noqa: E501 - - A map of HTTP headers specific to this result. This is primarily used for returning a `Location` header to accompany a `201 Created` result. The parent HTTP response will contain all common headers. # noqa: E501 - - :return: The headers of this BatchResponse. # noqa: E501 - :rtype: object - """ - return self._headers - - @headers.setter - def headers(self, headers): - """Sets the headers of this BatchResponse. - - A map of HTTP headers specific to this result. This is primarily used for returning a `Location` header to accompany a `201 Created` result. The parent HTTP response will contain all common headers. # noqa: E501 - - :param headers: The headers of this BatchResponse. # noqa: E501 - :type: object - """ - - self._headers = headers - - @property - def body(self): - """Gets the body of this BatchResponse. # noqa: E501 - - The JSON body that the invoked endpoint returned. # noqa: E501 - - :return: The body of this BatchResponse. # noqa: E501 - :rtype: object - """ - return self._body - - @body.setter - def body(self, body): - """Sets the body of this BatchResponse. - - The JSON body that the invoked endpoint returned. # noqa: E501 - - :param body: The body of this BatchResponse. # noqa: E501 - :type: object - """ - - self._body = body - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(BatchResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, BatchResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/batch_response_array.py b/asana/models/batch_response_array.py deleted file mode 100644 index 1c816100..00000000 --- a/asana/models/batch_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class BatchResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[BatchResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """BatchResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this BatchResponseArray. # noqa: E501 - - - :return: The data of this BatchResponseArray. # noqa: E501 - :rtype: list[BatchResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this BatchResponseArray. - - - :param data: The data of this BatchResponseArray. # noqa: E501 - :type: list[BatchResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this BatchResponseArray. # noqa: E501 - - - :return: The next_page of this BatchResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this BatchResponseArray. - - - :param next_page: The next_page of this BatchResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(BatchResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, BatchResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/create_membership_request.py b/asana/models/create_membership_request.py deleted file mode 100644 index 16390c03..00000000 --- a/asana/models/create_membership_request.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CreateMembershipRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'is_active': 'bool', - 'member': 'str', - 'parent': 'str' - } - - attribute_map = { - 'is_active': 'is_active', - 'member': 'member', - 'parent': 'parent' - } - - def __init__(self, is_active=None, member=None, parent=None): # noqa: E501 - """CreateMembershipRequest - a model defined in Swagger""" # noqa: E501 - self._is_active = None - self._member = None - self._parent = None - self.discriminator = None - if is_active is not None: - self.is_active = is_active - if member is not None: - self.member = member - if parent is not None: - self.parent = parent - - @property - def is_active(self): - """Gets the is_active of this CreateMembershipRequest. # noqa: E501 - - *Optional*. Denotes if a member is active. Applies to all memberships # noqa: E501 - - :return: The is_active of this CreateMembershipRequest. # noqa: E501 - :rtype: bool - """ - return self._is_active - - @is_active.setter - def is_active(self, is_active): - """Sets the is_active of this CreateMembershipRequest. - - *Optional*. Denotes if a member is active. Applies to all memberships # noqa: E501 - - :param is_active: The is_active of this CreateMembershipRequest. # noqa: E501 - :type: bool - """ - - self._is_active = is_active - - @property - def member(self): - """Gets the member of this CreateMembershipRequest. # noqa: E501 - - The gid of the user or team # noqa: E501 - - :return: The member of this CreateMembershipRequest. # noqa: E501 - :rtype: str - """ - return self._member - - @member.setter - def member(self, member): - """Sets the member of this CreateMembershipRequest. - - The gid of the user or team # noqa: E501 - - :param member: The member of this CreateMembershipRequest. # noqa: E501 - :type: str - """ - - self._member = member - - @property - def parent(self): - """Gets the parent of this CreateMembershipRequest. # noqa: E501 - - The gid of the `goal` # noqa: E501 - - :return: The parent of this CreateMembershipRequest. # noqa: E501 - :rtype: str - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this CreateMembershipRequest. - - The gid of the `goal` # noqa: E501 - - :param parent: The parent of this CreateMembershipRequest. # noqa: E501 - :type: str - """ - - self._parent = parent - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CreateMembershipRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CreateMembershipRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/create_time_tracking_entry_request.py b/asana/models/create_time_tracking_entry_request.py deleted file mode 100644 index 4019273d..00000000 --- a/asana/models/create_time_tracking_entry_request.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CreateTimeTrackingEntryRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'duration_minutes': 'int', - 'entered_on': 'date' - } - - attribute_map = { - 'duration_minutes': 'duration_minutes', - 'entered_on': 'entered_on' - } - - def __init__(self, duration_minutes=None, entered_on=None): # noqa: E501 - """CreateTimeTrackingEntryRequest - a model defined in Swagger""" # noqa: E501 - self._duration_minutes = None - self._entered_on = None - self.discriminator = None - if duration_minutes is not None: - self.duration_minutes = duration_minutes - if entered_on is not None: - self.entered_on = entered_on - - @property - def duration_minutes(self): - """Gets the duration_minutes of this CreateTimeTrackingEntryRequest. # noqa: E501 - - Time in minutes tracked by the entry. Must be greater than 0 # noqa: E501 - - :return: The duration_minutes of this CreateTimeTrackingEntryRequest. # noqa: E501 - :rtype: int - """ - return self._duration_minutes - - @duration_minutes.setter - def duration_minutes(self, duration_minutes): - """Sets the duration_minutes of this CreateTimeTrackingEntryRequest. - - Time in minutes tracked by the entry. Must be greater than 0 # noqa: E501 - - :param duration_minutes: The duration_minutes of this CreateTimeTrackingEntryRequest. # noqa: E501 - :type: int - """ - - self._duration_minutes = duration_minutes - - @property - def entered_on(self): - """Gets the entered_on of this CreateTimeTrackingEntryRequest. # noqa: E501 - - *Optional*. The day that this entry is logged on. Defaults to today if not specified # noqa: E501 - - :return: The entered_on of this CreateTimeTrackingEntryRequest. # noqa: E501 - :rtype: date - """ - return self._entered_on - - @entered_on.setter - def entered_on(self, entered_on): - """Sets the entered_on of this CreateTimeTrackingEntryRequest. - - *Optional*. The day that this entry is logged on. Defaults to today if not specified # noqa: E501 - - :param entered_on: The entered_on of this CreateTimeTrackingEntryRequest. # noqa: E501 - :type: date - """ - - self._entered_on = entered_on - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CreateTimeTrackingEntryRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CreateTimeTrackingEntryRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_base.py b/asana/models/custom_field_base.py deleted file mode 100644 index 78f9ab24..00000000 --- a/asana/models/custom_field_base.py +++ /dev/null @@ -1,754 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'type': 'str', - 'enum_options': 'list[CustomFieldBaseEnumOptions]', - 'enabled': 'bool', - 'is_formula_field': 'bool', - 'date_value': 'CustomFieldBaseDateValue', - 'enum_value': 'CustomFieldBaseEnumValue', - 'multi_enum_values': 'list[CustomFieldBaseEnumOptions]', - 'number_value': 'float', - 'text_value': 'str', - 'display_value': 'str', - 'description': 'str', - 'precision': 'int', - 'format': 'str', - 'currency_code': 'str', - 'custom_label': 'str', - 'custom_label_position': 'str', - 'is_global_to_workspace': 'bool', - 'has_notifications_enabled': 'bool', - 'asana_created_field': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'type': 'type', - 'enum_options': 'enum_options', - 'enabled': 'enabled', - 'is_formula_field': 'is_formula_field', - 'date_value': 'date_value', - 'enum_value': 'enum_value', - 'multi_enum_values': 'multi_enum_values', - 'number_value': 'number_value', - 'text_value': 'text_value', - 'display_value': 'display_value', - 'description': 'description', - 'precision': 'precision', - 'format': 'format', - 'currency_code': 'currency_code', - 'custom_label': 'custom_label', - 'custom_label_position': 'custom_label_position', - 'is_global_to_workspace': 'is_global_to_workspace', - 'has_notifications_enabled': 'has_notifications_enabled', - 'asana_created_field': 'asana_created_field' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, type=None, enum_options=None, enabled=None, is_formula_field=None, date_value=None, enum_value=None, multi_enum_values=None, number_value=None, text_value=None, display_value=None, description=None, precision=None, format=None, currency_code=None, custom_label=None, custom_label_position=None, is_global_to_workspace=None, has_notifications_enabled=None, asana_created_field=None): # noqa: E501 - """CustomFieldBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._type = None - self._enum_options = None - self._enabled = None - self._is_formula_field = None - self._date_value = None - self._enum_value = None - self._multi_enum_values = None - self._number_value = None - self._text_value = None - self._display_value = None - self._description = None - self._precision = None - self._format = None - self._currency_code = None - self._custom_label = None - self._custom_label_position = None - self._is_global_to_workspace = None - self._has_notifications_enabled = None - self._asana_created_field = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if type is not None: - self.type = type - if enum_options is not None: - self.enum_options = enum_options - if enabled is not None: - self.enabled = enabled - if is_formula_field is not None: - self.is_formula_field = is_formula_field - if date_value is not None: - self.date_value = date_value - if enum_value is not None: - self.enum_value = enum_value - if multi_enum_values is not None: - self.multi_enum_values = multi_enum_values - if number_value is not None: - self.number_value = number_value - if text_value is not None: - self.text_value = text_value - if display_value is not None: - self.display_value = display_value - if description is not None: - self.description = description - if precision is not None: - self.precision = precision - if format is not None: - self.format = format - if currency_code is not None: - self.currency_code = currency_code - if custom_label is not None: - self.custom_label = custom_label - if custom_label_position is not None: - self.custom_label_position = custom_label_position - if is_global_to_workspace is not None: - self.is_global_to_workspace = is_global_to_workspace - if has_notifications_enabled is not None: - self.has_notifications_enabled = has_notifications_enabled - if asana_created_field is not None: - self.asana_created_field = asana_created_field - - @property - def gid(self): - """Gets the gid of this CustomFieldBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this CustomFieldBase. # noqa: E501 - - The name of the custom field. # noqa: E501 - - :return: The name of this CustomFieldBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this CustomFieldBase. - - The name of the custom field. # noqa: E501 - - :param name: The name of this CustomFieldBase. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this CustomFieldBase. # noqa: E501 - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The resource_subtype of this CustomFieldBase. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this CustomFieldBase. - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :param resource_subtype: The resource_subtype of this CustomFieldBase. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def type(self): - """Gets the type of this CustomFieldBase. # noqa: E501 - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The type of this CustomFieldBase. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this CustomFieldBase. - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :param type: The type of this CustomFieldBase. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if type not in allowed_values: - raise ValueError( - "Invalid value for `type` ({0}), must be one of {1}" # noqa: E501 - .format(type, allowed_values) - ) - - self._type = type - - @property - def enum_options(self): - """Gets the enum_options of this CustomFieldBase. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :return: The enum_options of this CustomFieldBase. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._enum_options - - @enum_options.setter - def enum_options(self, enum_options): - """Sets the enum_options of this CustomFieldBase. - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :param enum_options: The enum_options of this CustomFieldBase. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._enum_options = enum_options - - @property - def enabled(self): - """Gets the enabled of this CustomFieldBase. # noqa: E501 - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :return: The enabled of this CustomFieldBase. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this CustomFieldBase. - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :param enabled: The enabled of this CustomFieldBase. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def is_formula_field(self): - """Gets the is_formula_field of this CustomFieldBase. # noqa: E501 - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :return: The is_formula_field of this CustomFieldBase. # noqa: E501 - :rtype: bool - """ - return self._is_formula_field - - @is_formula_field.setter - def is_formula_field(self, is_formula_field): - """Sets the is_formula_field of this CustomFieldBase. - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :param is_formula_field: The is_formula_field of this CustomFieldBase. # noqa: E501 - :type: bool - """ - - self._is_formula_field = is_formula_field - - @property - def date_value(self): - """Gets the date_value of this CustomFieldBase. # noqa: E501 - - - :return: The date_value of this CustomFieldBase. # noqa: E501 - :rtype: CustomFieldBaseDateValue - """ - return self._date_value - - @date_value.setter - def date_value(self, date_value): - """Sets the date_value of this CustomFieldBase. - - - :param date_value: The date_value of this CustomFieldBase. # noqa: E501 - :type: CustomFieldBaseDateValue - """ - - self._date_value = date_value - - @property - def enum_value(self): - """Gets the enum_value of this CustomFieldBase. # noqa: E501 - - - :return: The enum_value of this CustomFieldBase. # noqa: E501 - :rtype: CustomFieldBaseEnumValue - """ - return self._enum_value - - @enum_value.setter - def enum_value(self, enum_value): - """Sets the enum_value of this CustomFieldBase. - - - :param enum_value: The enum_value of this CustomFieldBase. # noqa: E501 - :type: CustomFieldBaseEnumValue - """ - - self._enum_value = enum_value - - @property - def multi_enum_values(self): - """Gets the multi_enum_values of this CustomFieldBase. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :return: The multi_enum_values of this CustomFieldBase. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._multi_enum_values - - @multi_enum_values.setter - def multi_enum_values(self, multi_enum_values): - """Sets the multi_enum_values of this CustomFieldBase. - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :param multi_enum_values: The multi_enum_values of this CustomFieldBase. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._multi_enum_values = multi_enum_values - - @property - def number_value(self): - """Gets the number_value of this CustomFieldBase. # noqa: E501 - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :return: The number_value of this CustomFieldBase. # noqa: E501 - :rtype: float - """ - return self._number_value - - @number_value.setter - def number_value(self, number_value): - """Sets the number_value of this CustomFieldBase. - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :param number_value: The number_value of this CustomFieldBase. # noqa: E501 - :type: float - """ - - self._number_value = number_value - - @property - def text_value(self): - """Gets the text_value of this CustomFieldBase. # noqa: E501 - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :return: The text_value of this CustomFieldBase. # noqa: E501 - :rtype: str - """ - return self._text_value - - @text_value.setter - def text_value(self, text_value): - """Sets the text_value of this CustomFieldBase. - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :param text_value: The text_value of this CustomFieldBase. # noqa: E501 - :type: str - """ - - self._text_value = text_value - - @property - def display_value(self): - """Gets the display_value of this CustomFieldBase. # noqa: E501 - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :return: The display_value of this CustomFieldBase. # noqa: E501 - :rtype: str - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this CustomFieldBase. - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :param display_value: The display_value of this CustomFieldBase. # noqa: E501 - :type: str - """ - - self._display_value = display_value - - @property - def description(self): - """Gets the description of this CustomFieldBase. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The description of the custom field. # noqa: E501 - - :return: The description of this CustomFieldBase. # noqa: E501 - :rtype: str - """ - return self._description - - @description.setter - def description(self, description): - """Sets the description of this CustomFieldBase. - - [Opt In](/docs/inputoutput-options). The description of the custom field. # noqa: E501 - - :param description: The description of this CustomFieldBase. # noqa: E501 - :type: str - """ - - self._description = description - - @property - def precision(self): - """Gets the precision of this CustomFieldBase. # noqa: E501 - - Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. # noqa: E501 - - :return: The precision of this CustomFieldBase. # noqa: E501 - :rtype: int - """ - return self._precision - - @precision.setter - def precision(self, precision): - """Sets the precision of this CustomFieldBase. - - Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. # noqa: E501 - - :param precision: The precision of this CustomFieldBase. # noqa: E501 - :type: int - """ - - self._precision = precision - - @property - def format(self): - """Gets the format of this CustomFieldBase. # noqa: E501 - - The format of this custom field. # noqa: E501 - - :return: The format of this CustomFieldBase. # noqa: E501 - :rtype: str - """ - return self._format - - @format.setter - def format(self, format): - """Sets the format of this CustomFieldBase. - - The format of this custom field. # noqa: E501 - - :param format: The format of this CustomFieldBase. # noqa: E501 - :type: str - """ - allowed_values = ["currency", "identifier", "percentage", "custom", "duration", "none"] # noqa: E501 - if format not in allowed_values: - raise ValueError( - "Invalid value for `format` ({0}), must be one of {1}" # noqa: E501 - .format(format, allowed_values) - ) - - self._format = format - - @property - def currency_code(self): - """Gets the currency_code of this CustomFieldBase. # noqa: E501 - - ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. # noqa: E501 - - :return: The currency_code of this CustomFieldBase. # noqa: E501 - :rtype: str - """ - return self._currency_code - - @currency_code.setter - def currency_code(self, currency_code): - """Sets the currency_code of this CustomFieldBase. - - ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. # noqa: E501 - - :param currency_code: The currency_code of this CustomFieldBase. # noqa: E501 - :type: str - """ - - self._currency_code = currency_code - - @property - def custom_label(self): - """Gets the custom_label of this CustomFieldBase. # noqa: E501 - - This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. # noqa: E501 - - :return: The custom_label of this CustomFieldBase. # noqa: E501 - :rtype: str - """ - return self._custom_label - - @custom_label.setter - def custom_label(self, custom_label): - """Sets the custom_label of this CustomFieldBase. - - This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. # noqa: E501 - - :param custom_label: The custom_label of this CustomFieldBase. # noqa: E501 - :type: str - """ - - self._custom_label = custom_label - - @property - def custom_label_position(self): - """Gets the custom_label_position of this CustomFieldBase. # noqa: E501 - - Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. # noqa: E501 - - :return: The custom_label_position of this CustomFieldBase. # noqa: E501 - :rtype: str - """ - return self._custom_label_position - - @custom_label_position.setter - def custom_label_position(self, custom_label_position): - """Sets the custom_label_position of this CustomFieldBase. - - Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. # noqa: E501 - - :param custom_label_position: The custom_label_position of this CustomFieldBase. # noqa: E501 - :type: str - """ - allowed_values = ["prefix", "suffix", ""] # noqa: E501 - if custom_label_position not in allowed_values: - raise ValueError( - "Invalid value for `custom_label_position` ({0}), must be one of {1}" # noqa: E501 - .format(custom_label_position, allowed_values) - ) - - self._custom_label_position = custom_label_position - - @property - def is_global_to_workspace(self): - """Gets the is_global_to_workspace of this CustomFieldBase. # noqa: E501 - - This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. # noqa: E501 - - :return: The is_global_to_workspace of this CustomFieldBase. # noqa: E501 - :rtype: bool - """ - return self._is_global_to_workspace - - @is_global_to_workspace.setter - def is_global_to_workspace(self, is_global_to_workspace): - """Sets the is_global_to_workspace of this CustomFieldBase. - - This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. # noqa: E501 - - :param is_global_to_workspace: The is_global_to_workspace of this CustomFieldBase. # noqa: E501 - :type: bool - """ - - self._is_global_to_workspace = is_global_to_workspace - - @property - def has_notifications_enabled(self): - """Gets the has_notifications_enabled of this CustomFieldBase. # noqa: E501 - - *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. # noqa: E501 - - :return: The has_notifications_enabled of this CustomFieldBase. # noqa: E501 - :rtype: bool - """ - return self._has_notifications_enabled - - @has_notifications_enabled.setter - def has_notifications_enabled(self, has_notifications_enabled): - """Sets the has_notifications_enabled of this CustomFieldBase. - - *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. # noqa: E501 - - :param has_notifications_enabled: The has_notifications_enabled of this CustomFieldBase. # noqa: E501 - :type: bool - """ - - self._has_notifications_enabled = has_notifications_enabled - - @property - def asana_created_field(self): - """Gets the asana_created_field of this CustomFieldBase. # noqa: E501 - - *Conditional*. A unique identifier to associate this field with the template source of truth. # noqa: E501 - - :return: The asana_created_field of this CustomFieldBase. # noqa: E501 - :rtype: str - """ - return self._asana_created_field - - @asana_created_field.setter - def asana_created_field(self, asana_created_field): - """Sets the asana_created_field of this CustomFieldBase. - - *Conditional*. A unique identifier to associate this field with the template source of truth. # noqa: E501 - - :param asana_created_field: The asana_created_field of this CustomFieldBase. # noqa: E501 - :type: str - """ - allowed_values = ["a_v_requirements", "account_name", "actionable", "align_shipping_link", "align_status", "allotted_time", "appointment", "approval_stage", "approved", "article_series", "board_committee", "browser", "campaign_audience", "campaign_project_status", "campaign_regions", "channel_primary", "client_topic_type", "complete_by", "contact", "contact_email_address", "content_channels", "content_channels_needed", "content_stage", "content_type", "contract", "contract_status", "cost", "creation_stage", "creative_channel", "creative_needed", "creative_needs", "data_sensitivity", "deal_size", "delivery_appt", "delivery_appt_date", "department", "department_responsible", "design_request_needed", "design_request_type", "discussion_category", "do_this_task", "editorial_content_status", "editorial_content_tag", "editorial_content_type", "effort", "effort_level", "est_completion_date", "estimated_time", "estimated_value", "expected_cost", "external_steps_needed", "favorite_idea", "feedback_type", "financial", "funding_amount", "grant_application_process", "hiring_candidate_status", "idea_status", "ids_link", "ids_patient_link", "implementation_stage", "insurance", "interview_area", "interview_question_score", "itero_scan_link", "job_s_applied_to", "lab", "launch_status", "lead_status", "localization_language", "localization_market_team", "localization_status", "meeting_minutes", "meeting_needed", "minutes", "mrr", "must_localize", "name_of_foundation", "need_to_follow_up", "next_appointment", "next_steps_sales", "num_people", "number_of_user_reports", "office_location", "onboarding_activity", "owner", "participants_needed", "patient_date_of_birth", "patient_email", "patient_phone", "patient_status", "phone_number", "planning_category", "point_of_contact", "position", "post_format", "prescription", "priority", "priority_level", "product", "product_stage", "progress", "project_size", "project_status", "proposed_budget", "publish_status", "reason_for_scan", "referral", "request_type", "research_status", "responsible_department", "responsible_team", "risk_assessment_status", "room_name", "sales_counterpart", "sentiment", "shipping_link", "social_channels", "stage", "status", "status_design", "status_of_initiative", "system_setup", "task_progress", "team", "team_marketing", "team_responsible", "time_it_takes_to_complete_tasks", "timeframe", "treatment_type", "type_work_requests_it", "use_agency", "user_name", "vendor_category", "vendor_type", "word_count", ""] # noqa: E501 - if asana_created_field not in allowed_values: - raise ValueError( - "Invalid value for `asana_created_field` ({0}), must be one of {1}" # noqa: E501 - .format(asana_created_field, allowed_values) - ) - - self._asana_created_field = asana_created_field - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_base_date_value.py b/asana/models/custom_field_base_date_value.py deleted file mode 100644 index e2d400ac..00000000 --- a/asana/models/custom_field_base_date_value.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldBaseDateValue(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - '_date': 'str', - 'date_time': 'str' - } - - attribute_map = { - '_date': 'date', - 'date_time': 'date_time' - } - - def __init__(self, _date=None, date_time=None): # noqa: E501 - """CustomFieldBaseDateValue - a model defined in Swagger""" # noqa: E501 - self.__date = None - self._date_time = None - self.discriminator = None - if _date is not None: - self._date = _date - if date_time is not None: - self.date_time = date_time - - @property - def _date(self): - """Gets the _date of this CustomFieldBaseDateValue. # noqa: E501 - - A string representing the date in YYYY-MM-DD format. # noqa: E501 - - :return: The _date of this CustomFieldBaseDateValue. # noqa: E501 - :rtype: str - """ - return self.__date - - @_date.setter - def _date(self, _date): - """Sets the _date of this CustomFieldBaseDateValue. - - A string representing the date in YYYY-MM-DD format. # noqa: E501 - - :param _date: The _date of this CustomFieldBaseDateValue. # noqa: E501 - :type: str - """ - - self.__date = _date - - @property - def date_time(self): - """Gets the date_time of this CustomFieldBaseDateValue. # noqa: E501 - - A string representing the date in ISO 8601 format. If no time value is selected, the value of `date-time` will be `null`. # noqa: E501 - - :return: The date_time of this CustomFieldBaseDateValue. # noqa: E501 - :rtype: str - """ - return self._date_time - - @date_time.setter - def date_time(self, date_time): - """Sets the date_time of this CustomFieldBaseDateValue. - - A string representing the date in ISO 8601 format. If no time value is selected, the value of `date-time` will be `null`. # noqa: E501 - - :param date_time: The date_time of this CustomFieldBaseDateValue. # noqa: E501 - :type: str - """ - - self._date_time = date_time - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldBaseDateValue, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldBaseDateValue): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_base_enum_options.py b/asana/models/custom_field_base_enum_options.py deleted file mode 100644 index 4ecfa66a..00000000 --- a/asana/models/custom_field_base_enum_options.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldBaseEnumOptions(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'enabled': 'bool', - 'color': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'enabled': 'enabled', - 'color': 'color' - } - - def __init__(self, gid=None, resource_type=None, name=None, enabled=None, color=None): # noqa: E501 - """CustomFieldBaseEnumOptions - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._enabled = None - self._color = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if enabled is not None: - self.enabled = enabled - if color is not None: - self.color = color - - @property - def gid(self): - """Gets the gid of this CustomFieldBaseEnumOptions. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldBaseEnumOptions. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldBaseEnumOptions. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldBaseEnumOptions. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldBaseEnumOptions. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldBaseEnumOptions. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldBaseEnumOptions. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldBaseEnumOptions. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this CustomFieldBaseEnumOptions. # noqa: E501 - - The name of the enum option. # noqa: E501 - - :return: The name of this CustomFieldBaseEnumOptions. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this CustomFieldBaseEnumOptions. - - The name of the enum option. # noqa: E501 - - :param name: The name of this CustomFieldBaseEnumOptions. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def enabled(self): - """Gets the enabled of this CustomFieldBaseEnumOptions. # noqa: E501 - - Whether or not the enum option is a selectable value for the custom field. # noqa: E501 - - :return: The enabled of this CustomFieldBaseEnumOptions. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this CustomFieldBaseEnumOptions. - - Whether or not the enum option is a selectable value for the custom field. # noqa: E501 - - :param enabled: The enabled of this CustomFieldBaseEnumOptions. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def color(self): - """Gets the color of this CustomFieldBaseEnumOptions. # noqa: E501 - - The color of the enum option. Defaults to ‘none’. # noqa: E501 - - :return: The color of this CustomFieldBaseEnumOptions. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this CustomFieldBaseEnumOptions. - - The color of the enum option. Defaults to ‘none’. # noqa: E501 - - :param color: The color of this CustomFieldBaseEnumOptions. # noqa: E501 - :type: str - """ - - self._color = color - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldBaseEnumOptions, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldBaseEnumOptions): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_base_enum_value.py b/asana/models/custom_field_base_enum_value.py deleted file mode 100644 index 3997d93d..00000000 --- a/asana/models/custom_field_base_enum_value.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldBaseEnumValue(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'enabled': 'bool', - 'color': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'enabled': 'enabled', - 'color': 'color' - } - - def __init__(self, gid=None, resource_type=None, name=None, enabled=None, color=None): # noqa: E501 - """CustomFieldBaseEnumValue - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._enabled = None - self._color = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if enabled is not None: - self.enabled = enabled - if color is not None: - self.color = color - - @property - def gid(self): - """Gets the gid of this CustomFieldBaseEnumValue. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldBaseEnumValue. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldBaseEnumValue. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldBaseEnumValue. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldBaseEnumValue. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldBaseEnumValue. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldBaseEnumValue. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldBaseEnumValue. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this CustomFieldBaseEnumValue. # noqa: E501 - - The name of the enum option. # noqa: E501 - - :return: The name of this CustomFieldBaseEnumValue. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this CustomFieldBaseEnumValue. - - The name of the enum option. # noqa: E501 - - :param name: The name of this CustomFieldBaseEnumValue. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def enabled(self): - """Gets the enabled of this CustomFieldBaseEnumValue. # noqa: E501 - - Whether or not the enum option is a selectable value for the custom field. # noqa: E501 - - :return: The enabled of this CustomFieldBaseEnumValue. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this CustomFieldBaseEnumValue. - - Whether or not the enum option is a selectable value for the custom field. # noqa: E501 - - :param enabled: The enabled of this CustomFieldBaseEnumValue. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def color(self): - """Gets the color of this CustomFieldBaseEnumValue. # noqa: E501 - - The color of the enum option. Defaults to ‘none’. # noqa: E501 - - :return: The color of this CustomFieldBaseEnumValue. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this CustomFieldBaseEnumValue. - - The color of the enum option. Defaults to ‘none’. # noqa: E501 - - :param color: The color of this CustomFieldBaseEnumValue. # noqa: E501 - :type: str - """ - - self._color = color - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldBaseEnumValue, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldBaseEnumValue): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_compact.py b/asana/models/custom_field_compact.py deleted file mode 100644 index f025022c..00000000 --- a/asana/models/custom_field_compact.py +++ /dev/null @@ -1,484 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'type': 'str', - 'enum_options': 'list[CustomFieldBaseEnumOptions]', - 'enabled': 'bool', - 'is_formula_field': 'bool', - 'date_value': 'CustomFieldBaseDateValue', - 'enum_value': 'CustomFieldBaseEnumValue', - 'multi_enum_values': 'list[CustomFieldBaseEnumOptions]', - 'number_value': 'float', - 'text_value': 'str', - 'display_value': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'type': 'type', - 'enum_options': 'enum_options', - 'enabled': 'enabled', - 'is_formula_field': 'is_formula_field', - 'date_value': 'date_value', - 'enum_value': 'enum_value', - 'multi_enum_values': 'multi_enum_values', - 'number_value': 'number_value', - 'text_value': 'text_value', - 'display_value': 'display_value' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, type=None, enum_options=None, enabled=None, is_formula_field=None, date_value=None, enum_value=None, multi_enum_values=None, number_value=None, text_value=None, display_value=None): # noqa: E501 - """CustomFieldCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._type = None - self._enum_options = None - self._enabled = None - self._is_formula_field = None - self._date_value = None - self._enum_value = None - self._multi_enum_values = None - self._number_value = None - self._text_value = None - self._display_value = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if type is not None: - self.type = type - if enum_options is not None: - self.enum_options = enum_options - if enabled is not None: - self.enabled = enabled - if is_formula_field is not None: - self.is_formula_field = is_formula_field - if date_value is not None: - self.date_value = date_value - if enum_value is not None: - self.enum_value = enum_value - if multi_enum_values is not None: - self.multi_enum_values = multi_enum_values - if number_value is not None: - self.number_value = number_value - if text_value is not None: - self.text_value = text_value - if display_value is not None: - self.display_value = display_value - - @property - def gid(self): - """Gets the gid of this CustomFieldCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this CustomFieldCompact. # noqa: E501 - - The name of the custom field. # noqa: E501 - - :return: The name of this CustomFieldCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this CustomFieldCompact. - - The name of the custom field. # noqa: E501 - - :param name: The name of this CustomFieldCompact. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this CustomFieldCompact. # noqa: E501 - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The resource_subtype of this CustomFieldCompact. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this CustomFieldCompact. - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :param resource_subtype: The resource_subtype of this CustomFieldCompact. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def type(self): - """Gets the type of this CustomFieldCompact. # noqa: E501 - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The type of this CustomFieldCompact. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this CustomFieldCompact. - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :param type: The type of this CustomFieldCompact. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if type not in allowed_values: - raise ValueError( - "Invalid value for `type` ({0}), must be one of {1}" # noqa: E501 - .format(type, allowed_values) - ) - - self._type = type - - @property - def enum_options(self): - """Gets the enum_options of this CustomFieldCompact. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :return: The enum_options of this CustomFieldCompact. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._enum_options - - @enum_options.setter - def enum_options(self, enum_options): - """Sets the enum_options of this CustomFieldCompact. - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :param enum_options: The enum_options of this CustomFieldCompact. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._enum_options = enum_options - - @property - def enabled(self): - """Gets the enabled of this CustomFieldCompact. # noqa: E501 - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :return: The enabled of this CustomFieldCompact. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this CustomFieldCompact. - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :param enabled: The enabled of this CustomFieldCompact. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def is_formula_field(self): - """Gets the is_formula_field of this CustomFieldCompact. # noqa: E501 - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :return: The is_formula_field of this CustomFieldCompact. # noqa: E501 - :rtype: bool - """ - return self._is_formula_field - - @is_formula_field.setter - def is_formula_field(self, is_formula_field): - """Sets the is_formula_field of this CustomFieldCompact. - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :param is_formula_field: The is_formula_field of this CustomFieldCompact. # noqa: E501 - :type: bool - """ - - self._is_formula_field = is_formula_field - - @property - def date_value(self): - """Gets the date_value of this CustomFieldCompact. # noqa: E501 - - - :return: The date_value of this CustomFieldCompact. # noqa: E501 - :rtype: CustomFieldBaseDateValue - """ - return self._date_value - - @date_value.setter - def date_value(self, date_value): - """Sets the date_value of this CustomFieldCompact. - - - :param date_value: The date_value of this CustomFieldCompact. # noqa: E501 - :type: CustomFieldBaseDateValue - """ - - self._date_value = date_value - - @property - def enum_value(self): - """Gets the enum_value of this CustomFieldCompact. # noqa: E501 - - - :return: The enum_value of this CustomFieldCompact. # noqa: E501 - :rtype: CustomFieldBaseEnumValue - """ - return self._enum_value - - @enum_value.setter - def enum_value(self, enum_value): - """Sets the enum_value of this CustomFieldCompact. - - - :param enum_value: The enum_value of this CustomFieldCompact. # noqa: E501 - :type: CustomFieldBaseEnumValue - """ - - self._enum_value = enum_value - - @property - def multi_enum_values(self): - """Gets the multi_enum_values of this CustomFieldCompact. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :return: The multi_enum_values of this CustomFieldCompact. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._multi_enum_values - - @multi_enum_values.setter - def multi_enum_values(self, multi_enum_values): - """Sets the multi_enum_values of this CustomFieldCompact. - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :param multi_enum_values: The multi_enum_values of this CustomFieldCompact. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._multi_enum_values = multi_enum_values - - @property - def number_value(self): - """Gets the number_value of this CustomFieldCompact. # noqa: E501 - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :return: The number_value of this CustomFieldCompact. # noqa: E501 - :rtype: float - """ - return self._number_value - - @number_value.setter - def number_value(self, number_value): - """Sets the number_value of this CustomFieldCompact. - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :param number_value: The number_value of this CustomFieldCompact. # noqa: E501 - :type: float - """ - - self._number_value = number_value - - @property - def text_value(self): - """Gets the text_value of this CustomFieldCompact. # noqa: E501 - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :return: The text_value of this CustomFieldCompact. # noqa: E501 - :rtype: str - """ - return self._text_value - - @text_value.setter - def text_value(self, text_value): - """Sets the text_value of this CustomFieldCompact. - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :param text_value: The text_value of this CustomFieldCompact. # noqa: E501 - :type: str - """ - - self._text_value = text_value - - @property - def display_value(self): - """Gets the display_value of this CustomFieldCompact. # noqa: E501 - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :return: The display_value of this CustomFieldCompact. # noqa: E501 - :rtype: str - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this CustomFieldCompact. - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :param display_value: The display_value of this CustomFieldCompact. # noqa: E501 - :type: str - """ - - self._display_value = display_value - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_gid_enum_options_body.py b/asana/models/custom_field_gid_enum_options_body.py deleted file mode 100644 index 562ce2ac..00000000 --- a/asana/models/custom_field_gid_enum_options_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldGidEnumOptionsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'EnumOptionRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """CustomFieldGidEnumOptionsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this CustomFieldGidEnumOptionsBody. # noqa: E501 - - - :return: The data of this CustomFieldGidEnumOptionsBody. # noqa: E501 - :rtype: EnumOptionRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this CustomFieldGidEnumOptionsBody. - - - :param data: The data of this CustomFieldGidEnumOptionsBody. # noqa: E501 - :type: EnumOptionRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldGidEnumOptionsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldGidEnumOptionsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_request.py b/asana/models/custom_field_request.py deleted file mode 100644 index 0890fa55..00000000 --- a/asana/models/custom_field_request.py +++ /dev/null @@ -1,839 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'type': 'str', - 'enum_options': 'list[CustomFieldBaseEnumOptions]', - 'enabled': 'bool', - 'is_formula_field': 'bool', - 'date_value': 'CustomFieldBaseDateValue', - 'enum_value': 'CustomFieldBaseEnumValue', - 'multi_enum_values': 'list[CustomFieldBaseEnumOptions]', - 'number_value': 'float', - 'text_value': 'str', - 'display_value': 'str', - 'description': 'str', - 'precision': 'int', - 'format': 'str', - 'currency_code': 'str', - 'custom_label': 'str', - 'custom_label_position': 'str', - 'is_global_to_workspace': 'bool', - 'has_notifications_enabled': 'bool', - 'asana_created_field': 'str', - 'workspace': 'str', - 'owned_by_app': 'bool', - 'people_value': 'list[str]' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'type': 'type', - 'enum_options': 'enum_options', - 'enabled': 'enabled', - 'is_formula_field': 'is_formula_field', - 'date_value': 'date_value', - 'enum_value': 'enum_value', - 'multi_enum_values': 'multi_enum_values', - 'number_value': 'number_value', - 'text_value': 'text_value', - 'display_value': 'display_value', - 'description': 'description', - 'precision': 'precision', - 'format': 'format', - 'currency_code': 'currency_code', - 'custom_label': 'custom_label', - 'custom_label_position': 'custom_label_position', - 'is_global_to_workspace': 'is_global_to_workspace', - 'has_notifications_enabled': 'has_notifications_enabled', - 'asana_created_field': 'asana_created_field', - 'workspace': 'workspace', - 'owned_by_app': 'owned_by_app', - 'people_value': 'people_value' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, type=None, enum_options=None, enabled=None, is_formula_field=None, date_value=None, enum_value=None, multi_enum_values=None, number_value=None, text_value=None, display_value=None, description=None, precision=None, format=None, currency_code=None, custom_label=None, custom_label_position=None, is_global_to_workspace=None, has_notifications_enabled=None, asana_created_field=None, workspace=None, owned_by_app=None, people_value=None): # noqa: E501 - """CustomFieldRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._type = None - self._enum_options = None - self._enabled = None - self._is_formula_field = None - self._date_value = None - self._enum_value = None - self._multi_enum_values = None - self._number_value = None - self._text_value = None - self._display_value = None - self._description = None - self._precision = None - self._format = None - self._currency_code = None - self._custom_label = None - self._custom_label_position = None - self._is_global_to_workspace = None - self._has_notifications_enabled = None - self._asana_created_field = None - self._workspace = None - self._owned_by_app = None - self._people_value = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if type is not None: - self.type = type - if enum_options is not None: - self.enum_options = enum_options - if enabled is not None: - self.enabled = enabled - if is_formula_field is not None: - self.is_formula_field = is_formula_field - if date_value is not None: - self.date_value = date_value - if enum_value is not None: - self.enum_value = enum_value - if multi_enum_values is not None: - self.multi_enum_values = multi_enum_values - if number_value is not None: - self.number_value = number_value - if text_value is not None: - self.text_value = text_value - if display_value is not None: - self.display_value = display_value - if description is not None: - self.description = description - if precision is not None: - self.precision = precision - if format is not None: - self.format = format - if currency_code is not None: - self.currency_code = currency_code - if custom_label is not None: - self.custom_label = custom_label - if custom_label_position is not None: - self.custom_label_position = custom_label_position - if is_global_to_workspace is not None: - self.is_global_to_workspace = is_global_to_workspace - if has_notifications_enabled is not None: - self.has_notifications_enabled = has_notifications_enabled - if asana_created_field is not None: - self.asana_created_field = asana_created_field - self.workspace = workspace - if owned_by_app is not None: - self.owned_by_app = owned_by_app - if people_value is not None: - self.people_value = people_value - - @property - def gid(self): - """Gets the gid of this CustomFieldRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this CustomFieldRequest. # noqa: E501 - - The name of the custom field. # noqa: E501 - - :return: The name of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this CustomFieldRequest. - - The name of the custom field. # noqa: E501 - - :param name: The name of this CustomFieldRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this CustomFieldRequest. # noqa: E501 - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The resource_subtype of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this CustomFieldRequest. - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :param resource_subtype: The resource_subtype of this CustomFieldRequest. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def type(self): - """Gets the type of this CustomFieldRequest. # noqa: E501 - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The type of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this CustomFieldRequest. - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :param type: The type of this CustomFieldRequest. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if type not in allowed_values: - raise ValueError( - "Invalid value for `type` ({0}), must be one of {1}" # noqa: E501 - .format(type, allowed_values) - ) - - self._type = type - - @property - def enum_options(self): - """Gets the enum_options of this CustomFieldRequest. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :return: The enum_options of this CustomFieldRequest. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._enum_options - - @enum_options.setter - def enum_options(self, enum_options): - """Sets the enum_options of this CustomFieldRequest. - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :param enum_options: The enum_options of this CustomFieldRequest. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._enum_options = enum_options - - @property - def enabled(self): - """Gets the enabled of this CustomFieldRequest. # noqa: E501 - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :return: The enabled of this CustomFieldRequest. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this CustomFieldRequest. - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :param enabled: The enabled of this CustomFieldRequest. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def is_formula_field(self): - """Gets the is_formula_field of this CustomFieldRequest. # noqa: E501 - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :return: The is_formula_field of this CustomFieldRequest. # noqa: E501 - :rtype: bool - """ - return self._is_formula_field - - @is_formula_field.setter - def is_formula_field(self, is_formula_field): - """Sets the is_formula_field of this CustomFieldRequest. - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :param is_formula_field: The is_formula_field of this CustomFieldRequest. # noqa: E501 - :type: bool - """ - - self._is_formula_field = is_formula_field - - @property - def date_value(self): - """Gets the date_value of this CustomFieldRequest. # noqa: E501 - - - :return: The date_value of this CustomFieldRequest. # noqa: E501 - :rtype: CustomFieldBaseDateValue - """ - return self._date_value - - @date_value.setter - def date_value(self, date_value): - """Sets the date_value of this CustomFieldRequest. - - - :param date_value: The date_value of this CustomFieldRequest. # noqa: E501 - :type: CustomFieldBaseDateValue - """ - - self._date_value = date_value - - @property - def enum_value(self): - """Gets the enum_value of this CustomFieldRequest. # noqa: E501 - - - :return: The enum_value of this CustomFieldRequest. # noqa: E501 - :rtype: CustomFieldBaseEnumValue - """ - return self._enum_value - - @enum_value.setter - def enum_value(self, enum_value): - """Sets the enum_value of this CustomFieldRequest. - - - :param enum_value: The enum_value of this CustomFieldRequest. # noqa: E501 - :type: CustomFieldBaseEnumValue - """ - - self._enum_value = enum_value - - @property - def multi_enum_values(self): - """Gets the multi_enum_values of this CustomFieldRequest. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :return: The multi_enum_values of this CustomFieldRequest. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._multi_enum_values - - @multi_enum_values.setter - def multi_enum_values(self, multi_enum_values): - """Sets the multi_enum_values of this CustomFieldRequest. - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :param multi_enum_values: The multi_enum_values of this CustomFieldRequest. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._multi_enum_values = multi_enum_values - - @property - def number_value(self): - """Gets the number_value of this CustomFieldRequest. # noqa: E501 - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :return: The number_value of this CustomFieldRequest. # noqa: E501 - :rtype: float - """ - return self._number_value - - @number_value.setter - def number_value(self, number_value): - """Sets the number_value of this CustomFieldRequest. - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :param number_value: The number_value of this CustomFieldRequest. # noqa: E501 - :type: float - """ - - self._number_value = number_value - - @property - def text_value(self): - """Gets the text_value of this CustomFieldRequest. # noqa: E501 - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :return: The text_value of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._text_value - - @text_value.setter - def text_value(self, text_value): - """Sets the text_value of this CustomFieldRequest. - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :param text_value: The text_value of this CustomFieldRequest. # noqa: E501 - :type: str - """ - - self._text_value = text_value - - @property - def display_value(self): - """Gets the display_value of this CustomFieldRequest. # noqa: E501 - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :return: The display_value of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this CustomFieldRequest. - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :param display_value: The display_value of this CustomFieldRequest. # noqa: E501 - :type: str - """ - - self._display_value = display_value - - @property - def description(self): - """Gets the description of this CustomFieldRequest. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The description of the custom field. # noqa: E501 - - :return: The description of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._description - - @description.setter - def description(self, description): - """Sets the description of this CustomFieldRequest. - - [Opt In](/docs/inputoutput-options). The description of the custom field. # noqa: E501 - - :param description: The description of this CustomFieldRequest. # noqa: E501 - :type: str - """ - - self._description = description - - @property - def precision(self): - """Gets the precision of this CustomFieldRequest. # noqa: E501 - - Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. # noqa: E501 - - :return: The precision of this CustomFieldRequest. # noqa: E501 - :rtype: int - """ - return self._precision - - @precision.setter - def precision(self, precision): - """Sets the precision of this CustomFieldRequest. - - Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. # noqa: E501 - - :param precision: The precision of this CustomFieldRequest. # noqa: E501 - :type: int - """ - - self._precision = precision - - @property - def format(self): - """Gets the format of this CustomFieldRequest. # noqa: E501 - - The format of this custom field. # noqa: E501 - - :return: The format of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._format - - @format.setter - def format(self, format): - """Sets the format of this CustomFieldRequest. - - The format of this custom field. # noqa: E501 - - :param format: The format of this CustomFieldRequest. # noqa: E501 - :type: str - """ - allowed_values = ["currency", "identifier", "percentage", "custom", "duration", "none"] # noqa: E501 - if format not in allowed_values: - raise ValueError( - "Invalid value for `format` ({0}), must be one of {1}" # noqa: E501 - .format(format, allowed_values) - ) - - self._format = format - - @property - def currency_code(self): - """Gets the currency_code of this CustomFieldRequest. # noqa: E501 - - ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. # noqa: E501 - - :return: The currency_code of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._currency_code - - @currency_code.setter - def currency_code(self, currency_code): - """Sets the currency_code of this CustomFieldRequest. - - ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. # noqa: E501 - - :param currency_code: The currency_code of this CustomFieldRequest. # noqa: E501 - :type: str - """ - - self._currency_code = currency_code - - @property - def custom_label(self): - """Gets the custom_label of this CustomFieldRequest. # noqa: E501 - - This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. # noqa: E501 - - :return: The custom_label of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._custom_label - - @custom_label.setter - def custom_label(self, custom_label): - """Sets the custom_label of this CustomFieldRequest. - - This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. # noqa: E501 - - :param custom_label: The custom_label of this CustomFieldRequest. # noqa: E501 - :type: str - """ - - self._custom_label = custom_label - - @property - def custom_label_position(self): - """Gets the custom_label_position of this CustomFieldRequest. # noqa: E501 - - Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. # noqa: E501 - - :return: The custom_label_position of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._custom_label_position - - @custom_label_position.setter - def custom_label_position(self, custom_label_position): - """Sets the custom_label_position of this CustomFieldRequest. - - Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. # noqa: E501 - - :param custom_label_position: The custom_label_position of this CustomFieldRequest. # noqa: E501 - :type: str - """ - allowed_values = ["prefix", "suffix", ""] # noqa: E501 - if custom_label_position not in allowed_values: - raise ValueError( - "Invalid value for `custom_label_position` ({0}), must be one of {1}" # noqa: E501 - .format(custom_label_position, allowed_values) - ) - - self._custom_label_position = custom_label_position - - @property - def is_global_to_workspace(self): - """Gets the is_global_to_workspace of this CustomFieldRequest. # noqa: E501 - - This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. # noqa: E501 - - :return: The is_global_to_workspace of this CustomFieldRequest. # noqa: E501 - :rtype: bool - """ - return self._is_global_to_workspace - - @is_global_to_workspace.setter - def is_global_to_workspace(self, is_global_to_workspace): - """Sets the is_global_to_workspace of this CustomFieldRequest. - - This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. # noqa: E501 - - :param is_global_to_workspace: The is_global_to_workspace of this CustomFieldRequest. # noqa: E501 - :type: bool - """ - - self._is_global_to_workspace = is_global_to_workspace - - @property - def has_notifications_enabled(self): - """Gets the has_notifications_enabled of this CustomFieldRequest. # noqa: E501 - - *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. # noqa: E501 - - :return: The has_notifications_enabled of this CustomFieldRequest. # noqa: E501 - :rtype: bool - """ - return self._has_notifications_enabled - - @has_notifications_enabled.setter - def has_notifications_enabled(self, has_notifications_enabled): - """Sets the has_notifications_enabled of this CustomFieldRequest. - - *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. # noqa: E501 - - :param has_notifications_enabled: The has_notifications_enabled of this CustomFieldRequest. # noqa: E501 - :type: bool - """ - - self._has_notifications_enabled = has_notifications_enabled - - @property - def asana_created_field(self): - """Gets the asana_created_field of this CustomFieldRequest. # noqa: E501 - - *Conditional*. A unique identifier to associate this field with the template source of truth. # noqa: E501 - - :return: The asana_created_field of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._asana_created_field - - @asana_created_field.setter - def asana_created_field(self, asana_created_field): - """Sets the asana_created_field of this CustomFieldRequest. - - *Conditional*. A unique identifier to associate this field with the template source of truth. # noqa: E501 - - :param asana_created_field: The asana_created_field of this CustomFieldRequest. # noqa: E501 - :type: str - """ - allowed_values = ["a_v_requirements", "account_name", "actionable", "align_shipping_link", "align_status", "allotted_time", "appointment", "approval_stage", "approved", "article_series", "board_committee", "browser", "campaign_audience", "campaign_project_status", "campaign_regions", "channel_primary", "client_topic_type", "complete_by", "contact", "contact_email_address", "content_channels", "content_channels_needed", "content_stage", "content_type", "contract", "contract_status", "cost", "creation_stage", "creative_channel", "creative_needed", "creative_needs", "data_sensitivity", "deal_size", "delivery_appt", "delivery_appt_date", "department", "department_responsible", "design_request_needed", "design_request_type", "discussion_category", "do_this_task", "editorial_content_status", "editorial_content_tag", "editorial_content_type", "effort", "effort_level", "est_completion_date", "estimated_time", "estimated_value", "expected_cost", "external_steps_needed", "favorite_idea", "feedback_type", "financial", "funding_amount", "grant_application_process", "hiring_candidate_status", "idea_status", "ids_link", "ids_patient_link", "implementation_stage", "insurance", "interview_area", "interview_question_score", "itero_scan_link", "job_s_applied_to", "lab", "launch_status", "lead_status", "localization_language", "localization_market_team", "localization_status", "meeting_minutes", "meeting_needed", "minutes", "mrr", "must_localize", "name_of_foundation", "need_to_follow_up", "next_appointment", "next_steps_sales", "num_people", "number_of_user_reports", "office_location", "onboarding_activity", "owner", "participants_needed", "patient_date_of_birth", "patient_email", "patient_phone", "patient_status", "phone_number", "planning_category", "point_of_contact", "position", "post_format", "prescription", "priority", "priority_level", "product", "product_stage", "progress", "project_size", "project_status", "proposed_budget", "publish_status", "reason_for_scan", "referral", "request_type", "research_status", "responsible_department", "responsible_team", "risk_assessment_status", "room_name", "sales_counterpart", "sentiment", "shipping_link", "social_channels", "stage", "status", "status_design", "status_of_initiative", "system_setup", "task_progress", "team", "team_marketing", "team_responsible", "time_it_takes_to_complete_tasks", "timeframe", "treatment_type", "type_work_requests_it", "use_agency", "user_name", "vendor_category", "vendor_type", "word_count", ""] # noqa: E501 - if asana_created_field not in allowed_values: - raise ValueError( - "Invalid value for `asana_created_field` ({0}), must be one of {1}" # noqa: E501 - .format(asana_created_field, allowed_values) - ) - - self._asana_created_field = asana_created_field - - @property - def workspace(self): - """Gets the workspace of this CustomFieldRequest. # noqa: E501 - - *Create-Only* The workspace to create a custom field in. # noqa: E501 - - :return: The workspace of this CustomFieldRequest. # noqa: E501 - :rtype: str - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this CustomFieldRequest. - - *Create-Only* The workspace to create a custom field in. # noqa: E501 - - :param workspace: The workspace of this CustomFieldRequest. # noqa: E501 - :type: str - """ - if workspace is None: - raise ValueError("Invalid value for `workspace`, must not be `None`") # noqa: E501 - - self._workspace = workspace - - @property - def owned_by_app(self): - """Gets the owned_by_app of this CustomFieldRequest. # noqa: E501 - - *Allow-listed*. Instructs the API that this Custom Field is app-owned. This parameter is allow-listed to specific apps at this point in time. For apps that are not allow-listed, providing this parameter will result in a `403 Forbidden`. # noqa: E501 - - :return: The owned_by_app of this CustomFieldRequest. # noqa: E501 - :rtype: bool - """ - return self._owned_by_app - - @owned_by_app.setter - def owned_by_app(self, owned_by_app): - """Sets the owned_by_app of this CustomFieldRequest. - - *Allow-listed*. Instructs the API that this Custom Field is app-owned. This parameter is allow-listed to specific apps at this point in time. For apps that are not allow-listed, providing this parameter will result in a `403 Forbidden`. # noqa: E501 - - :param owned_by_app: The owned_by_app of this CustomFieldRequest. # noqa: E501 - :type: bool - """ - - self._owned_by_app = owned_by_app - - @property - def people_value(self): - """Gets the people_value of this CustomFieldRequest. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `people`. This array of user GIDs reflects the users to be written to a `people` custom field. Note that *write* operations will replace existing users (if any) in the custom field with the users specified in this array. # noqa: E501 - - :return: The people_value of this CustomFieldRequest. # noqa: E501 - :rtype: list[str] - """ - return self._people_value - - @people_value.setter - def people_value(self, people_value): - """Sets the people_value of this CustomFieldRequest. - - *Conditional*. Only relevant for custom fields of type `people`. This array of user GIDs reflects the users to be written to a `people` custom field. Note that *write* operations will replace existing users (if any) in the custom field with the users specified in this array. # noqa: E501 - - :param people_value: The people_value of this CustomFieldRequest. # noqa: E501 - :type: list[str] - """ - - self._people_value = people_value - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_response.py b/asana/models/custom_field_response.py deleted file mode 100644 index 1b943dfd..00000000 --- a/asana/models/custom_field_response.py +++ /dev/null @@ -1,836 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'type': 'str', - 'enum_options': 'list[CustomFieldBaseEnumOptions]', - 'enabled': 'bool', - 'is_formula_field': 'bool', - 'date_value': 'CustomFieldBaseDateValue', - 'enum_value': 'CustomFieldBaseEnumValue', - 'multi_enum_values': 'list[CustomFieldBaseEnumOptions]', - 'number_value': 'float', - 'text_value': 'str', - 'display_value': 'str', - 'description': 'str', - 'precision': 'int', - 'format': 'str', - 'currency_code': 'str', - 'custom_label': 'str', - 'custom_label_position': 'str', - 'is_global_to_workspace': 'bool', - 'has_notifications_enabled': 'bool', - 'asana_created_field': 'str', - 'is_value_read_only': 'bool', - 'created_by': 'CustomFieldResponseCreatedBy', - 'people_value': 'list[CustomFieldResponsePeopleValue]' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'type': 'type', - 'enum_options': 'enum_options', - 'enabled': 'enabled', - 'is_formula_field': 'is_formula_field', - 'date_value': 'date_value', - 'enum_value': 'enum_value', - 'multi_enum_values': 'multi_enum_values', - 'number_value': 'number_value', - 'text_value': 'text_value', - 'display_value': 'display_value', - 'description': 'description', - 'precision': 'precision', - 'format': 'format', - 'currency_code': 'currency_code', - 'custom_label': 'custom_label', - 'custom_label_position': 'custom_label_position', - 'is_global_to_workspace': 'is_global_to_workspace', - 'has_notifications_enabled': 'has_notifications_enabled', - 'asana_created_field': 'asana_created_field', - 'is_value_read_only': 'is_value_read_only', - 'created_by': 'created_by', - 'people_value': 'people_value' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, type=None, enum_options=None, enabled=None, is_formula_field=None, date_value=None, enum_value=None, multi_enum_values=None, number_value=None, text_value=None, display_value=None, description=None, precision=None, format=None, currency_code=None, custom_label=None, custom_label_position=None, is_global_to_workspace=None, has_notifications_enabled=None, asana_created_field=None, is_value_read_only=None, created_by=None, people_value=None): # noqa: E501 - """CustomFieldResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._type = None - self._enum_options = None - self._enabled = None - self._is_formula_field = None - self._date_value = None - self._enum_value = None - self._multi_enum_values = None - self._number_value = None - self._text_value = None - self._display_value = None - self._description = None - self._precision = None - self._format = None - self._currency_code = None - self._custom_label = None - self._custom_label_position = None - self._is_global_to_workspace = None - self._has_notifications_enabled = None - self._asana_created_field = None - self._is_value_read_only = None - self._created_by = None - self._people_value = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if type is not None: - self.type = type - if enum_options is not None: - self.enum_options = enum_options - if enabled is not None: - self.enabled = enabled - if is_formula_field is not None: - self.is_formula_field = is_formula_field - if date_value is not None: - self.date_value = date_value - if enum_value is not None: - self.enum_value = enum_value - if multi_enum_values is not None: - self.multi_enum_values = multi_enum_values - if number_value is not None: - self.number_value = number_value - if text_value is not None: - self.text_value = text_value - if display_value is not None: - self.display_value = display_value - if description is not None: - self.description = description - if precision is not None: - self.precision = precision - if format is not None: - self.format = format - if currency_code is not None: - self.currency_code = currency_code - if custom_label is not None: - self.custom_label = custom_label - if custom_label_position is not None: - self.custom_label_position = custom_label_position - if is_global_to_workspace is not None: - self.is_global_to_workspace = is_global_to_workspace - if has_notifications_enabled is not None: - self.has_notifications_enabled = has_notifications_enabled - if asana_created_field is not None: - self.asana_created_field = asana_created_field - if is_value_read_only is not None: - self.is_value_read_only = is_value_read_only - if created_by is not None: - self.created_by = created_by - if people_value is not None: - self.people_value = people_value - - @property - def gid(self): - """Gets the gid of this CustomFieldResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this CustomFieldResponse. # noqa: E501 - - The name of the custom field. # noqa: E501 - - :return: The name of this CustomFieldResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this CustomFieldResponse. - - The name of the custom field. # noqa: E501 - - :param name: The name of this CustomFieldResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this CustomFieldResponse. # noqa: E501 - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The resource_subtype of this CustomFieldResponse. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this CustomFieldResponse. - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :param resource_subtype: The resource_subtype of this CustomFieldResponse. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def type(self): - """Gets the type of this CustomFieldResponse. # noqa: E501 - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The type of this CustomFieldResponse. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this CustomFieldResponse. - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :param type: The type of this CustomFieldResponse. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if type not in allowed_values: - raise ValueError( - "Invalid value for `type` ({0}), must be one of {1}" # noqa: E501 - .format(type, allowed_values) - ) - - self._type = type - - @property - def enum_options(self): - """Gets the enum_options of this CustomFieldResponse. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :return: The enum_options of this CustomFieldResponse. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._enum_options - - @enum_options.setter - def enum_options(self, enum_options): - """Sets the enum_options of this CustomFieldResponse. - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :param enum_options: The enum_options of this CustomFieldResponse. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._enum_options = enum_options - - @property - def enabled(self): - """Gets the enabled of this CustomFieldResponse. # noqa: E501 - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :return: The enabled of this CustomFieldResponse. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this CustomFieldResponse. - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :param enabled: The enabled of this CustomFieldResponse. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def is_formula_field(self): - """Gets the is_formula_field of this CustomFieldResponse. # noqa: E501 - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :return: The is_formula_field of this CustomFieldResponse. # noqa: E501 - :rtype: bool - """ - return self._is_formula_field - - @is_formula_field.setter - def is_formula_field(self, is_formula_field): - """Sets the is_formula_field of this CustomFieldResponse. - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :param is_formula_field: The is_formula_field of this CustomFieldResponse. # noqa: E501 - :type: bool - """ - - self._is_formula_field = is_formula_field - - @property - def date_value(self): - """Gets the date_value of this CustomFieldResponse. # noqa: E501 - - - :return: The date_value of this CustomFieldResponse. # noqa: E501 - :rtype: CustomFieldBaseDateValue - """ - return self._date_value - - @date_value.setter - def date_value(self, date_value): - """Sets the date_value of this CustomFieldResponse. - - - :param date_value: The date_value of this CustomFieldResponse. # noqa: E501 - :type: CustomFieldBaseDateValue - """ - - self._date_value = date_value - - @property - def enum_value(self): - """Gets the enum_value of this CustomFieldResponse. # noqa: E501 - - - :return: The enum_value of this CustomFieldResponse. # noqa: E501 - :rtype: CustomFieldBaseEnumValue - """ - return self._enum_value - - @enum_value.setter - def enum_value(self, enum_value): - """Sets the enum_value of this CustomFieldResponse. - - - :param enum_value: The enum_value of this CustomFieldResponse. # noqa: E501 - :type: CustomFieldBaseEnumValue - """ - - self._enum_value = enum_value - - @property - def multi_enum_values(self): - """Gets the multi_enum_values of this CustomFieldResponse. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :return: The multi_enum_values of this CustomFieldResponse. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._multi_enum_values - - @multi_enum_values.setter - def multi_enum_values(self, multi_enum_values): - """Sets the multi_enum_values of this CustomFieldResponse. - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :param multi_enum_values: The multi_enum_values of this CustomFieldResponse. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._multi_enum_values = multi_enum_values - - @property - def number_value(self): - """Gets the number_value of this CustomFieldResponse. # noqa: E501 - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :return: The number_value of this CustomFieldResponse. # noqa: E501 - :rtype: float - """ - return self._number_value - - @number_value.setter - def number_value(self, number_value): - """Sets the number_value of this CustomFieldResponse. - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :param number_value: The number_value of this CustomFieldResponse. # noqa: E501 - :type: float - """ - - self._number_value = number_value - - @property - def text_value(self): - """Gets the text_value of this CustomFieldResponse. # noqa: E501 - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :return: The text_value of this CustomFieldResponse. # noqa: E501 - :rtype: str - """ - return self._text_value - - @text_value.setter - def text_value(self, text_value): - """Sets the text_value of this CustomFieldResponse. - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :param text_value: The text_value of this CustomFieldResponse. # noqa: E501 - :type: str - """ - - self._text_value = text_value - - @property - def display_value(self): - """Gets the display_value of this CustomFieldResponse. # noqa: E501 - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :return: The display_value of this CustomFieldResponse. # noqa: E501 - :rtype: str - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this CustomFieldResponse. - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :param display_value: The display_value of this CustomFieldResponse. # noqa: E501 - :type: str - """ - - self._display_value = display_value - - @property - def description(self): - """Gets the description of this CustomFieldResponse. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The description of the custom field. # noqa: E501 - - :return: The description of this CustomFieldResponse. # noqa: E501 - :rtype: str - """ - return self._description - - @description.setter - def description(self, description): - """Sets the description of this CustomFieldResponse. - - [Opt In](/docs/inputoutput-options). The description of the custom field. # noqa: E501 - - :param description: The description of this CustomFieldResponse. # noqa: E501 - :type: str - """ - - self._description = description - - @property - def precision(self): - """Gets the precision of this CustomFieldResponse. # noqa: E501 - - Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. # noqa: E501 - - :return: The precision of this CustomFieldResponse. # noqa: E501 - :rtype: int - """ - return self._precision - - @precision.setter - def precision(self, precision): - """Sets the precision of this CustomFieldResponse. - - Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. # noqa: E501 - - :param precision: The precision of this CustomFieldResponse. # noqa: E501 - :type: int - """ - - self._precision = precision - - @property - def format(self): - """Gets the format of this CustomFieldResponse. # noqa: E501 - - The format of this custom field. # noqa: E501 - - :return: The format of this CustomFieldResponse. # noqa: E501 - :rtype: str - """ - return self._format - - @format.setter - def format(self, format): - """Sets the format of this CustomFieldResponse. - - The format of this custom field. # noqa: E501 - - :param format: The format of this CustomFieldResponse. # noqa: E501 - :type: str - """ - allowed_values = ["currency", "identifier", "percentage", "custom", "duration", "none"] # noqa: E501 - if format not in allowed_values: - raise ValueError( - "Invalid value for `format` ({0}), must be one of {1}" # noqa: E501 - .format(format, allowed_values) - ) - - self._format = format - - @property - def currency_code(self): - """Gets the currency_code of this CustomFieldResponse. # noqa: E501 - - ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. # noqa: E501 - - :return: The currency_code of this CustomFieldResponse. # noqa: E501 - :rtype: str - """ - return self._currency_code - - @currency_code.setter - def currency_code(self, currency_code): - """Sets the currency_code of this CustomFieldResponse. - - ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. # noqa: E501 - - :param currency_code: The currency_code of this CustomFieldResponse. # noqa: E501 - :type: str - """ - - self._currency_code = currency_code - - @property - def custom_label(self): - """Gets the custom_label of this CustomFieldResponse. # noqa: E501 - - This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. # noqa: E501 - - :return: The custom_label of this CustomFieldResponse. # noqa: E501 - :rtype: str - """ - return self._custom_label - - @custom_label.setter - def custom_label(self, custom_label): - """Sets the custom_label of this CustomFieldResponse. - - This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. # noqa: E501 - - :param custom_label: The custom_label of this CustomFieldResponse. # noqa: E501 - :type: str - """ - - self._custom_label = custom_label - - @property - def custom_label_position(self): - """Gets the custom_label_position of this CustomFieldResponse. # noqa: E501 - - Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. # noqa: E501 - - :return: The custom_label_position of this CustomFieldResponse. # noqa: E501 - :rtype: str - """ - return self._custom_label_position - - @custom_label_position.setter - def custom_label_position(self, custom_label_position): - """Sets the custom_label_position of this CustomFieldResponse. - - Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. # noqa: E501 - - :param custom_label_position: The custom_label_position of this CustomFieldResponse. # noqa: E501 - :type: str - """ - allowed_values = ["prefix", "suffix", ""] # noqa: E501 - if custom_label_position not in allowed_values: - raise ValueError( - "Invalid value for `custom_label_position` ({0}), must be one of {1}" # noqa: E501 - .format(custom_label_position, allowed_values) - ) - - self._custom_label_position = custom_label_position - - @property - def is_global_to_workspace(self): - """Gets the is_global_to_workspace of this CustomFieldResponse. # noqa: E501 - - This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. # noqa: E501 - - :return: The is_global_to_workspace of this CustomFieldResponse. # noqa: E501 - :rtype: bool - """ - return self._is_global_to_workspace - - @is_global_to_workspace.setter - def is_global_to_workspace(self, is_global_to_workspace): - """Sets the is_global_to_workspace of this CustomFieldResponse. - - This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. # noqa: E501 - - :param is_global_to_workspace: The is_global_to_workspace of this CustomFieldResponse. # noqa: E501 - :type: bool - """ - - self._is_global_to_workspace = is_global_to_workspace - - @property - def has_notifications_enabled(self): - """Gets the has_notifications_enabled of this CustomFieldResponse. # noqa: E501 - - *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. # noqa: E501 - - :return: The has_notifications_enabled of this CustomFieldResponse. # noqa: E501 - :rtype: bool - """ - return self._has_notifications_enabled - - @has_notifications_enabled.setter - def has_notifications_enabled(self, has_notifications_enabled): - """Sets the has_notifications_enabled of this CustomFieldResponse. - - *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. # noqa: E501 - - :param has_notifications_enabled: The has_notifications_enabled of this CustomFieldResponse. # noqa: E501 - :type: bool - """ - - self._has_notifications_enabled = has_notifications_enabled - - @property - def asana_created_field(self): - """Gets the asana_created_field of this CustomFieldResponse. # noqa: E501 - - *Conditional*. A unique identifier to associate this field with the template source of truth. # noqa: E501 - - :return: The asana_created_field of this CustomFieldResponse. # noqa: E501 - :rtype: str - """ - return self._asana_created_field - - @asana_created_field.setter - def asana_created_field(self, asana_created_field): - """Sets the asana_created_field of this CustomFieldResponse. - - *Conditional*. A unique identifier to associate this field with the template source of truth. # noqa: E501 - - :param asana_created_field: The asana_created_field of this CustomFieldResponse. # noqa: E501 - :type: str - """ - allowed_values = ["a_v_requirements", "account_name", "actionable", "align_shipping_link", "align_status", "allotted_time", "appointment", "approval_stage", "approved", "article_series", "board_committee", "browser", "campaign_audience", "campaign_project_status", "campaign_regions", "channel_primary", "client_topic_type", "complete_by", "contact", "contact_email_address", "content_channels", "content_channels_needed", "content_stage", "content_type", "contract", "contract_status", "cost", "creation_stage", "creative_channel", "creative_needed", "creative_needs", "data_sensitivity", "deal_size", "delivery_appt", "delivery_appt_date", "department", "department_responsible", "design_request_needed", "design_request_type", "discussion_category", "do_this_task", "editorial_content_status", "editorial_content_tag", "editorial_content_type", "effort", "effort_level", "est_completion_date", "estimated_time", "estimated_value", "expected_cost", "external_steps_needed", "favorite_idea", "feedback_type", "financial", "funding_amount", "grant_application_process", "hiring_candidate_status", "idea_status", "ids_link", "ids_patient_link", "implementation_stage", "insurance", "interview_area", "interview_question_score", "itero_scan_link", "job_s_applied_to", "lab", "launch_status", "lead_status", "localization_language", "localization_market_team", "localization_status", "meeting_minutes", "meeting_needed", "minutes", "mrr", "must_localize", "name_of_foundation", "need_to_follow_up", "next_appointment", "next_steps_sales", "num_people", "number_of_user_reports", "office_location", "onboarding_activity", "owner", "participants_needed", "patient_date_of_birth", "patient_email", "patient_phone", "patient_status", "phone_number", "planning_category", "point_of_contact", "position", "post_format", "prescription", "priority", "priority_level", "product", "product_stage", "progress", "project_size", "project_status", "proposed_budget", "publish_status", "reason_for_scan", "referral", "request_type", "research_status", "responsible_department", "responsible_team", "risk_assessment_status", "room_name", "sales_counterpart", "sentiment", "shipping_link", "social_channels", "stage", "status", "status_design", "status_of_initiative", "system_setup", "task_progress", "team", "team_marketing", "team_responsible", "time_it_takes_to_complete_tasks", "timeframe", "treatment_type", "type_work_requests_it", "use_agency", "user_name", "vendor_category", "vendor_type", "word_count", ""] # noqa: E501 - if asana_created_field not in allowed_values: - raise ValueError( - "Invalid value for `asana_created_field` ({0}), must be one of {1}" # noqa: E501 - .format(asana_created_field, allowed_values) - ) - - self._asana_created_field = asana_created_field - - @property - def is_value_read_only(self): - """Gets the is_value_read_only of this CustomFieldResponse. # noqa: E501 - - *Conditional*. This flag describes whether a custom field is read only. # noqa: E501 - - :return: The is_value_read_only of this CustomFieldResponse. # noqa: E501 - :rtype: bool - """ - return self._is_value_read_only - - @is_value_read_only.setter - def is_value_read_only(self, is_value_read_only): - """Sets the is_value_read_only of this CustomFieldResponse. - - *Conditional*. This flag describes whether a custom field is read only. # noqa: E501 - - :param is_value_read_only: The is_value_read_only of this CustomFieldResponse. # noqa: E501 - :type: bool - """ - - self._is_value_read_only = is_value_read_only - - @property - def created_by(self): - """Gets the created_by of this CustomFieldResponse. # noqa: E501 - - - :return: The created_by of this CustomFieldResponse. # noqa: E501 - :rtype: CustomFieldResponseCreatedBy - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this CustomFieldResponse. - - - :param created_by: The created_by of this CustomFieldResponse. # noqa: E501 - :type: CustomFieldResponseCreatedBy - """ - - self._created_by = created_by - - @property - def people_value(self): - """Gets the people_value of this CustomFieldResponse. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `people`. This array of [compact user](/reference/users) objects reflects the values of a `people` custom field. # noqa: E501 - - :return: The people_value of this CustomFieldResponse. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._people_value - - @people_value.setter - def people_value(self, people_value): - """Sets the people_value of this CustomFieldResponse. - - *Conditional*. Only relevant for custom fields of type `people`. This array of [compact user](/reference/users) objects reflects the values of a `people` custom field. # noqa: E501 - - :param people_value: The people_value of this CustomFieldResponse. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._people_value = people_value - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_response_array.py b/asana/models/custom_field_response_array.py deleted file mode 100644 index 157e60ac..00000000 --- a/asana/models/custom_field_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[CustomFieldResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """CustomFieldResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this CustomFieldResponseArray. # noqa: E501 - - - :return: The data of this CustomFieldResponseArray. # noqa: E501 - :rtype: list[CustomFieldResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this CustomFieldResponseArray. - - - :param data: The data of this CustomFieldResponseArray. # noqa: E501 - :type: list[CustomFieldResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this CustomFieldResponseArray. # noqa: E501 - - - :return: The next_page of this CustomFieldResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this CustomFieldResponseArray. - - - :param next_page: The next_page of this CustomFieldResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_response_created_by.py b/asana/models/custom_field_response_created_by.py deleted file mode 100644 index 5beb68e6..00000000 --- a/asana/models/custom_field_response_created_by.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldResponseCreatedBy(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """CustomFieldResponseCreatedBy - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this CustomFieldResponseCreatedBy. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldResponseCreatedBy. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldResponseCreatedBy. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldResponseCreatedBy. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldResponseCreatedBy. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldResponseCreatedBy. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldResponseCreatedBy. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldResponseCreatedBy. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this CustomFieldResponseCreatedBy. # noqa: E501 - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :return: The name of this CustomFieldResponseCreatedBy. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this CustomFieldResponseCreatedBy. - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :param name: The name of this CustomFieldResponseCreatedBy. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldResponseCreatedBy, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldResponseCreatedBy): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_response_data.py b/asana/models/custom_field_response_data.py deleted file mode 100644 index 3376b4eb..00000000 --- a/asana/models/custom_field_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'CustomFieldResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """CustomFieldResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this CustomFieldResponseData. # noqa: E501 - - - :return: The data of this CustomFieldResponseData. # noqa: E501 - :rtype: CustomFieldResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this CustomFieldResponseData. - - - :param data: The data of this CustomFieldResponseData. # noqa: E501 - :type: CustomFieldResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_response_people_value.py b/asana/models/custom_field_response_people_value.py deleted file mode 100644 index 714aef9d..00000000 --- a/asana/models/custom_field_response_people_value.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldResponsePeopleValue(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """CustomFieldResponsePeopleValue - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this CustomFieldResponsePeopleValue. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldResponsePeopleValue. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldResponsePeopleValue. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldResponsePeopleValue. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldResponsePeopleValue. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldResponsePeopleValue. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldResponsePeopleValue. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldResponsePeopleValue. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this CustomFieldResponsePeopleValue. # noqa: E501 - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :return: The name of this CustomFieldResponsePeopleValue. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this CustomFieldResponsePeopleValue. - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :param name: The name of this CustomFieldResponsePeopleValue. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldResponsePeopleValue, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldResponsePeopleValue): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_setting_base.py b/asana/models/custom_field_setting_base.py deleted file mode 100644 index 6b3f7e4f..00000000 --- a/asana/models/custom_field_setting_base.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldSettingBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type' - } - - def __init__(self, gid=None, resource_type=None): # noqa: E501 - """CustomFieldSettingBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - - @property - def gid(self): - """Gets the gid of this CustomFieldSettingBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldSettingBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldSettingBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldSettingBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldSettingBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldSettingBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldSettingBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldSettingBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldSettingBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldSettingBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_setting_compact.py b/asana/models/custom_field_setting_compact.py deleted file mode 100644 index 08bc295e..00000000 --- a/asana/models/custom_field_setting_compact.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldSettingCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type' - } - - def __init__(self, gid=None, resource_type=None): # noqa: E501 - """CustomFieldSettingCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - - @property - def gid(self): - """Gets the gid of this CustomFieldSettingCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldSettingCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldSettingCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldSettingCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldSettingCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldSettingCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldSettingCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldSettingCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldSettingCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldSettingCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_setting_response.py b/asana/models/custom_field_setting_response.py deleted file mode 100644 index 8fb2b1f8..00000000 --- a/asana/models/custom_field_setting_response.py +++ /dev/null @@ -1,246 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldSettingResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'project': 'CustomFieldSettingResponseProject', - 'is_important': 'bool', - 'parent': 'CustomFieldSettingResponseParent', - 'custom_field': 'CustomFieldSettingResponseCustomField' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'project': 'project', - 'is_important': 'is_important', - 'parent': 'parent', - 'custom_field': 'custom_field' - } - - def __init__(self, gid=None, resource_type=None, project=None, is_important=None, parent=None, custom_field=None): # noqa: E501 - """CustomFieldSettingResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._project = None - self._is_important = None - self._parent = None - self._custom_field = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if project is not None: - self.project = project - if is_important is not None: - self.is_important = is_important - if parent is not None: - self.parent = parent - if custom_field is not None: - self.custom_field = custom_field - - @property - def gid(self): - """Gets the gid of this CustomFieldSettingResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldSettingResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldSettingResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldSettingResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldSettingResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldSettingResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldSettingResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldSettingResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def project(self): - """Gets the project of this CustomFieldSettingResponse. # noqa: E501 - - - :return: The project of this CustomFieldSettingResponse. # noqa: E501 - :rtype: CustomFieldSettingResponseProject - """ - return self._project - - @project.setter - def project(self, project): - """Sets the project of this CustomFieldSettingResponse. - - - :param project: The project of this CustomFieldSettingResponse. # noqa: E501 - :type: CustomFieldSettingResponseProject - """ - - self._project = project - - @property - def is_important(self): - """Gets the is_important of this CustomFieldSettingResponse. # noqa: E501 - - `is_important` is used in the Asana web application to determine if this custom field is displayed in the list/grid view of a project or portfolio. # noqa: E501 - - :return: The is_important of this CustomFieldSettingResponse. # noqa: E501 - :rtype: bool - """ - return self._is_important - - @is_important.setter - def is_important(self, is_important): - """Sets the is_important of this CustomFieldSettingResponse. - - `is_important` is used in the Asana web application to determine if this custom field is displayed in the list/grid view of a project or portfolio. # noqa: E501 - - :param is_important: The is_important of this CustomFieldSettingResponse. # noqa: E501 - :type: bool - """ - - self._is_important = is_important - - @property - def parent(self): - """Gets the parent of this CustomFieldSettingResponse. # noqa: E501 - - - :return: The parent of this CustomFieldSettingResponse. # noqa: E501 - :rtype: CustomFieldSettingResponseParent - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this CustomFieldSettingResponse. - - - :param parent: The parent of this CustomFieldSettingResponse. # noqa: E501 - :type: CustomFieldSettingResponseParent - """ - - self._parent = parent - - @property - def custom_field(self): - """Gets the custom_field of this CustomFieldSettingResponse. # noqa: E501 - - - :return: The custom_field of this CustomFieldSettingResponse. # noqa: E501 - :rtype: CustomFieldSettingResponseCustomField - """ - return self._custom_field - - @custom_field.setter - def custom_field(self, custom_field): - """Sets the custom_field of this CustomFieldSettingResponse. - - - :param custom_field: The custom_field of this CustomFieldSettingResponse. # noqa: E501 - :type: CustomFieldSettingResponseCustomField - """ - - self._custom_field = custom_field - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldSettingResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldSettingResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_setting_response_array.py b/asana/models/custom_field_setting_response_array.py deleted file mode 100644 index db1853d0..00000000 --- a/asana/models/custom_field_setting_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldSettingResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[CustomFieldSettingResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """CustomFieldSettingResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this CustomFieldSettingResponseArray. # noqa: E501 - - - :return: The data of this CustomFieldSettingResponseArray. # noqa: E501 - :rtype: list[CustomFieldSettingResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this CustomFieldSettingResponseArray. - - - :param data: The data of this CustomFieldSettingResponseArray. # noqa: E501 - :type: list[CustomFieldSettingResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this CustomFieldSettingResponseArray. # noqa: E501 - - - :return: The next_page of this CustomFieldSettingResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this CustomFieldSettingResponseArray. - - - :param next_page: The next_page of this CustomFieldSettingResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldSettingResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldSettingResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_setting_response_custom_field.py b/asana/models/custom_field_setting_response_custom_field.py deleted file mode 100644 index 0b56e78e..00000000 --- a/asana/models/custom_field_setting_response_custom_field.py +++ /dev/null @@ -1,836 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldSettingResponseCustomField(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'type': 'str', - 'enum_options': 'list[CustomFieldBaseEnumOptions]', - 'enabled': 'bool', - 'is_formula_field': 'bool', - 'date_value': 'CustomFieldBaseDateValue', - 'enum_value': 'CustomFieldBaseEnumValue', - 'multi_enum_values': 'list[CustomFieldBaseEnumOptions]', - 'number_value': 'float', - 'text_value': 'str', - 'display_value': 'str', - 'description': 'str', - 'precision': 'int', - 'format': 'str', - 'currency_code': 'str', - 'custom_label': 'str', - 'custom_label_position': 'str', - 'is_global_to_workspace': 'bool', - 'has_notifications_enabled': 'bool', - 'asana_created_field': 'str', - 'is_value_read_only': 'bool', - 'created_by': 'CustomFieldResponseCreatedBy', - 'people_value': 'list[CustomFieldResponsePeopleValue]' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'type': 'type', - 'enum_options': 'enum_options', - 'enabled': 'enabled', - 'is_formula_field': 'is_formula_field', - 'date_value': 'date_value', - 'enum_value': 'enum_value', - 'multi_enum_values': 'multi_enum_values', - 'number_value': 'number_value', - 'text_value': 'text_value', - 'display_value': 'display_value', - 'description': 'description', - 'precision': 'precision', - 'format': 'format', - 'currency_code': 'currency_code', - 'custom_label': 'custom_label', - 'custom_label_position': 'custom_label_position', - 'is_global_to_workspace': 'is_global_to_workspace', - 'has_notifications_enabled': 'has_notifications_enabled', - 'asana_created_field': 'asana_created_field', - 'is_value_read_only': 'is_value_read_only', - 'created_by': 'created_by', - 'people_value': 'people_value' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, type=None, enum_options=None, enabled=None, is_formula_field=None, date_value=None, enum_value=None, multi_enum_values=None, number_value=None, text_value=None, display_value=None, description=None, precision=None, format=None, currency_code=None, custom_label=None, custom_label_position=None, is_global_to_workspace=None, has_notifications_enabled=None, asana_created_field=None, is_value_read_only=None, created_by=None, people_value=None): # noqa: E501 - """CustomFieldSettingResponseCustomField - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._type = None - self._enum_options = None - self._enabled = None - self._is_formula_field = None - self._date_value = None - self._enum_value = None - self._multi_enum_values = None - self._number_value = None - self._text_value = None - self._display_value = None - self._description = None - self._precision = None - self._format = None - self._currency_code = None - self._custom_label = None - self._custom_label_position = None - self._is_global_to_workspace = None - self._has_notifications_enabled = None - self._asana_created_field = None - self._is_value_read_only = None - self._created_by = None - self._people_value = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if type is not None: - self.type = type - if enum_options is not None: - self.enum_options = enum_options - if enabled is not None: - self.enabled = enabled - if is_formula_field is not None: - self.is_formula_field = is_formula_field - if date_value is not None: - self.date_value = date_value - if enum_value is not None: - self.enum_value = enum_value - if multi_enum_values is not None: - self.multi_enum_values = multi_enum_values - if number_value is not None: - self.number_value = number_value - if text_value is not None: - self.text_value = text_value - if display_value is not None: - self.display_value = display_value - if description is not None: - self.description = description - if precision is not None: - self.precision = precision - if format is not None: - self.format = format - if currency_code is not None: - self.currency_code = currency_code - if custom_label is not None: - self.custom_label = custom_label - if custom_label_position is not None: - self.custom_label_position = custom_label_position - if is_global_to_workspace is not None: - self.is_global_to_workspace = is_global_to_workspace - if has_notifications_enabled is not None: - self.has_notifications_enabled = has_notifications_enabled - if asana_created_field is not None: - self.asana_created_field = asana_created_field - if is_value_read_only is not None: - self.is_value_read_only = is_value_read_only - if created_by is not None: - self.created_by = created_by - if people_value is not None: - self.people_value = people_value - - @property - def gid(self): - """Gets the gid of this CustomFieldSettingResponseCustomField. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldSettingResponseCustomField. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldSettingResponseCustomField. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldSettingResponseCustomField. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this CustomFieldSettingResponseCustomField. # noqa: E501 - - The name of the custom field. # noqa: E501 - - :return: The name of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this CustomFieldSettingResponseCustomField. - - The name of the custom field. # noqa: E501 - - :param name: The name of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this CustomFieldSettingResponseCustomField. # noqa: E501 - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The resource_subtype of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this CustomFieldSettingResponseCustomField. - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :param resource_subtype: The resource_subtype of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def type(self): - """Gets the type of this CustomFieldSettingResponseCustomField. # noqa: E501 - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The type of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this CustomFieldSettingResponseCustomField. - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :param type: The type of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if type not in allowed_values: - raise ValueError( - "Invalid value for `type` ({0}), must be one of {1}" # noqa: E501 - .format(type, allowed_values) - ) - - self._type = type - - @property - def enum_options(self): - """Gets the enum_options of this CustomFieldSettingResponseCustomField. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :return: The enum_options of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._enum_options - - @enum_options.setter - def enum_options(self, enum_options): - """Sets the enum_options of this CustomFieldSettingResponseCustomField. - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :param enum_options: The enum_options of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._enum_options = enum_options - - @property - def enabled(self): - """Gets the enabled of this CustomFieldSettingResponseCustomField. # noqa: E501 - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :return: The enabled of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this CustomFieldSettingResponseCustomField. - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :param enabled: The enabled of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def is_formula_field(self): - """Gets the is_formula_field of this CustomFieldSettingResponseCustomField. # noqa: E501 - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :return: The is_formula_field of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: bool - """ - return self._is_formula_field - - @is_formula_field.setter - def is_formula_field(self, is_formula_field): - """Sets the is_formula_field of this CustomFieldSettingResponseCustomField. - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :param is_formula_field: The is_formula_field of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: bool - """ - - self._is_formula_field = is_formula_field - - @property - def date_value(self): - """Gets the date_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - - - :return: The date_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: CustomFieldBaseDateValue - """ - return self._date_value - - @date_value.setter - def date_value(self, date_value): - """Sets the date_value of this CustomFieldSettingResponseCustomField. - - - :param date_value: The date_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: CustomFieldBaseDateValue - """ - - self._date_value = date_value - - @property - def enum_value(self): - """Gets the enum_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - - - :return: The enum_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: CustomFieldBaseEnumValue - """ - return self._enum_value - - @enum_value.setter - def enum_value(self, enum_value): - """Sets the enum_value of this CustomFieldSettingResponseCustomField. - - - :param enum_value: The enum_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: CustomFieldBaseEnumValue - """ - - self._enum_value = enum_value - - @property - def multi_enum_values(self): - """Gets the multi_enum_values of this CustomFieldSettingResponseCustomField. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :return: The multi_enum_values of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._multi_enum_values - - @multi_enum_values.setter - def multi_enum_values(self, multi_enum_values): - """Sets the multi_enum_values of this CustomFieldSettingResponseCustomField. - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :param multi_enum_values: The multi_enum_values of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._multi_enum_values = multi_enum_values - - @property - def number_value(self): - """Gets the number_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :return: The number_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: float - """ - return self._number_value - - @number_value.setter - def number_value(self, number_value): - """Sets the number_value of this CustomFieldSettingResponseCustomField. - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :param number_value: The number_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: float - """ - - self._number_value = number_value - - @property - def text_value(self): - """Gets the text_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :return: The text_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._text_value - - @text_value.setter - def text_value(self, text_value): - """Sets the text_value of this CustomFieldSettingResponseCustomField. - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :param text_value: The text_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: str - """ - - self._text_value = text_value - - @property - def display_value(self): - """Gets the display_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :return: The display_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this CustomFieldSettingResponseCustomField. - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :param display_value: The display_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: str - """ - - self._display_value = display_value - - @property - def description(self): - """Gets the description of this CustomFieldSettingResponseCustomField. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The description of the custom field. # noqa: E501 - - :return: The description of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._description - - @description.setter - def description(self, description): - """Sets the description of this CustomFieldSettingResponseCustomField. - - [Opt In](/docs/inputoutput-options). The description of the custom field. # noqa: E501 - - :param description: The description of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: str - """ - - self._description = description - - @property - def precision(self): - """Gets the precision of this CustomFieldSettingResponseCustomField. # noqa: E501 - - Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. # noqa: E501 - - :return: The precision of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: int - """ - return self._precision - - @precision.setter - def precision(self, precision): - """Sets the precision of this CustomFieldSettingResponseCustomField. - - Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. # noqa: E501 - - :param precision: The precision of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: int - """ - - self._precision = precision - - @property - def format(self): - """Gets the format of this CustomFieldSettingResponseCustomField. # noqa: E501 - - The format of this custom field. # noqa: E501 - - :return: The format of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._format - - @format.setter - def format(self, format): - """Sets the format of this CustomFieldSettingResponseCustomField. - - The format of this custom field. # noqa: E501 - - :param format: The format of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: str - """ - allowed_values = ["currency", "identifier", "percentage", "custom", "duration", "none"] # noqa: E501 - if format not in allowed_values: - raise ValueError( - "Invalid value for `format` ({0}), must be one of {1}" # noqa: E501 - .format(format, allowed_values) - ) - - self._format = format - - @property - def currency_code(self): - """Gets the currency_code of this CustomFieldSettingResponseCustomField. # noqa: E501 - - ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. # noqa: E501 - - :return: The currency_code of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._currency_code - - @currency_code.setter - def currency_code(self, currency_code): - """Sets the currency_code of this CustomFieldSettingResponseCustomField. - - ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. # noqa: E501 - - :param currency_code: The currency_code of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: str - """ - - self._currency_code = currency_code - - @property - def custom_label(self): - """Gets the custom_label of this CustomFieldSettingResponseCustomField. # noqa: E501 - - This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. # noqa: E501 - - :return: The custom_label of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._custom_label - - @custom_label.setter - def custom_label(self, custom_label): - """Sets the custom_label of this CustomFieldSettingResponseCustomField. - - This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. # noqa: E501 - - :param custom_label: The custom_label of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: str - """ - - self._custom_label = custom_label - - @property - def custom_label_position(self): - """Gets the custom_label_position of this CustomFieldSettingResponseCustomField. # noqa: E501 - - Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. # noqa: E501 - - :return: The custom_label_position of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._custom_label_position - - @custom_label_position.setter - def custom_label_position(self, custom_label_position): - """Sets the custom_label_position of this CustomFieldSettingResponseCustomField. - - Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. # noqa: E501 - - :param custom_label_position: The custom_label_position of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: str - """ - allowed_values = ["prefix", "suffix", ""] # noqa: E501 - if custom_label_position not in allowed_values: - raise ValueError( - "Invalid value for `custom_label_position` ({0}), must be one of {1}" # noqa: E501 - .format(custom_label_position, allowed_values) - ) - - self._custom_label_position = custom_label_position - - @property - def is_global_to_workspace(self): - """Gets the is_global_to_workspace of this CustomFieldSettingResponseCustomField. # noqa: E501 - - This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. # noqa: E501 - - :return: The is_global_to_workspace of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: bool - """ - return self._is_global_to_workspace - - @is_global_to_workspace.setter - def is_global_to_workspace(self, is_global_to_workspace): - """Sets the is_global_to_workspace of this CustomFieldSettingResponseCustomField. - - This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. # noqa: E501 - - :param is_global_to_workspace: The is_global_to_workspace of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: bool - """ - - self._is_global_to_workspace = is_global_to_workspace - - @property - def has_notifications_enabled(self): - """Gets the has_notifications_enabled of this CustomFieldSettingResponseCustomField. # noqa: E501 - - *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. # noqa: E501 - - :return: The has_notifications_enabled of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: bool - """ - return self._has_notifications_enabled - - @has_notifications_enabled.setter - def has_notifications_enabled(self, has_notifications_enabled): - """Sets the has_notifications_enabled of this CustomFieldSettingResponseCustomField. - - *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. # noqa: E501 - - :param has_notifications_enabled: The has_notifications_enabled of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: bool - """ - - self._has_notifications_enabled = has_notifications_enabled - - @property - def asana_created_field(self): - """Gets the asana_created_field of this CustomFieldSettingResponseCustomField. # noqa: E501 - - *Conditional*. A unique identifier to associate this field with the template source of truth. # noqa: E501 - - :return: The asana_created_field of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._asana_created_field - - @asana_created_field.setter - def asana_created_field(self, asana_created_field): - """Sets the asana_created_field of this CustomFieldSettingResponseCustomField. - - *Conditional*. A unique identifier to associate this field with the template source of truth. # noqa: E501 - - :param asana_created_field: The asana_created_field of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: str - """ - allowed_values = ["a_v_requirements", "account_name", "actionable", "align_shipping_link", "align_status", "allotted_time", "appointment", "approval_stage", "approved", "article_series", "board_committee", "browser", "campaign_audience", "campaign_project_status", "campaign_regions", "channel_primary", "client_topic_type", "complete_by", "contact", "contact_email_address", "content_channels", "content_channels_needed", "content_stage", "content_type", "contract", "contract_status", "cost", "creation_stage", "creative_channel", "creative_needed", "creative_needs", "data_sensitivity", "deal_size", "delivery_appt", "delivery_appt_date", "department", "department_responsible", "design_request_needed", "design_request_type", "discussion_category", "do_this_task", "editorial_content_status", "editorial_content_tag", "editorial_content_type", "effort", "effort_level", "est_completion_date", "estimated_time", "estimated_value", "expected_cost", "external_steps_needed", "favorite_idea", "feedback_type", "financial", "funding_amount", "grant_application_process", "hiring_candidate_status", "idea_status", "ids_link", "ids_patient_link", "implementation_stage", "insurance", "interview_area", "interview_question_score", "itero_scan_link", "job_s_applied_to", "lab", "launch_status", "lead_status", "localization_language", "localization_market_team", "localization_status", "meeting_minutes", "meeting_needed", "minutes", "mrr", "must_localize", "name_of_foundation", "need_to_follow_up", "next_appointment", "next_steps_sales", "num_people", "number_of_user_reports", "office_location", "onboarding_activity", "owner", "participants_needed", "patient_date_of_birth", "patient_email", "patient_phone", "patient_status", "phone_number", "planning_category", "point_of_contact", "position", "post_format", "prescription", "priority", "priority_level", "product", "product_stage", "progress", "project_size", "project_status", "proposed_budget", "publish_status", "reason_for_scan", "referral", "request_type", "research_status", "responsible_department", "responsible_team", "risk_assessment_status", "room_name", "sales_counterpart", "sentiment", "shipping_link", "social_channels", "stage", "status", "status_design", "status_of_initiative", "system_setup", "task_progress", "team", "team_marketing", "team_responsible", "time_it_takes_to_complete_tasks", "timeframe", "treatment_type", "type_work_requests_it", "use_agency", "user_name", "vendor_category", "vendor_type", "word_count", ""] # noqa: E501 - if asana_created_field not in allowed_values: - raise ValueError( - "Invalid value for `asana_created_field` ({0}), must be one of {1}" # noqa: E501 - .format(asana_created_field, allowed_values) - ) - - self._asana_created_field = asana_created_field - - @property - def is_value_read_only(self): - """Gets the is_value_read_only of this CustomFieldSettingResponseCustomField. # noqa: E501 - - *Conditional*. This flag describes whether a custom field is read only. # noqa: E501 - - :return: The is_value_read_only of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: bool - """ - return self._is_value_read_only - - @is_value_read_only.setter - def is_value_read_only(self, is_value_read_only): - """Sets the is_value_read_only of this CustomFieldSettingResponseCustomField. - - *Conditional*. This flag describes whether a custom field is read only. # noqa: E501 - - :param is_value_read_only: The is_value_read_only of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: bool - """ - - self._is_value_read_only = is_value_read_only - - @property - def created_by(self): - """Gets the created_by of this CustomFieldSettingResponseCustomField. # noqa: E501 - - - :return: The created_by of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: CustomFieldResponseCreatedBy - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this CustomFieldSettingResponseCustomField. - - - :param created_by: The created_by of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: CustomFieldResponseCreatedBy - """ - - self._created_by = created_by - - @property - def people_value(self): - """Gets the people_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `people`. This array of [compact user](/reference/users) objects reflects the values of a `people` custom field. # noqa: E501 - - :return: The people_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._people_value - - @people_value.setter - def people_value(self, people_value): - """Sets the people_value of this CustomFieldSettingResponseCustomField. - - *Conditional*. Only relevant for custom fields of type `people`. This array of [compact user](/reference/users) objects reflects the values of a `people` custom field. # noqa: E501 - - :param people_value: The people_value of this CustomFieldSettingResponseCustomField. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._people_value = people_value - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldSettingResponseCustomField, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldSettingResponseCustomField): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_setting_response_data.py b/asana/models/custom_field_setting_response_data.py deleted file mode 100644 index e5996862..00000000 --- a/asana/models/custom_field_setting_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldSettingResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'CustomFieldSettingResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """CustomFieldSettingResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this CustomFieldSettingResponseData. # noqa: E501 - - - :return: The data of this CustomFieldSettingResponseData. # noqa: E501 - :rtype: CustomFieldSettingResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this CustomFieldSettingResponseData. - - - :param data: The data of this CustomFieldSettingResponseData. # noqa: E501 - :type: CustomFieldSettingResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldSettingResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldSettingResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_setting_response_parent.py b/asana/models/custom_field_setting_response_parent.py deleted file mode 100644 index 931b1428..00000000 --- a/asana/models/custom_field_setting_response_parent.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldSettingResponseParent(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """CustomFieldSettingResponseParent - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this CustomFieldSettingResponseParent. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldSettingResponseParent. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldSettingResponseParent. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldSettingResponseParent. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldSettingResponseParent. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldSettingResponseParent. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldSettingResponseParent. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldSettingResponseParent. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this CustomFieldSettingResponseParent. # noqa: E501 - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this CustomFieldSettingResponseParent. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this CustomFieldSettingResponseParent. - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this CustomFieldSettingResponseParent. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldSettingResponseParent, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldSettingResponseParent): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_field_setting_response_project.py b/asana/models/custom_field_setting_response_project.py deleted file mode 100644 index cf7deca0..00000000 --- a/asana/models/custom_field_setting_response_project.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldSettingResponseProject(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """CustomFieldSettingResponseProject - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this CustomFieldSettingResponseProject. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this CustomFieldSettingResponseProject. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this CustomFieldSettingResponseProject. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this CustomFieldSettingResponseProject. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this CustomFieldSettingResponseProject. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this CustomFieldSettingResponseProject. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this CustomFieldSettingResponseProject. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this CustomFieldSettingResponseProject. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this CustomFieldSettingResponseProject. # noqa: E501 - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this CustomFieldSettingResponseProject. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this CustomFieldSettingResponseProject. - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this CustomFieldSettingResponseProject. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldSettingResponseProject, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldSettingResponseProject): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_fields_body.py b/asana/models/custom_fields_body.py deleted file mode 100644 index 3b17d36a..00000000 --- a/asana/models/custom_fields_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'CustomFieldRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """CustomFieldsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this CustomFieldsBody. # noqa: E501 - - - :return: The data of this CustomFieldsBody. # noqa: E501 - :rtype: CustomFieldRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this CustomFieldsBody. - - - :param data: The data of this CustomFieldsBody. # noqa: E501 - :type: CustomFieldRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/custom_fields_custom_field_gid_body.py b/asana/models/custom_fields_custom_field_gid_body.py deleted file mode 100644 index 8bd76e8e..00000000 --- a/asana/models/custom_fields_custom_field_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class CustomFieldsCustomFieldGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'CustomFieldRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """CustomFieldsCustomFieldGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this CustomFieldsCustomFieldGidBody. # noqa: E501 - - - :return: The data of this CustomFieldsCustomFieldGidBody. # noqa: E501 - :rtype: CustomFieldRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this CustomFieldsCustomFieldGidBody. - - - :param data: The data of this CustomFieldsCustomFieldGidBody. # noqa: E501 - :type: CustomFieldRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(CustomFieldsCustomFieldGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, CustomFieldsCustomFieldGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/date_variable_compact.py b/asana/models/date_variable_compact.py deleted file mode 100644 index 97a21dfe..00000000 --- a/asana/models/date_variable_compact.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class DateVariableCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'name': 'str', - 'description': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'name': 'name', - 'description': 'description' - } - - def __init__(self, gid=None, name=None, description=None): # noqa: E501 - """DateVariableCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._name = None - self._description = None - self.discriminator = None - if gid is not None: - self.gid = gid - if name is not None: - self.name = name - if description is not None: - self.description = description - - @property - def gid(self): - """Gets the gid of this DateVariableCompact. # noqa: E501 - - Globally unique identifier of the date field in the project template. A value of `1` refers to the project start date, while `2` refers to the project due date. # noqa: E501 - - :return: The gid of this DateVariableCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this DateVariableCompact. - - Globally unique identifier of the date field in the project template. A value of `1` refers to the project start date, while `2` refers to the project due date. # noqa: E501 - - :param gid: The gid of this DateVariableCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def name(self): - """Gets the name of this DateVariableCompact. # noqa: E501 - - The name of the date variable. # noqa: E501 - - :return: The name of this DateVariableCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this DateVariableCompact. - - The name of the date variable. # noqa: E501 - - :param name: The name of this DateVariableCompact. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def description(self): - """Gets the description of this DateVariableCompact. # noqa: E501 - - The description of what the date variable is used for when instantiating a project. # noqa: E501 - - :return: The description of this DateVariableCompact. # noqa: E501 - :rtype: str - """ - return self._description - - @description.setter - def description(self, description): - """Sets the description of this DateVariableCompact. - - The description of what the date variable is used for when instantiating a project. # noqa: E501 - - :param description: The description of this DateVariableCompact. # noqa: E501 - :type: str - """ - - self._description = description - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(DateVariableCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, DateVariableCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/date_variable_request.py b/asana/models/date_variable_request.py deleted file mode 100644 index 28d9ed2b..00000000 --- a/asana/models/date_variable_request.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class DateVariableRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'value': 'datetime' - } - - attribute_map = { - 'gid': 'gid', - 'value': 'value' - } - - def __init__(self, gid=None, value=None): # noqa: E501 - """DateVariableRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._value = None - self.discriminator = None - if gid is not None: - self.gid = gid - if value is not None: - self.value = value - - @property - def gid(self): - """Gets the gid of this DateVariableRequest. # noqa: E501 - - Globally unique identifier of the date field in the project template. A value of `1` refers to the project start date, while `2` refers to the project due date. # noqa: E501 - - :return: The gid of this DateVariableRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this DateVariableRequest. - - Globally unique identifier of the date field in the project template. A value of `1` refers to the project start date, while `2` refers to the project due date. # noqa: E501 - - :param gid: The gid of this DateVariableRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def value(self): - """Gets the value of this DateVariableRequest. # noqa: E501 - - The date with which the date variable should be replaced when instantiating a project. This takes a date with `YYYY-MM-DD` format. # noqa: E501 - - :return: The value of this DateVariableRequest. # noqa: E501 - :rtype: datetime - """ - return self._value - - @value.setter - def value(self, value): - """Sets the value of this DateVariableRequest. - - The date with which the date variable should be replaced when instantiating a project. This takes a date with `YYYY-MM-DD` format. # noqa: E501 - - :param value: The value of this DateVariableRequest. # noqa: E501 - :type: datetime - """ - - self._value = value - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(DateVariableRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, DateVariableRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/empty_response.py b/asana/models/empty_response.py deleted file mode 100644 index a7000992..00000000 --- a/asana/models/empty_response.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EmptyResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """EmptyResponse - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EmptyResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EmptyResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/empty_response_data.py b/asana/models/empty_response_data.py deleted file mode 100644 index 50fc95eb..00000000 --- a/asana/models/empty_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EmptyResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'EmptyResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """EmptyResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this EmptyResponseData. # noqa: E501 - - - :return: The data of this EmptyResponseData. # noqa: E501 - :rtype: EmptyResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this EmptyResponseData. - - - :param data: The data of this EmptyResponseData. # noqa: E501 - :type: EmptyResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EmptyResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EmptyResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/enum_option.py b/asana/models/enum_option.py deleted file mode 100644 index 11b6764e..00000000 --- a/asana/models/enum_option.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EnumOption(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'enabled': 'bool', - 'color': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'enabled': 'enabled', - 'color': 'color' - } - - def __init__(self, gid=None, resource_type=None, name=None, enabled=None, color=None): # noqa: E501 - """EnumOption - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._enabled = None - self._color = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if enabled is not None: - self.enabled = enabled - if color is not None: - self.color = color - - @property - def gid(self): - """Gets the gid of this EnumOption. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this EnumOption. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this EnumOption. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this EnumOption. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this EnumOption. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this EnumOption. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this EnumOption. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this EnumOption. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this EnumOption. # noqa: E501 - - The name of the enum option. # noqa: E501 - - :return: The name of this EnumOption. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this EnumOption. - - The name of the enum option. # noqa: E501 - - :param name: The name of this EnumOption. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def enabled(self): - """Gets the enabled of this EnumOption. # noqa: E501 - - Whether or not the enum option is a selectable value for the custom field. # noqa: E501 - - :return: The enabled of this EnumOption. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this EnumOption. - - Whether or not the enum option is a selectable value for the custom field. # noqa: E501 - - :param enabled: The enabled of this EnumOption. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def color(self): - """Gets the color of this EnumOption. # noqa: E501 - - The color of the enum option. Defaults to ‘none’. # noqa: E501 - - :return: The color of this EnumOption. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this EnumOption. - - The color of the enum option. Defaults to ‘none’. # noqa: E501 - - :param color: The color of this EnumOption. # noqa: E501 - :type: str - """ - - self._color = color - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EnumOption, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EnumOption): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/enum_option_base.py b/asana/models/enum_option_base.py deleted file mode 100644 index a8a25fc5..00000000 --- a/asana/models/enum_option_base.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EnumOptionBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'enabled': 'bool', - 'color': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'enabled': 'enabled', - 'color': 'color' - } - - def __init__(self, gid=None, resource_type=None, name=None, enabled=None, color=None): # noqa: E501 - """EnumOptionBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._enabled = None - self._color = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if enabled is not None: - self.enabled = enabled - if color is not None: - self.color = color - - @property - def gid(self): - """Gets the gid of this EnumOptionBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this EnumOptionBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this EnumOptionBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this EnumOptionBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this EnumOptionBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this EnumOptionBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this EnumOptionBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this EnumOptionBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this EnumOptionBase. # noqa: E501 - - The name of the enum option. # noqa: E501 - - :return: The name of this EnumOptionBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this EnumOptionBase. - - The name of the enum option. # noqa: E501 - - :param name: The name of this EnumOptionBase. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def enabled(self): - """Gets the enabled of this EnumOptionBase. # noqa: E501 - - Whether or not the enum option is a selectable value for the custom field. # noqa: E501 - - :return: The enabled of this EnumOptionBase. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this EnumOptionBase. - - Whether or not the enum option is a selectable value for the custom field. # noqa: E501 - - :param enabled: The enabled of this EnumOptionBase. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def color(self): - """Gets the color of this EnumOptionBase. # noqa: E501 - - The color of the enum option. Defaults to ‘none’. # noqa: E501 - - :return: The color of this EnumOptionBase. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this EnumOptionBase. - - The color of the enum option. Defaults to ‘none’. # noqa: E501 - - :param color: The color of this EnumOptionBase. # noqa: E501 - :type: str - """ - - self._color = color - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EnumOptionBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EnumOptionBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/enum_option_data.py b/asana/models/enum_option_data.py deleted file mode 100644 index 812d7e35..00000000 --- a/asana/models/enum_option_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EnumOptionData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'EnumOption' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """EnumOptionData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this EnumOptionData. # noqa: E501 - - - :return: The data of this EnumOptionData. # noqa: E501 - :rtype: EnumOption - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this EnumOptionData. - - - :param data: The data of this EnumOptionData. # noqa: E501 - :type: EnumOption - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EnumOptionData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EnumOptionData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/enum_option_insert_request.py b/asana/models/enum_option_insert_request.py deleted file mode 100644 index 0bab1330..00000000 --- a/asana/models/enum_option_insert_request.py +++ /dev/null @@ -1,169 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EnumOptionInsertRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'enum_option': 'str', - 'before_enum_option': 'str', - 'after_enum_option': 'str' - } - - attribute_map = { - 'enum_option': 'enum_option', - 'before_enum_option': 'before_enum_option', - 'after_enum_option': 'after_enum_option' - } - - def __init__(self, enum_option=None, before_enum_option=None, after_enum_option=None): # noqa: E501 - """EnumOptionInsertRequest - a model defined in Swagger""" # noqa: E501 - self._enum_option = None - self._before_enum_option = None - self._after_enum_option = None - self.discriminator = None - self.enum_option = enum_option - if before_enum_option is not None: - self.before_enum_option = before_enum_option - if after_enum_option is not None: - self.after_enum_option = after_enum_option - - @property - def enum_option(self): - """Gets the enum_option of this EnumOptionInsertRequest. # noqa: E501 - - The gid of the enum option to relocate. # noqa: E501 - - :return: The enum_option of this EnumOptionInsertRequest. # noqa: E501 - :rtype: str - """ - return self._enum_option - - @enum_option.setter - def enum_option(self, enum_option): - """Sets the enum_option of this EnumOptionInsertRequest. - - The gid of the enum option to relocate. # noqa: E501 - - :param enum_option: The enum_option of this EnumOptionInsertRequest. # noqa: E501 - :type: str - """ - if enum_option is None: - raise ValueError("Invalid value for `enum_option`, must not be `None`") # noqa: E501 - - self._enum_option = enum_option - - @property - def before_enum_option(self): - """Gets the before_enum_option of this EnumOptionInsertRequest. # noqa: E501 - - An existing enum option within this custom field before which the new enum option should be inserted. Cannot be provided together with after_enum_option. # noqa: E501 - - :return: The before_enum_option of this EnumOptionInsertRequest. # noqa: E501 - :rtype: str - """ - return self._before_enum_option - - @before_enum_option.setter - def before_enum_option(self, before_enum_option): - """Sets the before_enum_option of this EnumOptionInsertRequest. - - An existing enum option within this custom field before which the new enum option should be inserted. Cannot be provided together with after_enum_option. # noqa: E501 - - :param before_enum_option: The before_enum_option of this EnumOptionInsertRequest. # noqa: E501 - :type: str - """ - - self._before_enum_option = before_enum_option - - @property - def after_enum_option(self): - """Gets the after_enum_option of this EnumOptionInsertRequest. # noqa: E501 - - An existing enum option within this custom field after which the new enum option should be inserted. Cannot be provided together with before_enum_option. # noqa: E501 - - :return: The after_enum_option of this EnumOptionInsertRequest. # noqa: E501 - :rtype: str - """ - return self._after_enum_option - - @after_enum_option.setter - def after_enum_option(self, after_enum_option): - """Sets the after_enum_option of this EnumOptionInsertRequest. - - An existing enum option within this custom field after which the new enum option should be inserted. Cannot be provided together with before_enum_option. # noqa: E501 - - :param after_enum_option: The after_enum_option of this EnumOptionInsertRequest. # noqa: E501 - :type: str - """ - - self._after_enum_option = after_enum_option - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EnumOptionInsertRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EnumOptionInsertRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/enum_option_request.py b/asana/models/enum_option_request.py deleted file mode 100644 index dd02128c..00000000 --- a/asana/models/enum_option_request.py +++ /dev/null @@ -1,280 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EnumOptionRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'enabled': 'bool', - 'color': 'str', - 'insert_before': 'str', - 'insert_after': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'enabled': 'enabled', - 'color': 'color', - 'insert_before': 'insert_before', - 'insert_after': 'insert_after' - } - - def __init__(self, gid=None, resource_type=None, name=None, enabled=None, color=None, insert_before=None, insert_after=None): # noqa: E501 - """EnumOptionRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._enabled = None - self._color = None - self._insert_before = None - self._insert_after = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if enabled is not None: - self.enabled = enabled - if color is not None: - self.color = color - if insert_before is not None: - self.insert_before = insert_before - if insert_after is not None: - self.insert_after = insert_after - - @property - def gid(self): - """Gets the gid of this EnumOptionRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this EnumOptionRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this EnumOptionRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this EnumOptionRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this EnumOptionRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this EnumOptionRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this EnumOptionRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this EnumOptionRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this EnumOptionRequest. # noqa: E501 - - The name of the enum option. # noqa: E501 - - :return: The name of this EnumOptionRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this EnumOptionRequest. - - The name of the enum option. # noqa: E501 - - :param name: The name of this EnumOptionRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def enabled(self): - """Gets the enabled of this EnumOptionRequest. # noqa: E501 - - Whether or not the enum option is a selectable value for the custom field. # noqa: E501 - - :return: The enabled of this EnumOptionRequest. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this EnumOptionRequest. - - Whether or not the enum option is a selectable value for the custom field. # noqa: E501 - - :param enabled: The enabled of this EnumOptionRequest. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def color(self): - """Gets the color of this EnumOptionRequest. # noqa: E501 - - The color of the enum option. Defaults to ‘none’. # noqa: E501 - - :return: The color of this EnumOptionRequest. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this EnumOptionRequest. - - The color of the enum option. Defaults to ‘none’. # noqa: E501 - - :param color: The color of this EnumOptionRequest. # noqa: E501 - :type: str - """ - - self._color = color - - @property - def insert_before(self): - """Gets the insert_before of this EnumOptionRequest. # noqa: E501 - - An existing enum option within this custom field before which the new enum option should be inserted. Cannot be provided together with after_enum_option. # noqa: E501 - - :return: The insert_before of this EnumOptionRequest. # noqa: E501 - :rtype: str - """ - return self._insert_before - - @insert_before.setter - def insert_before(self, insert_before): - """Sets the insert_before of this EnumOptionRequest. - - An existing enum option within this custom field before which the new enum option should be inserted. Cannot be provided together with after_enum_option. # noqa: E501 - - :param insert_before: The insert_before of this EnumOptionRequest. # noqa: E501 - :type: str - """ - - self._insert_before = insert_before - - @property - def insert_after(self): - """Gets the insert_after of this EnumOptionRequest. # noqa: E501 - - An existing enum option within this custom field after which the new enum option should be inserted. Cannot be provided together with before_enum_option. # noqa: E501 - - :return: The insert_after of this EnumOptionRequest. # noqa: E501 - :rtype: str - """ - return self._insert_after - - @insert_after.setter - def insert_after(self, insert_after): - """Sets the insert_after of this EnumOptionRequest. - - An existing enum option within this custom field after which the new enum option should be inserted. Cannot be provided together with before_enum_option. # noqa: E501 - - :param insert_after: The insert_after of this EnumOptionRequest. # noqa: E501 - :type: str - """ - - self._insert_after = insert_after - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EnumOptionRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EnumOptionRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/enum_options_enum_option_gid_body.py b/asana/models/enum_options_enum_option_gid_body.py deleted file mode 100644 index 643b7725..00000000 --- a/asana/models/enum_options_enum_option_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EnumOptionsEnumOptionGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'EnumOptionBase' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """EnumOptionsEnumOptionGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this EnumOptionsEnumOptionGidBody. # noqa: E501 - - - :return: The data of this EnumOptionsEnumOptionGidBody. # noqa: E501 - :rtype: EnumOptionBase - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this EnumOptionsEnumOptionGidBody. - - - :param data: The data of this EnumOptionsEnumOptionGidBody. # noqa: E501 - :type: EnumOptionBase - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EnumOptionsEnumOptionGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EnumOptionsEnumOptionGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/enum_options_insert_body.py b/asana/models/enum_options_insert_body.py deleted file mode 100644 index 7fa7d2fd..00000000 --- a/asana/models/enum_options_insert_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EnumOptionsInsertBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'EnumOptionInsertRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """EnumOptionsInsertBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this EnumOptionsInsertBody. # noqa: E501 - - - :return: The data of this EnumOptionsInsertBody. # noqa: E501 - :rtype: EnumOptionInsertRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this EnumOptionsInsertBody. - - - :param data: The data of this EnumOptionsInsertBody. # noqa: E501 - :type: EnumOptionInsertRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EnumOptionsInsertBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EnumOptionsInsertBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/error.py b/asana/models/error.py deleted file mode 100644 index 2574144d..00000000 --- a/asana/models/error.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class Error(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'message': 'str', - 'help': 'str', - 'phrase': 'str' - } - - attribute_map = { - 'message': 'message', - 'help': 'help', - 'phrase': 'phrase' - } - - def __init__(self, message=None, help=None, phrase=None): # noqa: E501 - """Error - a model defined in Swagger""" # noqa: E501 - self._message = None - self._help = None - self._phrase = None - self.discriminator = None - if message is not None: - self.message = message - if help is not None: - self.help = help - if phrase is not None: - self.phrase = phrase - - @property - def message(self): - """Gets the message of this Error. # noqa: E501 - - Message providing more detail about the error that occurred, if available. # noqa: E501 - - :return: The message of this Error. # noqa: E501 - :rtype: str - """ - return self._message - - @message.setter - def message(self, message): - """Sets the message of this Error. - - Message providing more detail about the error that occurred, if available. # noqa: E501 - - :param message: The message of this Error. # noqa: E501 - :type: str - """ - - self._message = message - - @property - def help(self): - """Gets the help of this Error. # noqa: E501 - - Additional information directing developers to resources on how to address and fix the problem, if available. # noqa: E501 - - :return: The help of this Error. # noqa: E501 - :rtype: str - """ - return self._help - - @help.setter - def help(self, help): - """Sets the help of this Error. - - Additional information directing developers to resources on how to address and fix the problem, if available. # noqa: E501 - - :param help: The help of this Error. # noqa: E501 - :type: str - """ - - self._help = help - - @property - def phrase(self): - """Gets the phrase of this Error. # noqa: E501 - - *500 errors only*. A unique error phrase which can be used when contacting developer support to help identify the exact occurrence of the problem in Asana’s logs. # noqa: E501 - - :return: The phrase of this Error. # noqa: E501 - :rtype: str - """ - return self._phrase - - @phrase.setter - def phrase(self, phrase): - """Sets the phrase of this Error. - - *500 errors only*. A unique error phrase which can be used when contacting developer support to help identify the exact occurrence of the problem in Asana’s logs. # noqa: E501 - - :param phrase: The phrase of this Error. # noqa: E501 - :type: str - """ - - self._phrase = phrase - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(Error, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, Error): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/error_response.py b/asana/models/error_response.py deleted file mode 100644 index 4b350f6d..00000000 --- a/asana/models/error_response.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ErrorResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'errors': 'list[ErrorResponseErrors]' - } - - attribute_map = { - 'errors': 'errors' - } - - def __init__(self, errors=None): # noqa: E501 - """ErrorResponse - a model defined in Swagger""" # noqa: E501 - self._errors = None - self.discriminator = None - if errors is not None: - self.errors = errors - - @property - def errors(self): - """Gets the errors of this ErrorResponse. # noqa: E501 - - - :return: The errors of this ErrorResponse. # noqa: E501 - :rtype: list[ErrorResponseErrors] - """ - return self._errors - - @errors.setter - def errors(self, errors): - """Sets the errors of this ErrorResponse. - - - :param errors: The errors of this ErrorResponse. # noqa: E501 - :type: list[ErrorResponseErrors] - """ - - self._errors = errors - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ErrorResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ErrorResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/error_response_errors.py b/asana/models/error_response_errors.py deleted file mode 100644 index 0405411e..00000000 --- a/asana/models/error_response_errors.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ErrorResponseErrors(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'message': 'str', - 'help': 'str', - 'phrase': 'str' - } - - attribute_map = { - 'message': 'message', - 'help': 'help', - 'phrase': 'phrase' - } - - def __init__(self, message=None, help=None, phrase=None): # noqa: E501 - """ErrorResponseErrors - a model defined in Swagger""" # noqa: E501 - self._message = None - self._help = None - self._phrase = None - self.discriminator = None - if message is not None: - self.message = message - if help is not None: - self.help = help - if phrase is not None: - self.phrase = phrase - - @property - def message(self): - """Gets the message of this ErrorResponseErrors. # noqa: E501 - - Message providing more detail about the error that occurred, if available. # noqa: E501 - - :return: The message of this ErrorResponseErrors. # noqa: E501 - :rtype: str - """ - return self._message - - @message.setter - def message(self, message): - """Sets the message of this ErrorResponseErrors. - - Message providing more detail about the error that occurred, if available. # noqa: E501 - - :param message: The message of this ErrorResponseErrors. # noqa: E501 - :type: str - """ - - self._message = message - - @property - def help(self): - """Gets the help of this ErrorResponseErrors. # noqa: E501 - - Additional information directing developers to resources on how to address and fix the problem, if available. # noqa: E501 - - :return: The help of this ErrorResponseErrors. # noqa: E501 - :rtype: str - """ - return self._help - - @help.setter - def help(self, help): - """Sets the help of this ErrorResponseErrors. - - Additional information directing developers to resources on how to address and fix the problem, if available. # noqa: E501 - - :param help: The help of this ErrorResponseErrors. # noqa: E501 - :type: str - """ - - self._help = help - - @property - def phrase(self): - """Gets the phrase of this ErrorResponseErrors. # noqa: E501 - - *500 errors only*. A unique error phrase which can be used when contacting developer support to help identify the exact occurrence of the problem in Asana’s logs. # noqa: E501 - - :return: The phrase of this ErrorResponseErrors. # noqa: E501 - :rtype: str - """ - return self._phrase - - @phrase.setter - def phrase(self, phrase): - """Sets the phrase of this ErrorResponseErrors. - - *500 errors only*. A unique error phrase which can be used when contacting developer support to help identify the exact occurrence of the problem in Asana’s logs. # noqa: E501 - - :param phrase: The phrase of this ErrorResponseErrors. # noqa: E501 - :type: str - """ - - self._phrase = phrase - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ErrorResponseErrors, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ErrorResponseErrors): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/event_response.py b/asana/models/event_response.py deleted file mode 100644 index 51ee3922..00000000 --- a/asana/models/event_response.py +++ /dev/null @@ -1,272 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EventResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'user': 'EventResponseUser', - 'resource': 'EventResponseResource', - 'type': 'str', - 'action': 'str', - 'parent': 'EventResponseParent', - 'created_at': 'datetime', - 'change': 'EventResponseChange' - } - - attribute_map = { - 'user': 'user', - 'resource': 'resource', - 'type': 'type', - 'action': 'action', - 'parent': 'parent', - 'created_at': 'created_at', - 'change': 'change' - } - - def __init__(self, user=None, resource=None, type=None, action=None, parent=None, created_at=None, change=None): # noqa: E501 - """EventResponse - a model defined in Swagger""" # noqa: E501 - self._user = None - self._resource = None - self._type = None - self._action = None - self._parent = None - self._created_at = None - self._change = None - self.discriminator = None - if user is not None: - self.user = user - if resource is not None: - self.resource = resource - if type is not None: - self.type = type - if action is not None: - self.action = action - if parent is not None: - self.parent = parent - if created_at is not None: - self.created_at = created_at - if change is not None: - self.change = change - - @property - def user(self): - """Gets the user of this EventResponse. # noqa: E501 - - - :return: The user of this EventResponse. # noqa: E501 - :rtype: EventResponseUser - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this EventResponse. - - - :param user: The user of this EventResponse. # noqa: E501 - :type: EventResponseUser - """ - - self._user = user - - @property - def resource(self): - """Gets the resource of this EventResponse. # noqa: E501 - - - :return: The resource of this EventResponse. # noqa: E501 - :rtype: EventResponseResource - """ - return self._resource - - @resource.setter - def resource(self, resource): - """Sets the resource of this EventResponse. - - - :param resource: The resource of this EventResponse. # noqa: E501 - :type: EventResponseResource - """ - - self._resource = resource - - @property - def type(self): - """Gets the type of this EventResponse. # noqa: E501 - - *Deprecated: Refer to the resource_type of the resource.* The type of the resource that generated the event. # noqa: E501 - - :return: The type of this EventResponse. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this EventResponse. - - *Deprecated: Refer to the resource_type of the resource.* The type of the resource that generated the event. # noqa: E501 - - :param type: The type of this EventResponse. # noqa: E501 - :type: str - """ - - self._type = type - - @property - def action(self): - """Gets the action of this EventResponse. # noqa: E501 - - The type of action taken on the **resource** that triggered the event. This can be one of `changed`, `added`, `removed`, `deleted`, or `undeleted` depending on the nature of the event. # noqa: E501 - - :return: The action of this EventResponse. # noqa: E501 - :rtype: str - """ - return self._action - - @action.setter - def action(self, action): - """Sets the action of this EventResponse. - - The type of action taken on the **resource** that triggered the event. This can be one of `changed`, `added`, `removed`, `deleted`, or `undeleted` depending on the nature of the event. # noqa: E501 - - :param action: The action of this EventResponse. # noqa: E501 - :type: str - """ - - self._action = action - - @property - def parent(self): - """Gets the parent of this EventResponse. # noqa: E501 - - - :return: The parent of this EventResponse. # noqa: E501 - :rtype: EventResponseParent - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this EventResponse. - - - :param parent: The parent of this EventResponse. # noqa: E501 - :type: EventResponseParent - """ - - self._parent = parent - - @property - def created_at(self): - """Gets the created_at of this EventResponse. # noqa: E501 - - The timestamp when the event occurred. # noqa: E501 - - :return: The created_at of this EventResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this EventResponse. - - The timestamp when the event occurred. # noqa: E501 - - :param created_at: The created_at of this EventResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def change(self): - """Gets the change of this EventResponse. # noqa: E501 - - - :return: The change of this EventResponse. # noqa: E501 - :rtype: EventResponseChange - """ - return self._change - - @change.setter - def change(self, change): - """Sets the change of this EventResponse. - - - :param change: The change of this EventResponse. # noqa: E501 - :type: EventResponseChange - """ - - self._change = change - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EventResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EventResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/event_response_array.py b/asana/models/event_response_array.py deleted file mode 100644 index 1ff1372f..00000000 --- a/asana/models/event_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EventResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[EventResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """EventResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this EventResponseArray. # noqa: E501 - - - :return: The data of this EventResponseArray. # noqa: E501 - :rtype: list[EventResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this EventResponseArray. - - - :param data: The data of this EventResponseArray. # noqa: E501 - :type: list[EventResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this EventResponseArray. # noqa: E501 - - - :return: The next_page of this EventResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this EventResponseArray. - - - :param next_page: The next_page of this EventResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EventResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EventResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/event_response_change.py b/asana/models/event_response_change.py deleted file mode 100644 index a68d0d77..00000000 --- a/asana/models/event_response_change.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EventResponseChange(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'field': 'str', - 'action': 'str', - 'new_value': 'object', - 'added_value': 'object', - 'removed_value': 'object' - } - - attribute_map = { - 'field': 'field', - 'action': 'action', - 'new_value': 'new_value', - 'added_value': 'added_value', - 'removed_value': 'removed_value' - } - - def __init__(self, field=None, action=None, new_value=None, added_value=None, removed_value=None): # noqa: E501 - """EventResponseChange - a model defined in Swagger""" # noqa: E501 - self._field = None - self._action = None - self._new_value = None - self._added_value = None - self._removed_value = None - self.discriminator = None - if field is not None: - self.field = field - if action is not None: - self.action = action - if new_value is not None: - self.new_value = new_value - if added_value is not None: - self.added_value = added_value - if removed_value is not None: - self.removed_value = removed_value - - @property - def field(self): - """Gets the field of this EventResponseChange. # noqa: E501 - - The name of the field that has changed in the resource. # noqa: E501 - - :return: The field of this EventResponseChange. # noqa: E501 - :rtype: str - """ - return self._field - - @field.setter - def field(self, field): - """Sets the field of this EventResponseChange. - - The name of the field that has changed in the resource. # noqa: E501 - - :param field: The field of this EventResponseChange. # noqa: E501 - :type: str - """ - - self._field = field - - @property - def action(self): - """Gets the action of this EventResponseChange. # noqa: E501 - - The type of action taken on the **field** which has been changed. This can be one of `changed`, `added`, or `removed` depending on the nature of the change. # noqa: E501 - - :return: The action of this EventResponseChange. # noqa: E501 - :rtype: str - """ - return self._action - - @action.setter - def action(self, action): - """Sets the action of this EventResponseChange. - - The type of action taken on the **field** which has been changed. This can be one of `changed`, `added`, or `removed` depending on the nature of the change. # noqa: E501 - - :param action: The action of this EventResponseChange. # noqa: E501 - :type: str - """ - - self._action = action - - @property - def new_value(self): - """Gets the new_value of this EventResponseChange. # noqa: E501 - - *Conditional.* This property is only present when the value of the event's `change.action` is `changed` _and_ the `new_value` is an Asana resource. This will be only the `gid` and `resource_type` of the resource when the events come from webhooks; this will be the compact representation (and can have fields expanded with [opt_fields](/docs/inputoutput-options)) when using the [get events](/reference/getevents) endpoint. # noqa: E501 - - :return: The new_value of this EventResponseChange. # noqa: E501 - :rtype: object - """ - return self._new_value - - @new_value.setter - def new_value(self, new_value): - """Sets the new_value of this EventResponseChange. - - *Conditional.* This property is only present when the value of the event's `change.action` is `changed` _and_ the `new_value` is an Asana resource. This will be only the `gid` and `resource_type` of the resource when the events come from webhooks; this will be the compact representation (and can have fields expanded with [opt_fields](/docs/inputoutput-options)) when using the [get events](/reference/getevents) endpoint. # noqa: E501 - - :param new_value: The new_value of this EventResponseChange. # noqa: E501 - :type: object - """ - - self._new_value = new_value - - @property - def added_value(self): - """Gets the added_value of this EventResponseChange. # noqa: E501 - - *Conditional.* This property is only present when the value of the event's `change.action` is `added` _and_ the `added_value` is an Asana resource. This will be only the `gid` and `resource_type` of the resource when the events come from webhooks; this will be the compact representation (and can have fields expanded with [opt_fields](/docs/inputoutput-options)) when using the [get events](/reference/getevents) endpoint. # noqa: E501 - - :return: The added_value of this EventResponseChange. # noqa: E501 - :rtype: object - """ - return self._added_value - - @added_value.setter - def added_value(self, added_value): - """Sets the added_value of this EventResponseChange. - - *Conditional.* This property is only present when the value of the event's `change.action` is `added` _and_ the `added_value` is an Asana resource. This will be only the `gid` and `resource_type` of the resource when the events come from webhooks; this will be the compact representation (and can have fields expanded with [opt_fields](/docs/inputoutput-options)) when using the [get events](/reference/getevents) endpoint. # noqa: E501 - - :param added_value: The added_value of this EventResponseChange. # noqa: E501 - :type: object - """ - - self._added_value = added_value - - @property - def removed_value(self): - """Gets the removed_value of this EventResponseChange. # noqa: E501 - - *Conditional.* This property is only present when the value of the event's `change.action` is `removed` _and_ the `removed_value` is an Asana resource. This will be only the `gid` and `resource_type` of the resource when the events come from webhooks; this will be the compact representation (and can have fields expanded with [opt_fields](/docs/inputoutput-options)) when using the [get events](/reference/getevents) endpoint. # noqa: E501 - - :return: The removed_value of this EventResponseChange. # noqa: E501 - :rtype: object - """ - return self._removed_value - - @removed_value.setter - def removed_value(self, removed_value): - """Sets the removed_value of this EventResponseChange. - - *Conditional.* This property is only present when the value of the event's `change.action` is `removed` _and_ the `removed_value` is an Asana resource. This will be only the `gid` and `resource_type` of the resource when the events come from webhooks; this will be the compact representation (and can have fields expanded with [opt_fields](/docs/inputoutput-options)) when using the [get events](/reference/getevents) endpoint. # noqa: E501 - - :param removed_value: The removed_value of this EventResponseChange. # noqa: E501 - :type: object - """ - - self._removed_value = removed_value - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EventResponseChange, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EventResponseChange): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/event_response_parent.py b/asana/models/event_response_parent.py deleted file mode 100644 index 431dd0f8..00000000 --- a/asana/models/event_response_parent.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EventResponseParent(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """EventResponseParent - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this EventResponseParent. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this EventResponseParent. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this EventResponseParent. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this EventResponseParent. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this EventResponseParent. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this EventResponseParent. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this EventResponseParent. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this EventResponseParent. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this EventResponseParent. # noqa: E501 - - The name of the object. # noqa: E501 - - :return: The name of this EventResponseParent. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this EventResponseParent. - - The name of the object. # noqa: E501 - - :param name: The name of this EventResponseParent. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EventResponseParent, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EventResponseParent): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/event_response_resource.py b/asana/models/event_response_resource.py deleted file mode 100644 index 37374cb4..00000000 --- a/asana/models/event_response_resource.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EventResponseResource(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """EventResponseResource - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this EventResponseResource. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this EventResponseResource. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this EventResponseResource. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this EventResponseResource. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this EventResponseResource. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this EventResponseResource. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this EventResponseResource. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this EventResponseResource. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this EventResponseResource. # noqa: E501 - - The name of the object. # noqa: E501 - - :return: The name of this EventResponseResource. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this EventResponseResource. - - The name of the object. # noqa: E501 - - :param name: The name of this EventResponseResource. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EventResponseResource, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EventResponseResource): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/event_response_user.py b/asana/models/event_response_user.py deleted file mode 100644 index 1472d52e..00000000 --- a/asana/models/event_response_user.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class EventResponseUser(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """EventResponseUser - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this EventResponseUser. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this EventResponseUser. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this EventResponseUser. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this EventResponseUser. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this EventResponseUser. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this EventResponseUser. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this EventResponseUser. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this EventResponseUser. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this EventResponseUser. # noqa: E501 - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :return: The name of this EventResponseUser. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this EventResponseUser. - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :param name: The name of this EventResponseUser. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(EventResponseUser, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, EventResponseUser): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_add_subgoal_request.py b/asana/models/goal_add_subgoal_request.py deleted file mode 100644 index b84f7613..00000000 --- a/asana/models/goal_add_subgoal_request.py +++ /dev/null @@ -1,169 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalAddSubgoalRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'subgoal': 'str', - 'insert_before': 'str', - 'insert_after': 'str' - } - - attribute_map = { - 'subgoal': 'subgoal', - 'insert_before': 'insert_before', - 'insert_after': 'insert_after' - } - - def __init__(self, subgoal=None, insert_before=None, insert_after=None): # noqa: E501 - """GoalAddSubgoalRequest - a model defined in Swagger""" # noqa: E501 - self._subgoal = None - self._insert_before = None - self._insert_after = None - self.discriminator = None - self.subgoal = subgoal - if insert_before is not None: - self.insert_before = insert_before - if insert_after is not None: - self.insert_after = insert_after - - @property - def subgoal(self): - """Gets the subgoal of this GoalAddSubgoalRequest. # noqa: E501 - - The goal gid to add as subgoal to a parent goal # noqa: E501 - - :return: The subgoal of this GoalAddSubgoalRequest. # noqa: E501 - :rtype: str - """ - return self._subgoal - - @subgoal.setter - def subgoal(self, subgoal): - """Sets the subgoal of this GoalAddSubgoalRequest. - - The goal gid to add as subgoal to a parent goal # noqa: E501 - - :param subgoal: The subgoal of this GoalAddSubgoalRequest. # noqa: E501 - :type: str - """ - if subgoal is None: - raise ValueError("Invalid value for `subgoal`, must not be `None`") # noqa: E501 - - self._subgoal = subgoal - - @property - def insert_before(self): - """Gets the insert_before of this GoalAddSubgoalRequest. # noqa: E501 - - An id of a subgoal of this parent goal. The new subgoal will be added before the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. # noqa: E501 - - :return: The insert_before of this GoalAddSubgoalRequest. # noqa: E501 - :rtype: str - """ - return self._insert_before - - @insert_before.setter - def insert_before(self, insert_before): - """Sets the insert_before of this GoalAddSubgoalRequest. - - An id of a subgoal of this parent goal. The new subgoal will be added before the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. # noqa: E501 - - :param insert_before: The insert_before of this GoalAddSubgoalRequest. # noqa: E501 - :type: str - """ - - self._insert_before = insert_before - - @property - def insert_after(self): - """Gets the insert_after of this GoalAddSubgoalRequest. # noqa: E501 - - An id of a subgoal of this parent goal. The new subgoal will be added after the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. # noqa: E501 - - :return: The insert_after of this GoalAddSubgoalRequest. # noqa: E501 - :rtype: str - """ - return self._insert_after - - @insert_after.setter - def insert_after(self, insert_after): - """Sets the insert_after of this GoalAddSubgoalRequest. - - An id of a subgoal of this parent goal. The new subgoal will be added after the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. # noqa: E501 - - :param insert_after: The insert_after of this GoalAddSubgoalRequest. # noqa: E501 - :type: str - """ - - self._insert_after = insert_after - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalAddSubgoalRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalAddSubgoalRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_add_supporting_relationship_request.py b/asana/models/goal_add_supporting_relationship_request.py deleted file mode 100644 index 7afe7678..00000000 --- a/asana/models/goal_add_supporting_relationship_request.py +++ /dev/null @@ -1,197 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalAddSupportingRelationshipRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'supporting_resource': 'str', - 'insert_before': 'str', - 'insert_after': 'str', - 'contribution_weight': 'float' - } - - attribute_map = { - 'supporting_resource': 'supporting_resource', - 'insert_before': 'insert_before', - 'insert_after': 'insert_after', - 'contribution_weight': 'contribution_weight' - } - - def __init__(self, supporting_resource=None, insert_before=None, insert_after=None, contribution_weight=None): # noqa: E501 - """GoalAddSupportingRelationshipRequest - a model defined in Swagger""" # noqa: E501 - self._supporting_resource = None - self._insert_before = None - self._insert_after = None - self._contribution_weight = None - self.discriminator = None - self.supporting_resource = supporting_resource - if insert_before is not None: - self.insert_before = insert_before - if insert_after is not None: - self.insert_after = insert_after - if contribution_weight is not None: - self.contribution_weight = contribution_weight - - @property - def supporting_resource(self): - """Gets the supporting_resource of this GoalAddSupportingRelationshipRequest. # noqa: E501 - - The gid of the supporting resource to add to the parent goal. Must be the gid of a goal, project, or portfolio. # noqa: E501 - - :return: The supporting_resource of this GoalAddSupportingRelationshipRequest. # noqa: E501 - :rtype: str - """ - return self._supporting_resource - - @supporting_resource.setter - def supporting_resource(self, supporting_resource): - """Sets the supporting_resource of this GoalAddSupportingRelationshipRequest. - - The gid of the supporting resource to add to the parent goal. Must be the gid of a goal, project, or portfolio. # noqa: E501 - - :param supporting_resource: The supporting_resource of this GoalAddSupportingRelationshipRequest. # noqa: E501 - :type: str - """ - if supporting_resource is None: - raise ValueError("Invalid value for `supporting_resource`, must not be `None`") # noqa: E501 - - self._supporting_resource = supporting_resource - - @property - def insert_before(self): - """Gets the insert_before of this GoalAddSupportingRelationshipRequest. # noqa: E501 - - An id of a subgoal of this parent goal. The new subgoal will be added before the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. Currently only supported when adding a subgoal. # noqa: E501 - - :return: The insert_before of this GoalAddSupportingRelationshipRequest. # noqa: E501 - :rtype: str - """ - return self._insert_before - - @insert_before.setter - def insert_before(self, insert_before): - """Sets the insert_before of this GoalAddSupportingRelationshipRequest. - - An id of a subgoal of this parent goal. The new subgoal will be added before the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. Currently only supported when adding a subgoal. # noqa: E501 - - :param insert_before: The insert_before of this GoalAddSupportingRelationshipRequest. # noqa: E501 - :type: str - """ - - self._insert_before = insert_before - - @property - def insert_after(self): - """Gets the insert_after of this GoalAddSupportingRelationshipRequest. # noqa: E501 - - An id of a subgoal of this parent goal. The new subgoal will be added after the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. Currently only supported when adding a subgoal. # noqa: E501 - - :return: The insert_after of this GoalAddSupportingRelationshipRequest. # noqa: E501 - :rtype: str - """ - return self._insert_after - - @insert_after.setter - def insert_after(self, insert_after): - """Sets the insert_after of this GoalAddSupportingRelationshipRequest. - - An id of a subgoal of this parent goal. The new subgoal will be added after the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. Currently only supported when adding a subgoal. # noqa: E501 - - :param insert_after: The insert_after of this GoalAddSupportingRelationshipRequest. # noqa: E501 - :type: str - """ - - self._insert_after = insert_after - - @property - def contribution_weight(self): - """Gets the contribution_weight of this GoalAddSupportingRelationshipRequest. # noqa: E501 - - The weight that the supporting resource's progress will contribute to the supported goal's progress. This can only be 0 or 1. # noqa: E501 - - :return: The contribution_weight of this GoalAddSupportingRelationshipRequest. # noqa: E501 - :rtype: float - """ - return self._contribution_weight - - @contribution_weight.setter - def contribution_weight(self, contribution_weight): - """Sets the contribution_weight of this GoalAddSupportingRelationshipRequest. - - The weight that the supporting resource's progress will contribute to the supported goal's progress. This can only be 0 or 1. # noqa: E501 - - :param contribution_weight: The contribution_weight of this GoalAddSupportingRelationshipRequest. # noqa: E501 - :type: float - """ - - self._contribution_weight = contribution_weight - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalAddSupportingRelationshipRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalAddSupportingRelationshipRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_add_supporting_work_request.py b/asana/models/goal_add_supporting_work_request.py deleted file mode 100644 index be5c821a..00000000 --- a/asana/models/goal_add_supporting_work_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalAddSupportingWorkRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'supporting_work': 'str' - } - - attribute_map = { - 'supporting_work': 'supporting_work' - } - - def __init__(self, supporting_work=None): # noqa: E501 - """GoalAddSupportingWorkRequest - a model defined in Swagger""" # noqa: E501 - self._supporting_work = None - self.discriminator = None - self.supporting_work = supporting_work - - @property - def supporting_work(self): - """Gets the supporting_work of this GoalAddSupportingWorkRequest. # noqa: E501 - - The project/portfolio gid to add as supporting work for a goal # noqa: E501 - - :return: The supporting_work of this GoalAddSupportingWorkRequest. # noqa: E501 - :rtype: str - """ - return self._supporting_work - - @supporting_work.setter - def supporting_work(self, supporting_work): - """Sets the supporting_work of this GoalAddSupportingWorkRequest. - - The project/portfolio gid to add as supporting work for a goal # noqa: E501 - - :param supporting_work: The supporting_work of this GoalAddSupportingWorkRequest. # noqa: E501 - :type: str - """ - if supporting_work is None: - raise ValueError("Invalid value for `supporting_work`, must not be `None`") # noqa: E501 - - self._supporting_work = supporting_work - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalAddSupportingWorkRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalAddSupportingWorkRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_base.py b/asana/models/goal_base.py deleted file mode 100644 index 2fb93555..00000000 --- a/asana/models/goal_base.py +++ /dev/null @@ -1,336 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'html_notes': 'str', - 'notes': 'str', - 'due_on': 'str', - 'start_on': 'str', - 'is_workspace_level': 'bool', - 'liked': 'bool' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'html_notes': 'html_notes', - 'notes': 'notes', - 'due_on': 'due_on', - 'start_on': 'start_on', - 'is_workspace_level': 'is_workspace_level', - 'liked': 'liked' - } - - def __init__(self, gid=None, resource_type=None, name=None, html_notes=None, notes=None, due_on=None, start_on=None, is_workspace_level=None, liked=None): # noqa: E501 - """GoalBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._html_notes = None - self._notes = None - self._due_on = None - self._start_on = None - self._is_workspace_level = None - self._liked = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if html_notes is not None: - self.html_notes = html_notes - if notes is not None: - self.notes = notes - if due_on is not None: - self.due_on = due_on - if start_on is not None: - self.start_on = start_on - if is_workspace_level is not None: - self.is_workspace_level = is_workspace_level - if liked is not None: - self.liked = liked - - @property - def gid(self): - """Gets the gid of this GoalBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this GoalBase. # noqa: E501 - - The name of the goal. # noqa: E501 - - :return: The name of this GoalBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this GoalBase. - - The name of the goal. # noqa: E501 - - :param name: The name of this GoalBase. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def html_notes(self): - """Gets the html_notes of this GoalBase. # noqa: E501 - - The notes of the goal with formatting as HTML. # noqa: E501 - - :return: The html_notes of this GoalBase. # noqa: E501 - :rtype: str - """ - return self._html_notes - - @html_notes.setter - def html_notes(self, html_notes): - """Sets the html_notes of this GoalBase. - - The notes of the goal with formatting as HTML. # noqa: E501 - - :param html_notes: The html_notes of this GoalBase. # noqa: E501 - :type: str - """ - - self._html_notes = html_notes - - @property - def notes(self): - """Gets the notes of this GoalBase. # noqa: E501 - - Free-form textual information associated with the goal (i.e. its description). # noqa: E501 - - :return: The notes of this GoalBase. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this GoalBase. - - Free-form textual information associated with the goal (i.e. its description). # noqa: E501 - - :param notes: The notes of this GoalBase. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def due_on(self): - """Gets the due_on of this GoalBase. # noqa: E501 - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :return: The due_on of this GoalBase. # noqa: E501 - :rtype: str - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this GoalBase. - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :param due_on: The due_on of this GoalBase. # noqa: E501 - :type: str - """ - - self._due_on = due_on - - @property - def start_on(self): - """Gets the start_on of this GoalBase. # noqa: E501 - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :return: The start_on of this GoalBase. # noqa: E501 - :rtype: str - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this GoalBase. - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :param start_on: The start_on of this GoalBase. # noqa: E501 - :type: str - """ - - self._start_on = start_on - - @property - def is_workspace_level(self): - """Gets the is_workspace_level of this GoalBase. # noqa: E501 - - *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. # noqa: E501 - - :return: The is_workspace_level of this GoalBase. # noqa: E501 - :rtype: bool - """ - return self._is_workspace_level - - @is_workspace_level.setter - def is_workspace_level(self, is_workspace_level): - """Sets the is_workspace_level of this GoalBase. - - *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. # noqa: E501 - - :param is_workspace_level: The is_workspace_level of this GoalBase. # noqa: E501 - :type: bool - """ - - self._is_workspace_level = is_workspace_level - - @property - def liked(self): - """Gets the liked of this GoalBase. # noqa: E501 - - True if the goal is liked by the authorized user, false if not. # noqa: E501 - - :return: The liked of this GoalBase. # noqa: E501 - :rtype: bool - """ - return self._liked - - @liked.setter - def liked(self, liked): - """Sets the liked of this GoalBase. - - True if the goal is liked by the authorized user, false if not. # noqa: E501 - - :param liked: The liked of this GoalBase. # noqa: E501 - :type: bool - """ - - self._liked = liked - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_compact.py b/asana/models/goal_compact.py deleted file mode 100644 index 85a453be..00000000 --- a/asana/models/goal_compact.py +++ /dev/null @@ -1,194 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'owner': 'CustomFieldResponseCreatedBy' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'owner': 'owner' - } - - def __init__(self, gid=None, resource_type=None, name=None, owner=None): # noqa: E501 - """GoalCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._owner = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if owner is not None: - self.owner = owner - - @property - def gid(self): - """Gets the gid of this GoalCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this GoalCompact. # noqa: E501 - - The name of the goal. # noqa: E501 - - :return: The name of this GoalCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this GoalCompact. - - The name of the goal. # noqa: E501 - - :param name: The name of this GoalCompact. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def owner(self): - """Gets the owner of this GoalCompact. # noqa: E501 - - - :return: The owner of this GoalCompact. # noqa: E501 - :rtype: CustomFieldResponseCreatedBy - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this GoalCompact. - - - :param owner: The owner of this GoalCompact. # noqa: E501 - :type: CustomFieldResponseCreatedBy - """ - - self._owner = owner - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_gid_add_followers_body.py b/asana/models/goal_gid_add_followers_body.py deleted file mode 100644 index 6e9949b6..00000000 --- a/asana/models/goal_gid_add_followers_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalGidAddFollowersBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskAddFollowersRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """GoalGidAddFollowersBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this GoalGidAddFollowersBody. # noqa: E501 - - - :return: The data of this GoalGidAddFollowersBody. # noqa: E501 - :rtype: TaskAddFollowersRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this GoalGidAddFollowersBody. - - - :param data: The data of this GoalGidAddFollowersBody. # noqa: E501 - :type: TaskAddFollowersRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalGidAddFollowersBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalGidAddFollowersBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_gid_add_supporting_relationship_body.py b/asana/models/goal_gid_add_supporting_relationship_body.py deleted file mode 100644 index 37cb9bad..00000000 --- a/asana/models/goal_gid_add_supporting_relationship_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalGidAddSupportingRelationshipBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'GoalAddSupportingRelationshipRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """GoalGidAddSupportingRelationshipBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this GoalGidAddSupportingRelationshipBody. # noqa: E501 - - - :return: The data of this GoalGidAddSupportingRelationshipBody. # noqa: E501 - :rtype: GoalAddSupportingRelationshipRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this GoalGidAddSupportingRelationshipBody. - - - :param data: The data of this GoalGidAddSupportingRelationshipBody. # noqa: E501 - :type: GoalAddSupportingRelationshipRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalGidAddSupportingRelationshipBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalGidAddSupportingRelationshipBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_gid_remove_followers_body.py b/asana/models/goal_gid_remove_followers_body.py deleted file mode 100644 index 9e9643ee..00000000 --- a/asana/models/goal_gid_remove_followers_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalGidRemoveFollowersBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskAddFollowersRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """GoalGidRemoveFollowersBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this GoalGidRemoveFollowersBody. # noqa: E501 - - - :return: The data of this GoalGidRemoveFollowersBody. # noqa: E501 - :rtype: TaskAddFollowersRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this GoalGidRemoveFollowersBody. - - - :param data: The data of this GoalGidRemoveFollowersBody. # noqa: E501 - :type: TaskAddFollowersRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalGidRemoveFollowersBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalGidRemoveFollowersBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_gid_remove_supporting_relationship_body.py b/asana/models/goal_gid_remove_supporting_relationship_body.py deleted file mode 100644 index 6eb4b966..00000000 --- a/asana/models/goal_gid_remove_supporting_relationship_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalGidRemoveSupportingRelationshipBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'GoalRemoveSupportingRelationshipRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """GoalGidRemoveSupportingRelationshipBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this GoalGidRemoveSupportingRelationshipBody. # noqa: E501 - - - :return: The data of this GoalGidRemoveSupportingRelationshipBody. # noqa: E501 - :rtype: GoalRemoveSupportingRelationshipRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this GoalGidRemoveSupportingRelationshipBody. - - - :param data: The data of this GoalGidRemoveSupportingRelationshipBody. # noqa: E501 - :type: GoalRemoveSupportingRelationshipRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalGidRemoveSupportingRelationshipBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalGidRemoveSupportingRelationshipBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_gid_set_metric_body.py b/asana/models/goal_gid_set_metric_body.py deleted file mode 100644 index 7b9ec883..00000000 --- a/asana/models/goal_gid_set_metric_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalGidSetMetricBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'GoalMetricRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """GoalGidSetMetricBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this GoalGidSetMetricBody. # noqa: E501 - - - :return: The data of this GoalGidSetMetricBody. # noqa: E501 - :rtype: GoalMetricRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this GoalGidSetMetricBody. - - - :param data: The data of this GoalGidSetMetricBody. # noqa: E501 - :type: GoalMetricRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalGidSetMetricBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalGidSetMetricBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_gid_set_metric_current_value_body.py b/asana/models/goal_gid_set_metric_current_value_body.py deleted file mode 100644 index 37b08b7b..00000000 --- a/asana/models/goal_gid_set_metric_current_value_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalGidSetMetricCurrentValueBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'GoalMetricCurrentValueRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """GoalGidSetMetricCurrentValueBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this GoalGidSetMetricCurrentValueBody. # noqa: E501 - - - :return: The data of this GoalGidSetMetricCurrentValueBody. # noqa: E501 - :rtype: GoalMetricCurrentValueRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this GoalGidSetMetricCurrentValueBody. - - - :param data: The data of this GoalGidSetMetricCurrentValueBody. # noqa: E501 - :type: GoalMetricCurrentValueRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalGidSetMetricCurrentValueBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalGidSetMetricCurrentValueBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_membership_base.py b/asana/models/goal_membership_base.py deleted file mode 100644 index 07eeb459..00000000 --- a/asana/models/goal_membership_base.py +++ /dev/null @@ -1,280 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalMembershipBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'resource_subtype': 'str', - 'member': 'MembershipCompactMember', - 'parent': 'MembershipCompactParent', - 'role': 'str', - 'goal': 'MembershipCompactGoal' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'member': 'member', - 'parent': 'parent', - 'role': 'role', - 'goal': 'goal' - } - - def __init__(self, gid=None, resource_type=None, resource_subtype=None, member=None, parent=None, role=None, goal=None): # noqa: E501 - """GoalMembershipBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._resource_subtype = None - self._member = None - self._parent = None - self._role = None - self._goal = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if member is not None: - self.member = member - if parent is not None: - self.parent = parent - if role is not None: - self.role = role - if goal is not None: - self.goal = goal - - @property - def gid(self): - """Gets the gid of this GoalMembershipBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalMembershipBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalMembershipBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalMembershipBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalMembershipBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalMembershipBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalMembershipBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalMembershipBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this GoalMembershipBase. # noqa: E501 - - The type of membership. # noqa: E501 - - :return: The resource_subtype of this GoalMembershipBase. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this GoalMembershipBase. - - The type of membership. # noqa: E501 - - :param resource_subtype: The resource_subtype of this GoalMembershipBase. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def member(self): - """Gets the member of this GoalMembershipBase. # noqa: E501 - - - :return: The member of this GoalMembershipBase. # noqa: E501 - :rtype: MembershipCompactMember - """ - return self._member - - @member.setter - def member(self, member): - """Sets the member of this GoalMembershipBase. - - - :param member: The member of this GoalMembershipBase. # noqa: E501 - :type: MembershipCompactMember - """ - - self._member = member - - @property - def parent(self): - """Gets the parent of this GoalMembershipBase. # noqa: E501 - - - :return: The parent of this GoalMembershipBase. # noqa: E501 - :rtype: MembershipCompactParent - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this GoalMembershipBase. - - - :param parent: The parent of this GoalMembershipBase. # noqa: E501 - :type: MembershipCompactParent - """ - - self._parent = parent - - @property - def role(self): - """Gets the role of this GoalMembershipBase. # noqa: E501 - - Describes if the member is a commenter or editor in goal. # noqa: E501 - - :return: The role of this GoalMembershipBase. # noqa: E501 - :rtype: str - """ - return self._role - - @role.setter - def role(self, role): - """Sets the role of this GoalMembershipBase. - - Describes if the member is a commenter or editor in goal. # noqa: E501 - - :param role: The role of this GoalMembershipBase. # noqa: E501 - :type: str - """ - allowed_values = ["commenter", "editor"] # noqa: E501 - if role not in allowed_values: - raise ValueError( - "Invalid value for `role` ({0}), must be one of {1}" # noqa: E501 - .format(role, allowed_values) - ) - - self._role = role - - @property - def goal(self): - """Gets the goal of this GoalMembershipBase. # noqa: E501 - - - :return: The goal of this GoalMembershipBase. # noqa: E501 - :rtype: MembershipCompactGoal - """ - return self._goal - - @goal.setter - def goal(self, goal): - """Sets the goal of this GoalMembershipBase. - - - :param goal: The goal of this GoalMembershipBase. # noqa: E501 - :type: MembershipCompactGoal - """ - - self._goal = goal - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalMembershipBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalMembershipBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_membership_base_goal.py b/asana/models/goal_membership_base_goal.py deleted file mode 100644 index 35cfe975..00000000 --- a/asana/models/goal_membership_base_goal.py +++ /dev/null @@ -1,194 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalMembershipBaseGoal(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'owner': 'CustomFieldResponseCreatedBy' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'owner': 'owner' - } - - def __init__(self, gid=None, resource_type=None, name=None, owner=None): # noqa: E501 - """GoalMembershipBaseGoal - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._owner = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if owner is not None: - self.owner = owner - - @property - def gid(self): - """Gets the gid of this GoalMembershipBaseGoal. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalMembershipBaseGoal. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalMembershipBaseGoal. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalMembershipBaseGoal. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalMembershipBaseGoal. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalMembershipBaseGoal. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalMembershipBaseGoal. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalMembershipBaseGoal. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this GoalMembershipBaseGoal. # noqa: E501 - - The name of the goal. # noqa: E501 - - :return: The name of this GoalMembershipBaseGoal. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this GoalMembershipBaseGoal. - - The name of the goal. # noqa: E501 - - :param name: The name of this GoalMembershipBaseGoal. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def owner(self): - """Gets the owner of this GoalMembershipBaseGoal. # noqa: E501 - - - :return: The owner of this GoalMembershipBaseGoal. # noqa: E501 - :rtype: CustomFieldResponseCreatedBy - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this GoalMembershipBaseGoal. - - - :param owner: The owner of this GoalMembershipBaseGoal. # noqa: E501 - :type: CustomFieldResponseCreatedBy - """ - - self._owner = owner - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalMembershipBaseGoal, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalMembershipBaseGoal): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_membership_compact.py b/asana/models/goal_membership_compact.py deleted file mode 100644 index 8382fdf3..00000000 --- a/asana/models/goal_membership_compact.py +++ /dev/null @@ -1,336 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalMembershipCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'resource_subtype': 'str', - 'member': 'MembershipCompactMember', - 'parent': 'MembershipCompactParent', - 'role': 'str', - 'goal': 'MembershipCompactGoal', - 'is_commenter': 'bool', - 'is_editor': 'bool' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'member': 'member', - 'parent': 'parent', - 'role': 'role', - 'goal': 'goal', - 'is_commenter': 'is_commenter', - 'is_editor': 'is_editor' - } - - def __init__(self, gid=None, resource_type=None, resource_subtype=None, member=None, parent=None, role=None, goal=None, is_commenter=None, is_editor=None): # noqa: E501 - """GoalMembershipCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._resource_subtype = None - self._member = None - self._parent = None - self._role = None - self._goal = None - self._is_commenter = None - self._is_editor = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if member is not None: - self.member = member - if parent is not None: - self.parent = parent - if role is not None: - self.role = role - if goal is not None: - self.goal = goal - if is_commenter is not None: - self.is_commenter = is_commenter - if is_editor is not None: - self.is_editor = is_editor - - @property - def gid(self): - """Gets the gid of this GoalMembershipCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalMembershipCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalMembershipCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalMembershipCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalMembershipCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalMembershipCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalMembershipCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalMembershipCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this GoalMembershipCompact. # noqa: E501 - - The type of membership. # noqa: E501 - - :return: The resource_subtype of this GoalMembershipCompact. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this GoalMembershipCompact. - - The type of membership. # noqa: E501 - - :param resource_subtype: The resource_subtype of this GoalMembershipCompact. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def member(self): - """Gets the member of this GoalMembershipCompact. # noqa: E501 - - - :return: The member of this GoalMembershipCompact. # noqa: E501 - :rtype: MembershipCompactMember - """ - return self._member - - @member.setter - def member(self, member): - """Sets the member of this GoalMembershipCompact. - - - :param member: The member of this GoalMembershipCompact. # noqa: E501 - :type: MembershipCompactMember - """ - - self._member = member - - @property - def parent(self): - """Gets the parent of this GoalMembershipCompact. # noqa: E501 - - - :return: The parent of this GoalMembershipCompact. # noqa: E501 - :rtype: MembershipCompactParent - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this GoalMembershipCompact. - - - :param parent: The parent of this GoalMembershipCompact. # noqa: E501 - :type: MembershipCompactParent - """ - - self._parent = parent - - @property - def role(self): - """Gets the role of this GoalMembershipCompact. # noqa: E501 - - Describes if the member is a commenter or editor in goal. # noqa: E501 - - :return: The role of this GoalMembershipCompact. # noqa: E501 - :rtype: str - """ - return self._role - - @role.setter - def role(self, role): - """Sets the role of this GoalMembershipCompact. - - Describes if the member is a commenter or editor in goal. # noqa: E501 - - :param role: The role of this GoalMembershipCompact. # noqa: E501 - :type: str - """ - allowed_values = ["commenter", "editor"] # noqa: E501 - if role not in allowed_values: - raise ValueError( - "Invalid value for `role` ({0}), must be one of {1}" # noqa: E501 - .format(role, allowed_values) - ) - - self._role = role - - @property - def goal(self): - """Gets the goal of this GoalMembershipCompact. # noqa: E501 - - - :return: The goal of this GoalMembershipCompact. # noqa: E501 - :rtype: MembershipCompactGoal - """ - return self._goal - - @goal.setter - def goal(self, goal): - """Sets the goal of this GoalMembershipCompact. - - - :param goal: The goal of this GoalMembershipCompact. # noqa: E501 - :type: MembershipCompactGoal - """ - - self._goal = goal - - @property - def is_commenter(self): - """Gets the is_commenter of this GoalMembershipCompact. # noqa: E501 - - *Deprecated: new integrations should prefer the `role` field.* Describes if the member is comment only in goal. # noqa: E501 - - :return: The is_commenter of this GoalMembershipCompact. # noqa: E501 - :rtype: bool - """ - return self._is_commenter - - @is_commenter.setter - def is_commenter(self, is_commenter): - """Sets the is_commenter of this GoalMembershipCompact. - - *Deprecated: new integrations should prefer the `role` field.* Describes if the member is comment only in goal. # noqa: E501 - - :param is_commenter: The is_commenter of this GoalMembershipCompact. # noqa: E501 - :type: bool - """ - - self._is_commenter = is_commenter - - @property - def is_editor(self): - """Gets the is_editor of this GoalMembershipCompact. # noqa: E501 - - *Deprecated: new integrations should prefer the `role` field.* Describes if the member is editor in goal. # noqa: E501 - - :return: The is_editor of this GoalMembershipCompact. # noqa: E501 - :rtype: bool - """ - return self._is_editor - - @is_editor.setter - def is_editor(self, is_editor): - """Sets the is_editor of this GoalMembershipCompact. - - *Deprecated: new integrations should prefer the `role` field.* Describes if the member is editor in goal. # noqa: E501 - - :param is_editor: The is_editor of this GoalMembershipCompact. # noqa: E501 - :type: bool - """ - - self._is_editor = is_editor - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalMembershipCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalMembershipCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_membership_response.py b/asana/models/goal_membership_response.py deleted file mode 100644 index 532383c0..00000000 --- a/asana/models/goal_membership_response.py +++ /dev/null @@ -1,332 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalMembershipResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'resource_subtype': 'str', - 'member': 'MembershipCompactMember', - 'parent': 'MembershipCompactParent', - 'role': 'str', - 'goal': 'MembershipCompactGoal', - 'user': 'GoalMembershipResponseUser', - 'workspace': 'GoalMembershipResponseWorkspace' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'member': 'member', - 'parent': 'parent', - 'role': 'role', - 'goal': 'goal', - 'user': 'user', - 'workspace': 'workspace' - } - - def __init__(self, gid=None, resource_type=None, resource_subtype=None, member=None, parent=None, role=None, goal=None, user=None, workspace=None): # noqa: E501 - """GoalMembershipResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._resource_subtype = None - self._member = None - self._parent = None - self._role = None - self._goal = None - self._user = None - self._workspace = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if member is not None: - self.member = member - if parent is not None: - self.parent = parent - if role is not None: - self.role = role - if goal is not None: - self.goal = goal - if user is not None: - self.user = user - if workspace is not None: - self.workspace = workspace - - @property - def gid(self): - """Gets the gid of this GoalMembershipResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalMembershipResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalMembershipResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalMembershipResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalMembershipResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalMembershipResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this GoalMembershipResponse. # noqa: E501 - - The type of membership. # noqa: E501 - - :return: The resource_subtype of this GoalMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this GoalMembershipResponse. - - The type of membership. # noqa: E501 - - :param resource_subtype: The resource_subtype of this GoalMembershipResponse. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def member(self): - """Gets the member of this GoalMembershipResponse. # noqa: E501 - - - :return: The member of this GoalMembershipResponse. # noqa: E501 - :rtype: MembershipCompactMember - """ - return self._member - - @member.setter - def member(self, member): - """Sets the member of this GoalMembershipResponse. - - - :param member: The member of this GoalMembershipResponse. # noqa: E501 - :type: MembershipCompactMember - """ - - self._member = member - - @property - def parent(self): - """Gets the parent of this GoalMembershipResponse. # noqa: E501 - - - :return: The parent of this GoalMembershipResponse. # noqa: E501 - :rtype: MembershipCompactParent - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this GoalMembershipResponse. - - - :param parent: The parent of this GoalMembershipResponse. # noqa: E501 - :type: MembershipCompactParent - """ - - self._parent = parent - - @property - def role(self): - """Gets the role of this GoalMembershipResponse. # noqa: E501 - - Describes if the member is a commenter or editor in goal. # noqa: E501 - - :return: The role of this GoalMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._role - - @role.setter - def role(self, role): - """Sets the role of this GoalMembershipResponse. - - Describes if the member is a commenter or editor in goal. # noqa: E501 - - :param role: The role of this GoalMembershipResponse. # noqa: E501 - :type: str - """ - allowed_values = ["commenter", "editor"] # noqa: E501 - if role not in allowed_values: - raise ValueError( - "Invalid value for `role` ({0}), must be one of {1}" # noqa: E501 - .format(role, allowed_values) - ) - - self._role = role - - @property - def goal(self): - """Gets the goal of this GoalMembershipResponse. # noqa: E501 - - - :return: The goal of this GoalMembershipResponse. # noqa: E501 - :rtype: MembershipCompactGoal - """ - return self._goal - - @goal.setter - def goal(self, goal): - """Sets the goal of this GoalMembershipResponse. - - - :param goal: The goal of this GoalMembershipResponse. # noqa: E501 - :type: MembershipCompactGoal - """ - - self._goal = goal - - @property - def user(self): - """Gets the user of this GoalMembershipResponse. # noqa: E501 - - - :return: The user of this GoalMembershipResponse. # noqa: E501 - :rtype: GoalMembershipResponseUser - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this GoalMembershipResponse. - - - :param user: The user of this GoalMembershipResponse. # noqa: E501 - :type: GoalMembershipResponseUser - """ - - self._user = user - - @property - def workspace(self): - """Gets the workspace of this GoalMembershipResponse. # noqa: E501 - - - :return: The workspace of this GoalMembershipResponse. # noqa: E501 - :rtype: GoalMembershipResponseWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this GoalMembershipResponse. - - - :param workspace: The workspace of this GoalMembershipResponse. # noqa: E501 - :type: GoalMembershipResponseWorkspace - """ - - self._workspace = workspace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalMembershipResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalMembershipResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_membership_response_user.py b/asana/models/goal_membership_response_user.py deleted file mode 100644 index f27bfda7..00000000 --- a/asana/models/goal_membership_response_user.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalMembershipResponseUser(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """GoalMembershipResponseUser - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this GoalMembershipResponseUser. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalMembershipResponseUser. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalMembershipResponseUser. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalMembershipResponseUser. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalMembershipResponseUser. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalMembershipResponseUser. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalMembershipResponseUser. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalMembershipResponseUser. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this GoalMembershipResponseUser. # noqa: E501 - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :return: The name of this GoalMembershipResponseUser. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this GoalMembershipResponseUser. - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :param name: The name of this GoalMembershipResponseUser. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalMembershipResponseUser, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalMembershipResponseUser): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_membership_response_workspace.py b/asana/models/goal_membership_response_workspace.py deleted file mode 100644 index 582fba84..00000000 --- a/asana/models/goal_membership_response_workspace.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalMembershipResponseWorkspace(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """GoalMembershipResponseWorkspace - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this GoalMembershipResponseWorkspace. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalMembershipResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalMembershipResponseWorkspace. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalMembershipResponseWorkspace. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalMembershipResponseWorkspace. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalMembershipResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalMembershipResponseWorkspace. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalMembershipResponseWorkspace. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this GoalMembershipResponseWorkspace. # noqa: E501 - - The name of the workspace. # noqa: E501 - - :return: The name of this GoalMembershipResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this GoalMembershipResponseWorkspace. - - The name of the workspace. # noqa: E501 - - :param name: The name of this GoalMembershipResponseWorkspace. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalMembershipResponseWorkspace, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalMembershipResponseWorkspace): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_metric_base.py b/asana/models/goal_metric_base.py deleted file mode 100644 index 6e9a18d7..00000000 --- a/asana/models/goal_metric_base.py +++ /dev/null @@ -1,410 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalMetricBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'resource_subtype': 'str', - 'precision': 'int', - 'unit': 'str', - 'currency_code': 'str', - 'initial_number_value': 'float', - 'target_number_value': 'float', - 'current_number_value': 'float', - 'current_display_value': 'str', - 'progress_source': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'precision': 'precision', - 'unit': 'unit', - 'currency_code': 'currency_code', - 'initial_number_value': 'initial_number_value', - 'target_number_value': 'target_number_value', - 'current_number_value': 'current_number_value', - 'current_display_value': 'current_display_value', - 'progress_source': 'progress_source' - } - - def __init__(self, gid=None, resource_type=None, resource_subtype=None, precision=None, unit=None, currency_code=None, initial_number_value=None, target_number_value=None, current_number_value=None, current_display_value=None, progress_source=None): # noqa: E501 - """GoalMetricBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._resource_subtype = None - self._precision = None - self._unit = None - self._currency_code = None - self._initial_number_value = None - self._target_number_value = None - self._current_number_value = None - self._current_display_value = None - self._progress_source = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if precision is not None: - self.precision = precision - if unit is not None: - self.unit = unit - if currency_code is not None: - self.currency_code = currency_code - if initial_number_value is not None: - self.initial_number_value = initial_number_value - if target_number_value is not None: - self.target_number_value = target_number_value - if current_number_value is not None: - self.current_number_value = current_number_value - if current_display_value is not None: - self.current_display_value = current_display_value - if progress_source is not None: - self.progress_source = progress_source - - @property - def gid(self): - """Gets the gid of this GoalMetricBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalMetricBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalMetricBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalMetricBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalMetricBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalMetricBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalMetricBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalMetricBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this GoalMetricBase. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this GoalMetricBase. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this GoalMetricBase. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this GoalMetricBase. # noqa: E501 - :type: str - """ - allowed_values = ["number"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def precision(self): - """Gets the precision of this GoalMetricBase. # noqa: E501 - - *Conditional*. Only relevant for goal metrics of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. # noqa: E501 - - :return: The precision of this GoalMetricBase. # noqa: E501 - :rtype: int - """ - return self._precision - - @precision.setter - def precision(self, precision): - """Sets the precision of this GoalMetricBase. - - *Conditional*. Only relevant for goal metrics of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. # noqa: E501 - - :param precision: The precision of this GoalMetricBase. # noqa: E501 - :type: int - """ - - self._precision = precision - - @property - def unit(self): - """Gets the unit of this GoalMetricBase. # noqa: E501 - - A supported unit of measure for the goal metric, or none. # noqa: E501 - - :return: The unit of this GoalMetricBase. # noqa: E501 - :rtype: str - """ - return self._unit - - @unit.setter - def unit(self, unit): - """Sets the unit of this GoalMetricBase. - - A supported unit of measure for the goal metric, or none. # noqa: E501 - - :param unit: The unit of this GoalMetricBase. # noqa: E501 - :type: str - """ - allowed_values = ["none", "currency", "percentage"] # noqa: E501 - if unit not in allowed_values: - raise ValueError( - "Invalid value for `unit` ({0}), must be one of {1}" # noqa: E501 - .format(unit, allowed_values) - ) - - self._unit = unit - - @property - def currency_code(self): - """Gets the currency_code of this GoalMetricBase. # noqa: E501 - - ISO 4217 currency code to format this custom field. This will be null if the `unit` is not `currency`. # noqa: E501 - - :return: The currency_code of this GoalMetricBase. # noqa: E501 - :rtype: str - """ - return self._currency_code - - @currency_code.setter - def currency_code(self, currency_code): - """Sets the currency_code of this GoalMetricBase. - - ISO 4217 currency code to format this custom field. This will be null if the `unit` is not `currency`. # noqa: E501 - - :param currency_code: The currency_code of this GoalMetricBase. # noqa: E501 - :type: str - """ - - self._currency_code = currency_code - - @property - def initial_number_value(self): - """Gets the initial_number_value of this GoalMetricBase. # noqa: E501 - - This number is the start value of a goal metric of type number. # noqa: E501 - - :return: The initial_number_value of this GoalMetricBase. # noqa: E501 - :rtype: float - """ - return self._initial_number_value - - @initial_number_value.setter - def initial_number_value(self, initial_number_value): - """Sets the initial_number_value of this GoalMetricBase. - - This number is the start value of a goal metric of type number. # noqa: E501 - - :param initial_number_value: The initial_number_value of this GoalMetricBase. # noqa: E501 - :type: float - """ - - self._initial_number_value = initial_number_value - - @property - def target_number_value(self): - """Gets the target_number_value of this GoalMetricBase. # noqa: E501 - - This number is the end value of a goal metric of type number. This number cannot equal `initial_number_value`. # noqa: E501 - - :return: The target_number_value of this GoalMetricBase. # noqa: E501 - :rtype: float - """ - return self._target_number_value - - @target_number_value.setter - def target_number_value(self, target_number_value): - """Sets the target_number_value of this GoalMetricBase. - - This number is the end value of a goal metric of type number. This number cannot equal `initial_number_value`. # noqa: E501 - - :param target_number_value: The target_number_value of this GoalMetricBase. # noqa: E501 - :type: float - """ - - self._target_number_value = target_number_value - - @property - def current_number_value(self): - """Gets the current_number_value of this GoalMetricBase. # noqa: E501 - - This number is the current value of a goal metric of type number. # noqa: E501 - - :return: The current_number_value of this GoalMetricBase. # noqa: E501 - :rtype: float - """ - return self._current_number_value - - @current_number_value.setter - def current_number_value(self, current_number_value): - """Sets the current_number_value of this GoalMetricBase. - - This number is the current value of a goal metric of type number. # noqa: E501 - - :param current_number_value: The current_number_value of this GoalMetricBase. # noqa: E501 - :type: float - """ - - self._current_number_value = current_number_value - - @property - def current_display_value(self): - """Gets the current_display_value of this GoalMetricBase. # noqa: E501 - - This string is the current value of a goal metric of type string. # noqa: E501 - - :return: The current_display_value of this GoalMetricBase. # noqa: E501 - :rtype: str - """ - return self._current_display_value - - @current_display_value.setter - def current_display_value(self, current_display_value): - """Sets the current_display_value of this GoalMetricBase. - - This string is the current value of a goal metric of type string. # noqa: E501 - - :param current_display_value: The current_display_value of this GoalMetricBase. # noqa: E501 - :type: str - """ - - self._current_display_value = current_display_value - - @property - def progress_source(self): - """Gets the progress_source of this GoalMetricBase. # noqa: E501 - - This field defines how the progress value of a goal metric is being calculated. A goal's progress can be provided manually by the user, calculated automatically from contributing subgoals or projects, or managed by an integration with an external data source, such as Salesforce. # noqa: E501 - - :return: The progress_source of this GoalMetricBase. # noqa: E501 - :rtype: str - """ - return self._progress_source - - @progress_source.setter - def progress_source(self, progress_source): - """Sets the progress_source of this GoalMetricBase. - - This field defines how the progress value of a goal metric is being calculated. A goal's progress can be provided manually by the user, calculated automatically from contributing subgoals or projects, or managed by an integration with an external data source, such as Salesforce. # noqa: E501 - - :param progress_source: The progress_source of this GoalMetricBase. # noqa: E501 - :type: str - """ - allowed_values = ["manual", "subgoal_progress", "project_task_completion", "project_milestone_completion", "external"] # noqa: E501 - if progress_source not in allowed_values: - raise ValueError( - "Invalid value for `progress_source` ({0}), must be one of {1}" # noqa: E501 - .format(progress_source, allowed_values) - ) - - self._progress_source = progress_source - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalMetricBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalMetricBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_metric_current_value_request.py b/asana/models/goal_metric_current_value_request.py deleted file mode 100644 index 8e55e606..00000000 --- a/asana/models/goal_metric_current_value_request.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalMetricCurrentValueRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'current_number_value': 'float' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'current_number_value': 'current_number_value' - } - - def __init__(self, gid=None, resource_type=None, current_number_value=None): # noqa: E501 - """GoalMetricCurrentValueRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._current_number_value = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if current_number_value is not None: - self.current_number_value = current_number_value - - @property - def gid(self): - """Gets the gid of this GoalMetricCurrentValueRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalMetricCurrentValueRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalMetricCurrentValueRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalMetricCurrentValueRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalMetricCurrentValueRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalMetricCurrentValueRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalMetricCurrentValueRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalMetricCurrentValueRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def current_number_value(self): - """Gets the current_number_value of this GoalMetricCurrentValueRequest. # noqa: E501 - - *Conditional*. This number is the current value of a goal metric of type number. # noqa: E501 - - :return: The current_number_value of this GoalMetricCurrentValueRequest. # noqa: E501 - :rtype: float - """ - return self._current_number_value - - @current_number_value.setter - def current_number_value(self, current_number_value): - """Sets the current_number_value of this GoalMetricCurrentValueRequest. - - *Conditional*. This number is the current value of a goal metric of type number. # noqa: E501 - - :param current_number_value: The current_number_value of this GoalMetricCurrentValueRequest. # noqa: E501 - :type: float - """ - - self._current_number_value = current_number_value - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalMetricCurrentValueRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalMetricCurrentValueRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_metric_request.py b/asana/models/goal_metric_request.py deleted file mode 100644 index a601b564..00000000 --- a/asana/models/goal_metric_request.py +++ /dev/null @@ -1,410 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalMetricRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'resource_subtype': 'str', - 'precision': 'int', - 'unit': 'str', - 'currency_code': 'str', - 'initial_number_value': 'float', - 'target_number_value': 'float', - 'current_number_value': 'float', - 'current_display_value': 'str', - 'progress_source': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'precision': 'precision', - 'unit': 'unit', - 'currency_code': 'currency_code', - 'initial_number_value': 'initial_number_value', - 'target_number_value': 'target_number_value', - 'current_number_value': 'current_number_value', - 'current_display_value': 'current_display_value', - 'progress_source': 'progress_source' - } - - def __init__(self, gid=None, resource_type=None, resource_subtype=None, precision=None, unit=None, currency_code=None, initial_number_value=None, target_number_value=None, current_number_value=None, current_display_value=None, progress_source=None): # noqa: E501 - """GoalMetricRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._resource_subtype = None - self._precision = None - self._unit = None - self._currency_code = None - self._initial_number_value = None - self._target_number_value = None - self._current_number_value = None - self._current_display_value = None - self._progress_source = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if precision is not None: - self.precision = precision - if unit is not None: - self.unit = unit - if currency_code is not None: - self.currency_code = currency_code - if initial_number_value is not None: - self.initial_number_value = initial_number_value - if target_number_value is not None: - self.target_number_value = target_number_value - if current_number_value is not None: - self.current_number_value = current_number_value - if current_display_value is not None: - self.current_display_value = current_display_value - if progress_source is not None: - self.progress_source = progress_source - - @property - def gid(self): - """Gets the gid of this GoalMetricRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalMetricRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalMetricRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalMetricRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalMetricRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalMetricRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalMetricRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalMetricRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this GoalMetricRequest. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this GoalMetricRequest. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this GoalMetricRequest. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this GoalMetricRequest. # noqa: E501 - :type: str - """ - allowed_values = ["number"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def precision(self): - """Gets the precision of this GoalMetricRequest. # noqa: E501 - - *Conditional*. Only relevant for goal metrics of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. # noqa: E501 - - :return: The precision of this GoalMetricRequest. # noqa: E501 - :rtype: int - """ - return self._precision - - @precision.setter - def precision(self, precision): - """Sets the precision of this GoalMetricRequest. - - *Conditional*. Only relevant for goal metrics of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. # noqa: E501 - - :param precision: The precision of this GoalMetricRequest. # noqa: E501 - :type: int - """ - - self._precision = precision - - @property - def unit(self): - """Gets the unit of this GoalMetricRequest. # noqa: E501 - - A supported unit of measure for the goal metric, or none. # noqa: E501 - - :return: The unit of this GoalMetricRequest. # noqa: E501 - :rtype: str - """ - return self._unit - - @unit.setter - def unit(self, unit): - """Sets the unit of this GoalMetricRequest. - - A supported unit of measure for the goal metric, or none. # noqa: E501 - - :param unit: The unit of this GoalMetricRequest. # noqa: E501 - :type: str - """ - allowed_values = ["none", "currency", "percentage"] # noqa: E501 - if unit not in allowed_values: - raise ValueError( - "Invalid value for `unit` ({0}), must be one of {1}" # noqa: E501 - .format(unit, allowed_values) - ) - - self._unit = unit - - @property - def currency_code(self): - """Gets the currency_code of this GoalMetricRequest. # noqa: E501 - - ISO 4217 currency code to format this custom field. This will be null if the `unit` is not `currency`. # noqa: E501 - - :return: The currency_code of this GoalMetricRequest. # noqa: E501 - :rtype: str - """ - return self._currency_code - - @currency_code.setter - def currency_code(self, currency_code): - """Sets the currency_code of this GoalMetricRequest. - - ISO 4217 currency code to format this custom field. This will be null if the `unit` is not `currency`. # noqa: E501 - - :param currency_code: The currency_code of this GoalMetricRequest. # noqa: E501 - :type: str - """ - - self._currency_code = currency_code - - @property - def initial_number_value(self): - """Gets the initial_number_value of this GoalMetricRequest. # noqa: E501 - - This number is the start value of a goal metric of type number. # noqa: E501 - - :return: The initial_number_value of this GoalMetricRequest. # noqa: E501 - :rtype: float - """ - return self._initial_number_value - - @initial_number_value.setter - def initial_number_value(self, initial_number_value): - """Sets the initial_number_value of this GoalMetricRequest. - - This number is the start value of a goal metric of type number. # noqa: E501 - - :param initial_number_value: The initial_number_value of this GoalMetricRequest. # noqa: E501 - :type: float - """ - - self._initial_number_value = initial_number_value - - @property - def target_number_value(self): - """Gets the target_number_value of this GoalMetricRequest. # noqa: E501 - - This number is the end value of a goal metric of type number. This number cannot equal `initial_number_value`. # noqa: E501 - - :return: The target_number_value of this GoalMetricRequest. # noqa: E501 - :rtype: float - """ - return self._target_number_value - - @target_number_value.setter - def target_number_value(self, target_number_value): - """Sets the target_number_value of this GoalMetricRequest. - - This number is the end value of a goal metric of type number. This number cannot equal `initial_number_value`. # noqa: E501 - - :param target_number_value: The target_number_value of this GoalMetricRequest. # noqa: E501 - :type: float - """ - - self._target_number_value = target_number_value - - @property - def current_number_value(self): - """Gets the current_number_value of this GoalMetricRequest. # noqa: E501 - - This number is the current value of a goal metric of type number. # noqa: E501 - - :return: The current_number_value of this GoalMetricRequest. # noqa: E501 - :rtype: float - """ - return self._current_number_value - - @current_number_value.setter - def current_number_value(self, current_number_value): - """Sets the current_number_value of this GoalMetricRequest. - - This number is the current value of a goal metric of type number. # noqa: E501 - - :param current_number_value: The current_number_value of this GoalMetricRequest. # noqa: E501 - :type: float - """ - - self._current_number_value = current_number_value - - @property - def current_display_value(self): - """Gets the current_display_value of this GoalMetricRequest. # noqa: E501 - - This string is the current value of a goal metric of type string. # noqa: E501 - - :return: The current_display_value of this GoalMetricRequest. # noqa: E501 - :rtype: str - """ - return self._current_display_value - - @current_display_value.setter - def current_display_value(self, current_display_value): - """Sets the current_display_value of this GoalMetricRequest. - - This string is the current value of a goal metric of type string. # noqa: E501 - - :param current_display_value: The current_display_value of this GoalMetricRequest. # noqa: E501 - :type: str - """ - - self._current_display_value = current_display_value - - @property - def progress_source(self): - """Gets the progress_source of this GoalMetricRequest. # noqa: E501 - - This field defines how the progress value of a goal metric is being calculated. A goal's progress can be provided manually by the user, calculated automatically from contributing subgoals or projects, or managed by an integration with an external data source, such as Salesforce. # noqa: E501 - - :return: The progress_source of this GoalMetricRequest. # noqa: E501 - :rtype: str - """ - return self._progress_source - - @progress_source.setter - def progress_source(self, progress_source): - """Sets the progress_source of this GoalMetricRequest. - - This field defines how the progress value of a goal metric is being calculated. A goal's progress can be provided manually by the user, calculated automatically from contributing subgoals or projects, or managed by an integration with an external data source, such as Salesforce. # noqa: E501 - - :param progress_source: The progress_source of this GoalMetricRequest. # noqa: E501 - :type: str - """ - allowed_values = ["manual", "subgoal_progress", "project_task_completion", "project_milestone_completion", "external"] # noqa: E501 - if progress_source not in allowed_values: - raise ValueError( - "Invalid value for `progress_source` ({0}), must be one of {1}" # noqa: E501 - .format(progress_source, allowed_values) - ) - - self._progress_source = progress_source - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalMetricRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalMetricRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_relationship_base.py b/asana/models/goal_relationship_base.py deleted file mode 100644 index 705e7b04..00000000 --- a/asana/models/goal_relationship_base.py +++ /dev/null @@ -1,254 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalRelationshipBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'resource_subtype': 'str', - 'supporting_resource': 'GoalRelationshipBaseSupportingResource', - 'contribution_weight': 'float', - 'supported_goal': 'GoalRelationshipBaseSupportedGoal' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'supporting_resource': 'supporting_resource', - 'contribution_weight': 'contribution_weight', - 'supported_goal': 'supported_goal' - } - - def __init__(self, gid=None, resource_type=None, resource_subtype=None, supporting_resource=None, contribution_weight=None, supported_goal=None): # noqa: E501 - """GoalRelationshipBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._resource_subtype = None - self._supporting_resource = None - self._contribution_weight = None - self._supported_goal = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if supporting_resource is not None: - self.supporting_resource = supporting_resource - if contribution_weight is not None: - self.contribution_weight = contribution_weight - if supported_goal is not None: - self.supported_goal = supported_goal - - @property - def gid(self): - """Gets the gid of this GoalRelationshipBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalRelationshipBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalRelationshipBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalRelationshipBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalRelationshipBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalRelationshipBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalRelationshipBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalRelationshipBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this GoalRelationshipBase. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this GoalRelationshipBase. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this GoalRelationshipBase. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this GoalRelationshipBase. # noqa: E501 - :type: str - """ - allowed_values = ["subgoal", "supporting_work"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def supporting_resource(self): - """Gets the supporting_resource of this GoalRelationshipBase. # noqa: E501 - - - :return: The supporting_resource of this GoalRelationshipBase. # noqa: E501 - :rtype: GoalRelationshipBaseSupportingResource - """ - return self._supporting_resource - - @supporting_resource.setter - def supporting_resource(self, supporting_resource): - """Sets the supporting_resource of this GoalRelationshipBase. - - - :param supporting_resource: The supporting_resource of this GoalRelationshipBase. # noqa: E501 - :type: GoalRelationshipBaseSupportingResource - """ - - self._supporting_resource = supporting_resource - - @property - def contribution_weight(self): - """Gets the contribution_weight of this GoalRelationshipBase. # noqa: E501 - - The weight that the supporting resource's progress contributes to the supported goal's progress. This can only be 0 or 1. # noqa: E501 - - :return: The contribution_weight of this GoalRelationshipBase. # noqa: E501 - :rtype: float - """ - return self._contribution_weight - - @contribution_weight.setter - def contribution_weight(self, contribution_weight): - """Sets the contribution_weight of this GoalRelationshipBase. - - The weight that the supporting resource's progress contributes to the supported goal's progress. This can only be 0 or 1. # noqa: E501 - - :param contribution_weight: The contribution_weight of this GoalRelationshipBase. # noqa: E501 - :type: float - """ - - self._contribution_weight = contribution_weight - - @property - def supported_goal(self): - """Gets the supported_goal of this GoalRelationshipBase. # noqa: E501 - - - :return: The supported_goal of this GoalRelationshipBase. # noqa: E501 - :rtype: GoalRelationshipBaseSupportedGoal - """ - return self._supported_goal - - @supported_goal.setter - def supported_goal(self, supported_goal): - """Sets the supported_goal of this GoalRelationshipBase. - - - :param supported_goal: The supported_goal of this GoalRelationshipBase. # noqa: E501 - :type: GoalRelationshipBaseSupportedGoal - """ - - self._supported_goal = supported_goal - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalRelationshipBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalRelationshipBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_relationship_base_supported_goal.py b/asana/models/goal_relationship_base_supported_goal.py deleted file mode 100644 index bed14096..00000000 --- a/asana/models/goal_relationship_base_supported_goal.py +++ /dev/null @@ -1,194 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalRelationshipBaseSupportedGoal(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'owner': 'CustomFieldResponseCreatedBy' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'owner': 'owner' - } - - def __init__(self, gid=None, resource_type=None, name=None, owner=None): # noqa: E501 - """GoalRelationshipBaseSupportedGoal - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._owner = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if owner is not None: - self.owner = owner - - @property - def gid(self): - """Gets the gid of this GoalRelationshipBaseSupportedGoal. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalRelationshipBaseSupportedGoal. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalRelationshipBaseSupportedGoal. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalRelationshipBaseSupportedGoal. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalRelationshipBaseSupportedGoal. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalRelationshipBaseSupportedGoal. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalRelationshipBaseSupportedGoal. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalRelationshipBaseSupportedGoal. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this GoalRelationshipBaseSupportedGoal. # noqa: E501 - - The name of the goal. # noqa: E501 - - :return: The name of this GoalRelationshipBaseSupportedGoal. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this GoalRelationshipBaseSupportedGoal. - - The name of the goal. # noqa: E501 - - :param name: The name of this GoalRelationshipBaseSupportedGoal. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def owner(self): - """Gets the owner of this GoalRelationshipBaseSupportedGoal. # noqa: E501 - - - :return: The owner of this GoalRelationshipBaseSupportedGoal. # noqa: E501 - :rtype: CustomFieldResponseCreatedBy - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this GoalRelationshipBaseSupportedGoal. - - - :param owner: The owner of this GoalRelationshipBaseSupportedGoal. # noqa: E501 - :type: CustomFieldResponseCreatedBy - """ - - self._owner = owner - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalRelationshipBaseSupportedGoal, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalRelationshipBaseSupportedGoal): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_relationship_base_supporting_resource.py b/asana/models/goal_relationship_base_supporting_resource.py deleted file mode 100644 index 725b71b0..00000000 --- a/asana/models/goal_relationship_base_supporting_resource.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalRelationshipBaseSupportingResource(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """GoalRelationshipBaseSupportingResource - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this GoalRelationshipBaseSupportingResource. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalRelationshipBaseSupportingResource. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalRelationshipBaseSupportingResource. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalRelationshipBaseSupportingResource. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalRelationshipBaseSupportingResource. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalRelationshipBaseSupportingResource. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalRelationshipBaseSupportingResource. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalRelationshipBaseSupportingResource. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this GoalRelationshipBaseSupportingResource. # noqa: E501 - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this GoalRelationshipBaseSupportingResource. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this GoalRelationshipBaseSupportingResource. - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this GoalRelationshipBaseSupportingResource. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalRelationshipBaseSupportingResource, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalRelationshipBaseSupportingResource): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_relationship_compact.py b/asana/models/goal_relationship_compact.py deleted file mode 100644 index 8110c297..00000000 --- a/asana/models/goal_relationship_compact.py +++ /dev/null @@ -1,228 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalRelationshipCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'resource_subtype': 'str', - 'supporting_resource': 'GoalRelationshipBaseSupportingResource', - 'contribution_weight': 'float' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'supporting_resource': 'supporting_resource', - 'contribution_weight': 'contribution_weight' - } - - def __init__(self, gid=None, resource_type=None, resource_subtype=None, supporting_resource=None, contribution_weight=None): # noqa: E501 - """GoalRelationshipCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._resource_subtype = None - self._supporting_resource = None - self._contribution_weight = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if supporting_resource is not None: - self.supporting_resource = supporting_resource - if contribution_weight is not None: - self.contribution_weight = contribution_weight - - @property - def gid(self): - """Gets the gid of this GoalRelationshipCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalRelationshipCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalRelationshipCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalRelationshipCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalRelationshipCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalRelationshipCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalRelationshipCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalRelationshipCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this GoalRelationshipCompact. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this GoalRelationshipCompact. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this GoalRelationshipCompact. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this GoalRelationshipCompact. # noqa: E501 - :type: str - """ - allowed_values = ["subgoal", "supporting_work"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def supporting_resource(self): - """Gets the supporting_resource of this GoalRelationshipCompact. # noqa: E501 - - - :return: The supporting_resource of this GoalRelationshipCompact. # noqa: E501 - :rtype: GoalRelationshipBaseSupportingResource - """ - return self._supporting_resource - - @supporting_resource.setter - def supporting_resource(self, supporting_resource): - """Sets the supporting_resource of this GoalRelationshipCompact. - - - :param supporting_resource: The supporting_resource of this GoalRelationshipCompact. # noqa: E501 - :type: GoalRelationshipBaseSupportingResource - """ - - self._supporting_resource = supporting_resource - - @property - def contribution_weight(self): - """Gets the contribution_weight of this GoalRelationshipCompact. # noqa: E501 - - The weight that the supporting resource's progress contributes to the supported goal's progress. This can only be 0 or 1. # noqa: E501 - - :return: The contribution_weight of this GoalRelationshipCompact. # noqa: E501 - :rtype: float - """ - return self._contribution_weight - - @contribution_weight.setter - def contribution_weight(self, contribution_weight): - """Sets the contribution_weight of this GoalRelationshipCompact. - - The weight that the supporting resource's progress contributes to the supported goal's progress. This can only be 0 or 1. # noqa: E501 - - :param contribution_weight: The contribution_weight of this GoalRelationshipCompact. # noqa: E501 - :type: float - """ - - self._contribution_weight = contribution_weight - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalRelationshipCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalRelationshipCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_relationship_request.py b/asana/models/goal_relationship_request.py deleted file mode 100644 index a650ad85..00000000 --- a/asana/models/goal_relationship_request.py +++ /dev/null @@ -1,254 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalRelationshipRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'resource_subtype': 'str', - 'supporting_resource': 'GoalRelationshipBaseSupportingResource', - 'contribution_weight': 'float', - 'supported_goal': 'GoalRelationshipBaseSupportedGoal' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'supporting_resource': 'supporting_resource', - 'contribution_weight': 'contribution_weight', - 'supported_goal': 'supported_goal' - } - - def __init__(self, gid=None, resource_type=None, resource_subtype=None, supporting_resource=None, contribution_weight=None, supported_goal=None): # noqa: E501 - """GoalRelationshipRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._resource_subtype = None - self._supporting_resource = None - self._contribution_weight = None - self._supported_goal = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if supporting_resource is not None: - self.supporting_resource = supporting_resource - if contribution_weight is not None: - self.contribution_weight = contribution_weight - if supported_goal is not None: - self.supported_goal = supported_goal - - @property - def gid(self): - """Gets the gid of this GoalRelationshipRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalRelationshipRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalRelationshipRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalRelationshipRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalRelationshipRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalRelationshipRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalRelationshipRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalRelationshipRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this GoalRelationshipRequest. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this GoalRelationshipRequest. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this GoalRelationshipRequest. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this GoalRelationshipRequest. # noqa: E501 - :type: str - """ - allowed_values = ["subgoal", "supporting_work"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def supporting_resource(self): - """Gets the supporting_resource of this GoalRelationshipRequest. # noqa: E501 - - - :return: The supporting_resource of this GoalRelationshipRequest. # noqa: E501 - :rtype: GoalRelationshipBaseSupportingResource - """ - return self._supporting_resource - - @supporting_resource.setter - def supporting_resource(self, supporting_resource): - """Sets the supporting_resource of this GoalRelationshipRequest. - - - :param supporting_resource: The supporting_resource of this GoalRelationshipRequest. # noqa: E501 - :type: GoalRelationshipBaseSupportingResource - """ - - self._supporting_resource = supporting_resource - - @property - def contribution_weight(self): - """Gets the contribution_weight of this GoalRelationshipRequest. # noqa: E501 - - The weight that the supporting resource's progress contributes to the supported goal's progress. This can only be 0 or 1. # noqa: E501 - - :return: The contribution_weight of this GoalRelationshipRequest. # noqa: E501 - :rtype: float - """ - return self._contribution_weight - - @contribution_weight.setter - def contribution_weight(self, contribution_weight): - """Sets the contribution_weight of this GoalRelationshipRequest. - - The weight that the supporting resource's progress contributes to the supported goal's progress. This can only be 0 or 1. # noqa: E501 - - :param contribution_weight: The contribution_weight of this GoalRelationshipRequest. # noqa: E501 - :type: float - """ - - self._contribution_weight = contribution_weight - - @property - def supported_goal(self): - """Gets the supported_goal of this GoalRelationshipRequest. # noqa: E501 - - - :return: The supported_goal of this GoalRelationshipRequest. # noqa: E501 - :rtype: GoalRelationshipBaseSupportedGoal - """ - return self._supported_goal - - @supported_goal.setter - def supported_goal(self, supported_goal): - """Sets the supported_goal of this GoalRelationshipRequest. - - - :param supported_goal: The supported_goal of this GoalRelationshipRequest. # noqa: E501 - :type: GoalRelationshipBaseSupportedGoal - """ - - self._supported_goal = supported_goal - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalRelationshipRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalRelationshipRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_relationship_response.py b/asana/models/goal_relationship_response.py deleted file mode 100644 index e57e4ea2..00000000 --- a/asana/models/goal_relationship_response.py +++ /dev/null @@ -1,254 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalRelationshipResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'resource_subtype': 'str', - 'supporting_resource': 'GoalRelationshipBaseSupportingResource', - 'contribution_weight': 'float', - 'supported_goal': 'GoalRelationshipBaseSupportedGoal' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'supporting_resource': 'supporting_resource', - 'contribution_weight': 'contribution_weight', - 'supported_goal': 'supported_goal' - } - - def __init__(self, gid=None, resource_type=None, resource_subtype=None, supporting_resource=None, contribution_weight=None, supported_goal=None): # noqa: E501 - """GoalRelationshipResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._resource_subtype = None - self._supporting_resource = None - self._contribution_weight = None - self._supported_goal = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if supporting_resource is not None: - self.supporting_resource = supporting_resource - if contribution_weight is not None: - self.contribution_weight = contribution_weight - if supported_goal is not None: - self.supported_goal = supported_goal - - @property - def gid(self): - """Gets the gid of this GoalRelationshipResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalRelationshipResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalRelationshipResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalRelationshipResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalRelationshipResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalRelationshipResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalRelationshipResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalRelationshipResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this GoalRelationshipResponse. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this GoalRelationshipResponse. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this GoalRelationshipResponse. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this GoalRelationshipResponse. # noqa: E501 - :type: str - """ - allowed_values = ["subgoal", "supporting_work"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def supporting_resource(self): - """Gets the supporting_resource of this GoalRelationshipResponse. # noqa: E501 - - - :return: The supporting_resource of this GoalRelationshipResponse. # noqa: E501 - :rtype: GoalRelationshipBaseSupportingResource - """ - return self._supporting_resource - - @supporting_resource.setter - def supporting_resource(self, supporting_resource): - """Sets the supporting_resource of this GoalRelationshipResponse. - - - :param supporting_resource: The supporting_resource of this GoalRelationshipResponse. # noqa: E501 - :type: GoalRelationshipBaseSupportingResource - """ - - self._supporting_resource = supporting_resource - - @property - def contribution_weight(self): - """Gets the contribution_weight of this GoalRelationshipResponse. # noqa: E501 - - The weight that the supporting resource's progress contributes to the supported goal's progress. This can only be 0 or 1. # noqa: E501 - - :return: The contribution_weight of this GoalRelationshipResponse. # noqa: E501 - :rtype: float - """ - return self._contribution_weight - - @contribution_weight.setter - def contribution_weight(self, contribution_weight): - """Sets the contribution_weight of this GoalRelationshipResponse. - - The weight that the supporting resource's progress contributes to the supported goal's progress. This can only be 0 or 1. # noqa: E501 - - :param contribution_weight: The contribution_weight of this GoalRelationshipResponse. # noqa: E501 - :type: float - """ - - self._contribution_weight = contribution_weight - - @property - def supported_goal(self): - """Gets the supported_goal of this GoalRelationshipResponse. # noqa: E501 - - - :return: The supported_goal of this GoalRelationshipResponse. # noqa: E501 - :rtype: GoalRelationshipBaseSupportedGoal - """ - return self._supported_goal - - @supported_goal.setter - def supported_goal(self, supported_goal): - """Sets the supported_goal of this GoalRelationshipResponse. - - - :param supported_goal: The supported_goal of this GoalRelationshipResponse. # noqa: E501 - :type: GoalRelationshipBaseSupportedGoal - """ - - self._supported_goal = supported_goal - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalRelationshipResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalRelationshipResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_relationship_response_array.py b/asana/models/goal_relationship_response_array.py deleted file mode 100644 index 81854e51..00000000 --- a/asana/models/goal_relationship_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalRelationshipResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[GoalRelationshipResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """GoalRelationshipResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this GoalRelationshipResponseArray. # noqa: E501 - - - :return: The data of this GoalRelationshipResponseArray. # noqa: E501 - :rtype: list[GoalRelationshipResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this GoalRelationshipResponseArray. - - - :param data: The data of this GoalRelationshipResponseArray. # noqa: E501 - :type: list[GoalRelationshipResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this GoalRelationshipResponseArray. # noqa: E501 - - - :return: The next_page of this GoalRelationshipResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this GoalRelationshipResponseArray. - - - :param next_page: The next_page of this GoalRelationshipResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalRelationshipResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalRelationshipResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_relationship_response_data.py b/asana/models/goal_relationship_response_data.py deleted file mode 100644 index f439b66b..00000000 --- a/asana/models/goal_relationship_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalRelationshipResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'GoalRelationshipResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """GoalRelationshipResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this GoalRelationshipResponseData. # noqa: E501 - - - :return: The data of this GoalRelationshipResponseData. # noqa: E501 - :rtype: GoalRelationshipResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this GoalRelationshipResponseData. - - - :param data: The data of this GoalRelationshipResponseData. # noqa: E501 - :type: GoalRelationshipResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalRelationshipResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalRelationshipResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_relationships_goal_relationship_gid_body.py b/asana/models/goal_relationships_goal_relationship_gid_body.py deleted file mode 100644 index 1b368eff..00000000 --- a/asana/models/goal_relationships_goal_relationship_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalRelationshipsGoalRelationshipGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'GoalRelationshipRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """GoalRelationshipsGoalRelationshipGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this GoalRelationshipsGoalRelationshipGidBody. # noqa: E501 - - - :return: The data of this GoalRelationshipsGoalRelationshipGidBody. # noqa: E501 - :rtype: GoalRelationshipRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this GoalRelationshipsGoalRelationshipGidBody. - - - :param data: The data of this GoalRelationshipsGoalRelationshipGidBody. # noqa: E501 - :type: GoalRelationshipRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalRelationshipsGoalRelationshipGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalRelationshipsGoalRelationshipGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_remove_subgoal_request.py b/asana/models/goal_remove_subgoal_request.py deleted file mode 100644 index 70ad2aba..00000000 --- a/asana/models/goal_remove_subgoal_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalRemoveSubgoalRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'subgoal': 'str' - } - - attribute_map = { - 'subgoal': 'subgoal' - } - - def __init__(self, subgoal=None): # noqa: E501 - """GoalRemoveSubgoalRequest - a model defined in Swagger""" # noqa: E501 - self._subgoal = None - self.discriminator = None - self.subgoal = subgoal - - @property - def subgoal(self): - """Gets the subgoal of this GoalRemoveSubgoalRequest. # noqa: E501 - - The goal gid to remove as subgoal from the parent goal # noqa: E501 - - :return: The subgoal of this GoalRemoveSubgoalRequest. # noqa: E501 - :rtype: str - """ - return self._subgoal - - @subgoal.setter - def subgoal(self, subgoal): - """Sets the subgoal of this GoalRemoveSubgoalRequest. - - The goal gid to remove as subgoal from the parent goal # noqa: E501 - - :param subgoal: The subgoal of this GoalRemoveSubgoalRequest. # noqa: E501 - :type: str - """ - if subgoal is None: - raise ValueError("Invalid value for `subgoal`, must not be `None`") # noqa: E501 - - self._subgoal = subgoal - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalRemoveSubgoalRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalRemoveSubgoalRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_remove_supporting_relationship_request.py b/asana/models/goal_remove_supporting_relationship_request.py deleted file mode 100644 index 82ff67d8..00000000 --- a/asana/models/goal_remove_supporting_relationship_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalRemoveSupportingRelationshipRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'supporting_resource': 'str' - } - - attribute_map = { - 'supporting_resource': 'supporting_resource' - } - - def __init__(self, supporting_resource=None): # noqa: E501 - """GoalRemoveSupportingRelationshipRequest - a model defined in Swagger""" # noqa: E501 - self._supporting_resource = None - self.discriminator = None - self.supporting_resource = supporting_resource - - @property - def supporting_resource(self): - """Gets the supporting_resource of this GoalRemoveSupportingRelationshipRequest. # noqa: E501 - - The gid of the supporting resource to remove from the parent goal. Must be the gid of a goal, project, or portfolio. # noqa: E501 - - :return: The supporting_resource of this GoalRemoveSupportingRelationshipRequest. # noqa: E501 - :rtype: str - """ - return self._supporting_resource - - @supporting_resource.setter - def supporting_resource(self, supporting_resource): - """Sets the supporting_resource of this GoalRemoveSupportingRelationshipRequest. - - The gid of the supporting resource to remove from the parent goal. Must be the gid of a goal, project, or portfolio. # noqa: E501 - - :param supporting_resource: The supporting_resource of this GoalRemoveSupportingRelationshipRequest. # noqa: E501 - :type: str - """ - if supporting_resource is None: - raise ValueError("Invalid value for `supporting_resource`, must not be `None`") # noqa: E501 - - self._supporting_resource = supporting_resource - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalRemoveSupportingRelationshipRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalRemoveSupportingRelationshipRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_request.py b/asana/models/goal_request.py deleted file mode 100644 index f83780fd..00000000 --- a/asana/models/goal_request.py +++ /dev/null @@ -1,474 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'html_notes': 'str', - 'notes': 'str', - 'due_on': 'str', - 'start_on': 'str', - 'is_workspace_level': 'bool', - 'liked': 'bool', - 'team': 'str', - 'workspace': 'str', - 'time_period': 'str', - 'owner': 'str', - 'followers': 'list[str]' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'html_notes': 'html_notes', - 'notes': 'notes', - 'due_on': 'due_on', - 'start_on': 'start_on', - 'is_workspace_level': 'is_workspace_level', - 'liked': 'liked', - 'team': 'team', - 'workspace': 'workspace', - 'time_period': 'time_period', - 'owner': 'owner', - 'followers': 'followers' - } - - def __init__(self, gid=None, resource_type=None, name=None, html_notes=None, notes=None, due_on=None, start_on=None, is_workspace_level=None, liked=None, team=None, workspace=None, time_period=None, owner=None, followers=None): # noqa: E501 - """GoalRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._html_notes = None - self._notes = None - self._due_on = None - self._start_on = None - self._is_workspace_level = None - self._liked = None - self._team = None - self._workspace = None - self._time_period = None - self._owner = None - self._followers = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if html_notes is not None: - self.html_notes = html_notes - if notes is not None: - self.notes = notes - if due_on is not None: - self.due_on = due_on - if start_on is not None: - self.start_on = start_on - if is_workspace_level is not None: - self.is_workspace_level = is_workspace_level - if liked is not None: - self.liked = liked - if team is not None: - self.team = team - if workspace is not None: - self.workspace = workspace - if time_period is not None: - self.time_period = time_period - if owner is not None: - self.owner = owner - if followers is not None: - self.followers = followers - - @property - def gid(self): - """Gets the gid of this GoalRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this GoalRequest. # noqa: E501 - - The name of the goal. # noqa: E501 - - :return: The name of this GoalRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this GoalRequest. - - The name of the goal. # noqa: E501 - - :param name: The name of this GoalRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def html_notes(self): - """Gets the html_notes of this GoalRequest. # noqa: E501 - - The notes of the goal with formatting as HTML. # noqa: E501 - - :return: The html_notes of this GoalRequest. # noqa: E501 - :rtype: str - """ - return self._html_notes - - @html_notes.setter - def html_notes(self, html_notes): - """Sets the html_notes of this GoalRequest. - - The notes of the goal with formatting as HTML. # noqa: E501 - - :param html_notes: The html_notes of this GoalRequest. # noqa: E501 - :type: str - """ - - self._html_notes = html_notes - - @property - def notes(self): - """Gets the notes of this GoalRequest. # noqa: E501 - - Free-form textual information associated with the goal (i.e. its description). # noqa: E501 - - :return: The notes of this GoalRequest. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this GoalRequest. - - Free-form textual information associated with the goal (i.e. its description). # noqa: E501 - - :param notes: The notes of this GoalRequest. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def due_on(self): - """Gets the due_on of this GoalRequest. # noqa: E501 - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :return: The due_on of this GoalRequest. # noqa: E501 - :rtype: str - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this GoalRequest. - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :param due_on: The due_on of this GoalRequest. # noqa: E501 - :type: str - """ - - self._due_on = due_on - - @property - def start_on(self): - """Gets the start_on of this GoalRequest. # noqa: E501 - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :return: The start_on of this GoalRequest. # noqa: E501 - :rtype: str - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this GoalRequest. - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :param start_on: The start_on of this GoalRequest. # noqa: E501 - :type: str - """ - - self._start_on = start_on - - @property - def is_workspace_level(self): - """Gets the is_workspace_level of this GoalRequest. # noqa: E501 - - *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. # noqa: E501 - - :return: The is_workspace_level of this GoalRequest. # noqa: E501 - :rtype: bool - """ - return self._is_workspace_level - - @is_workspace_level.setter - def is_workspace_level(self, is_workspace_level): - """Sets the is_workspace_level of this GoalRequest. - - *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. # noqa: E501 - - :param is_workspace_level: The is_workspace_level of this GoalRequest. # noqa: E501 - :type: bool - """ - - self._is_workspace_level = is_workspace_level - - @property - def liked(self): - """Gets the liked of this GoalRequest. # noqa: E501 - - True if the goal is liked by the authorized user, false if not. # noqa: E501 - - :return: The liked of this GoalRequest. # noqa: E501 - :rtype: bool - """ - return self._liked - - @liked.setter - def liked(self, liked): - """Sets the liked of this GoalRequest. - - True if the goal is liked by the authorized user, false if not. # noqa: E501 - - :param liked: The liked of this GoalRequest. # noqa: E501 - :type: bool - """ - - self._liked = liked - - @property - def team(self): - """Gets the team of this GoalRequest. # noqa: E501 - - *Conditional*. This property is only present when the `workspace` provided is an organization. # noqa: E501 - - :return: The team of this GoalRequest. # noqa: E501 - :rtype: str - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this GoalRequest. - - *Conditional*. This property is only present when the `workspace` provided is an organization. # noqa: E501 - - :param team: The team of this GoalRequest. # noqa: E501 - :type: str - """ - - self._team = team - - @property - def workspace(self): - """Gets the workspace of this GoalRequest. # noqa: E501 - - The `gid` of a workspace. # noqa: E501 - - :return: The workspace of this GoalRequest. # noqa: E501 - :rtype: str - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this GoalRequest. - - The `gid` of a workspace. # noqa: E501 - - :param workspace: The workspace of this GoalRequest. # noqa: E501 - :type: str - """ - - self._workspace = workspace - - @property - def time_period(self): - """Gets the time_period of this GoalRequest. # noqa: E501 - - The `gid` of a time period. # noqa: E501 - - :return: The time_period of this GoalRequest. # noqa: E501 - :rtype: str - """ - return self._time_period - - @time_period.setter - def time_period(self, time_period): - """Sets the time_period of this GoalRequest. - - The `gid` of a time period. # noqa: E501 - - :param time_period: The time_period of this GoalRequest. # noqa: E501 - :type: str - """ - - self._time_period = time_period - - @property - def owner(self): - """Gets the owner of this GoalRequest. # noqa: E501 - - The `gid` of a user. # noqa: E501 - - :return: The owner of this GoalRequest. # noqa: E501 - :rtype: str - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this GoalRequest. - - The `gid` of a user. # noqa: E501 - - :param owner: The owner of this GoalRequest. # noqa: E501 - :type: str - """ - - self._owner = owner - - @property - def followers(self): - """Gets the followers of this GoalRequest. # noqa: E501 - - - :return: The followers of this GoalRequest. # noqa: E501 - :rtype: list[str] - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this GoalRequest. - - - :param followers: The followers of this GoalRequest. # noqa: E501 - :type: list[str] - """ - - self._followers = followers - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_request_base.py b/asana/models/goal_request_base.py deleted file mode 100644 index c6c68fca..00000000 --- a/asana/models/goal_request_base.py +++ /dev/null @@ -1,448 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalRequestBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'html_notes': 'str', - 'notes': 'str', - 'due_on': 'str', - 'start_on': 'str', - 'is_workspace_level': 'bool', - 'liked': 'bool', - 'team': 'str', - 'workspace': 'str', - 'time_period': 'str', - 'owner': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'html_notes': 'html_notes', - 'notes': 'notes', - 'due_on': 'due_on', - 'start_on': 'start_on', - 'is_workspace_level': 'is_workspace_level', - 'liked': 'liked', - 'team': 'team', - 'workspace': 'workspace', - 'time_period': 'time_period', - 'owner': 'owner' - } - - def __init__(self, gid=None, resource_type=None, name=None, html_notes=None, notes=None, due_on=None, start_on=None, is_workspace_level=None, liked=None, team=None, workspace=None, time_period=None, owner=None): # noqa: E501 - """GoalRequestBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._html_notes = None - self._notes = None - self._due_on = None - self._start_on = None - self._is_workspace_level = None - self._liked = None - self._team = None - self._workspace = None - self._time_period = None - self._owner = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if html_notes is not None: - self.html_notes = html_notes - if notes is not None: - self.notes = notes - if due_on is not None: - self.due_on = due_on - if start_on is not None: - self.start_on = start_on - if is_workspace_level is not None: - self.is_workspace_level = is_workspace_level - if liked is not None: - self.liked = liked - if team is not None: - self.team = team - if workspace is not None: - self.workspace = workspace - if time_period is not None: - self.time_period = time_period - if owner is not None: - self.owner = owner - - @property - def gid(self): - """Gets the gid of this GoalRequestBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalRequestBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalRequestBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalRequestBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalRequestBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalRequestBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalRequestBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalRequestBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this GoalRequestBase. # noqa: E501 - - The name of the goal. # noqa: E501 - - :return: The name of this GoalRequestBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this GoalRequestBase. - - The name of the goal. # noqa: E501 - - :param name: The name of this GoalRequestBase. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def html_notes(self): - """Gets the html_notes of this GoalRequestBase. # noqa: E501 - - The notes of the goal with formatting as HTML. # noqa: E501 - - :return: The html_notes of this GoalRequestBase. # noqa: E501 - :rtype: str - """ - return self._html_notes - - @html_notes.setter - def html_notes(self, html_notes): - """Sets the html_notes of this GoalRequestBase. - - The notes of the goal with formatting as HTML. # noqa: E501 - - :param html_notes: The html_notes of this GoalRequestBase. # noqa: E501 - :type: str - """ - - self._html_notes = html_notes - - @property - def notes(self): - """Gets the notes of this GoalRequestBase. # noqa: E501 - - Free-form textual information associated with the goal (i.e. its description). # noqa: E501 - - :return: The notes of this GoalRequestBase. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this GoalRequestBase. - - Free-form textual information associated with the goal (i.e. its description). # noqa: E501 - - :param notes: The notes of this GoalRequestBase. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def due_on(self): - """Gets the due_on of this GoalRequestBase. # noqa: E501 - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :return: The due_on of this GoalRequestBase. # noqa: E501 - :rtype: str - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this GoalRequestBase. - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :param due_on: The due_on of this GoalRequestBase. # noqa: E501 - :type: str - """ - - self._due_on = due_on - - @property - def start_on(self): - """Gets the start_on of this GoalRequestBase. # noqa: E501 - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :return: The start_on of this GoalRequestBase. # noqa: E501 - :rtype: str - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this GoalRequestBase. - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :param start_on: The start_on of this GoalRequestBase. # noqa: E501 - :type: str - """ - - self._start_on = start_on - - @property - def is_workspace_level(self): - """Gets the is_workspace_level of this GoalRequestBase. # noqa: E501 - - *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. # noqa: E501 - - :return: The is_workspace_level of this GoalRequestBase. # noqa: E501 - :rtype: bool - """ - return self._is_workspace_level - - @is_workspace_level.setter - def is_workspace_level(self, is_workspace_level): - """Sets the is_workspace_level of this GoalRequestBase. - - *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. # noqa: E501 - - :param is_workspace_level: The is_workspace_level of this GoalRequestBase. # noqa: E501 - :type: bool - """ - - self._is_workspace_level = is_workspace_level - - @property - def liked(self): - """Gets the liked of this GoalRequestBase. # noqa: E501 - - True if the goal is liked by the authorized user, false if not. # noqa: E501 - - :return: The liked of this GoalRequestBase. # noqa: E501 - :rtype: bool - """ - return self._liked - - @liked.setter - def liked(self, liked): - """Sets the liked of this GoalRequestBase. - - True if the goal is liked by the authorized user, false if not. # noqa: E501 - - :param liked: The liked of this GoalRequestBase. # noqa: E501 - :type: bool - """ - - self._liked = liked - - @property - def team(self): - """Gets the team of this GoalRequestBase. # noqa: E501 - - *Conditional*. This property is only present when the `workspace` provided is an organization. # noqa: E501 - - :return: The team of this GoalRequestBase. # noqa: E501 - :rtype: str - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this GoalRequestBase. - - *Conditional*. This property is only present when the `workspace` provided is an organization. # noqa: E501 - - :param team: The team of this GoalRequestBase. # noqa: E501 - :type: str - """ - - self._team = team - - @property - def workspace(self): - """Gets the workspace of this GoalRequestBase. # noqa: E501 - - The `gid` of a workspace. # noqa: E501 - - :return: The workspace of this GoalRequestBase. # noqa: E501 - :rtype: str - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this GoalRequestBase. - - The `gid` of a workspace. # noqa: E501 - - :param workspace: The workspace of this GoalRequestBase. # noqa: E501 - :type: str - """ - - self._workspace = workspace - - @property - def time_period(self): - """Gets the time_period of this GoalRequestBase. # noqa: E501 - - The `gid` of a time period. # noqa: E501 - - :return: The time_period of this GoalRequestBase. # noqa: E501 - :rtype: str - """ - return self._time_period - - @time_period.setter - def time_period(self, time_period): - """Sets the time_period of this GoalRequestBase. - - The `gid` of a time period. # noqa: E501 - - :param time_period: The time_period of this GoalRequestBase. # noqa: E501 - :type: str - """ - - self._time_period = time_period - - @property - def owner(self): - """Gets the owner of this GoalRequestBase. # noqa: E501 - - The `gid` of a user. # noqa: E501 - - :return: The owner of this GoalRequestBase. # noqa: E501 - :rtype: str - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this GoalRequestBase. - - The `gid` of a user. # noqa: E501 - - :param owner: The owner of this GoalRequestBase. # noqa: E501 - :type: str - """ - - self._owner = owner - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalRequestBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalRequestBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_response.py b/asana/models/goal_response.py deleted file mode 100644 index a6d5577b..00000000 --- a/asana/models/goal_response.py +++ /dev/null @@ -1,604 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'html_notes': 'str', - 'notes': 'str', - 'due_on': 'str', - 'start_on': 'str', - 'is_workspace_level': 'bool', - 'liked': 'bool', - 'likes': 'list[GoalResponseLikes]', - 'num_likes': 'int', - 'team': 'GoalResponseTeam', - 'workspace': 'GoalResponseWorkspace', - 'followers': 'list[CustomFieldResponsePeopleValue]', - 'time_period': 'GoalResponseTimePeriod', - 'metric': 'GoalResponseMetric', - 'owner': 'CustomFieldResponseCreatedBy', - 'current_status_update': 'GoalResponseCurrentStatusUpdate', - 'status': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'html_notes': 'html_notes', - 'notes': 'notes', - 'due_on': 'due_on', - 'start_on': 'start_on', - 'is_workspace_level': 'is_workspace_level', - 'liked': 'liked', - 'likes': 'likes', - 'num_likes': 'num_likes', - 'team': 'team', - 'workspace': 'workspace', - 'followers': 'followers', - 'time_period': 'time_period', - 'metric': 'metric', - 'owner': 'owner', - 'current_status_update': 'current_status_update', - 'status': 'status' - } - - def __init__(self, gid=None, resource_type=None, name=None, html_notes=None, notes=None, due_on=None, start_on=None, is_workspace_level=None, liked=None, likes=None, num_likes=None, team=None, workspace=None, followers=None, time_period=None, metric=None, owner=None, current_status_update=None, status=None): # noqa: E501 - """GoalResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._html_notes = None - self._notes = None - self._due_on = None - self._start_on = None - self._is_workspace_level = None - self._liked = None - self._likes = None - self._num_likes = None - self._team = None - self._workspace = None - self._followers = None - self._time_period = None - self._metric = None - self._owner = None - self._current_status_update = None - self._status = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if html_notes is not None: - self.html_notes = html_notes - if notes is not None: - self.notes = notes - if due_on is not None: - self.due_on = due_on - if start_on is not None: - self.start_on = start_on - if is_workspace_level is not None: - self.is_workspace_level = is_workspace_level - if liked is not None: - self.liked = liked - if likes is not None: - self.likes = likes - if num_likes is not None: - self.num_likes = num_likes - if team is not None: - self.team = team - if workspace is not None: - self.workspace = workspace - if followers is not None: - self.followers = followers - if time_period is not None: - self.time_period = time_period - if metric is not None: - self.metric = metric - if owner is not None: - self.owner = owner - if current_status_update is not None: - self.current_status_update = current_status_update - if status is not None: - self.status = status - - @property - def gid(self): - """Gets the gid of this GoalResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this GoalResponse. # noqa: E501 - - The name of the goal. # noqa: E501 - - :return: The name of this GoalResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this GoalResponse. - - The name of the goal. # noqa: E501 - - :param name: The name of this GoalResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def html_notes(self): - """Gets the html_notes of this GoalResponse. # noqa: E501 - - The notes of the goal with formatting as HTML. # noqa: E501 - - :return: The html_notes of this GoalResponse. # noqa: E501 - :rtype: str - """ - return self._html_notes - - @html_notes.setter - def html_notes(self, html_notes): - """Sets the html_notes of this GoalResponse. - - The notes of the goal with formatting as HTML. # noqa: E501 - - :param html_notes: The html_notes of this GoalResponse. # noqa: E501 - :type: str - """ - - self._html_notes = html_notes - - @property - def notes(self): - """Gets the notes of this GoalResponse. # noqa: E501 - - Free-form textual information associated with the goal (i.e. its description). # noqa: E501 - - :return: The notes of this GoalResponse. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this GoalResponse. - - Free-form textual information associated with the goal (i.e. its description). # noqa: E501 - - :param notes: The notes of this GoalResponse. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def due_on(self): - """Gets the due_on of this GoalResponse. # noqa: E501 - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :return: The due_on of this GoalResponse. # noqa: E501 - :rtype: str - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this GoalResponse. - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :param due_on: The due_on of this GoalResponse. # noqa: E501 - :type: str - """ - - self._due_on = due_on - - @property - def start_on(self): - """Gets the start_on of this GoalResponse. # noqa: E501 - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :return: The start_on of this GoalResponse. # noqa: E501 - :rtype: str - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this GoalResponse. - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :param start_on: The start_on of this GoalResponse. # noqa: E501 - :type: str - """ - - self._start_on = start_on - - @property - def is_workspace_level(self): - """Gets the is_workspace_level of this GoalResponse. # noqa: E501 - - *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. # noqa: E501 - - :return: The is_workspace_level of this GoalResponse. # noqa: E501 - :rtype: bool - """ - return self._is_workspace_level - - @is_workspace_level.setter - def is_workspace_level(self, is_workspace_level): - """Sets the is_workspace_level of this GoalResponse. - - *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. # noqa: E501 - - :param is_workspace_level: The is_workspace_level of this GoalResponse. # noqa: E501 - :type: bool - """ - - self._is_workspace_level = is_workspace_level - - @property - def liked(self): - """Gets the liked of this GoalResponse. # noqa: E501 - - True if the goal is liked by the authorized user, false if not. # noqa: E501 - - :return: The liked of this GoalResponse. # noqa: E501 - :rtype: bool - """ - return self._liked - - @liked.setter - def liked(self, liked): - """Sets the liked of this GoalResponse. - - True if the goal is liked by the authorized user, false if not. # noqa: E501 - - :param liked: The liked of this GoalResponse. # noqa: E501 - :type: bool - """ - - self._liked = liked - - @property - def likes(self): - """Gets the likes of this GoalResponse. # noqa: E501 - - Array of likes for users who have liked this goal. # noqa: E501 - - :return: The likes of this GoalResponse. # noqa: E501 - :rtype: list[GoalResponseLikes] - """ - return self._likes - - @likes.setter - def likes(self, likes): - """Sets the likes of this GoalResponse. - - Array of likes for users who have liked this goal. # noqa: E501 - - :param likes: The likes of this GoalResponse. # noqa: E501 - :type: list[GoalResponseLikes] - """ - - self._likes = likes - - @property - def num_likes(self): - """Gets the num_likes of this GoalResponse. # noqa: E501 - - The number of users who have liked this goal. # noqa: E501 - - :return: The num_likes of this GoalResponse. # noqa: E501 - :rtype: int - """ - return self._num_likes - - @num_likes.setter - def num_likes(self, num_likes): - """Sets the num_likes of this GoalResponse. - - The number of users who have liked this goal. # noqa: E501 - - :param num_likes: The num_likes of this GoalResponse. # noqa: E501 - :type: int - """ - - self._num_likes = num_likes - - @property - def team(self): - """Gets the team of this GoalResponse. # noqa: E501 - - - :return: The team of this GoalResponse. # noqa: E501 - :rtype: GoalResponseTeam - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this GoalResponse. - - - :param team: The team of this GoalResponse. # noqa: E501 - :type: GoalResponseTeam - """ - - self._team = team - - @property - def workspace(self): - """Gets the workspace of this GoalResponse. # noqa: E501 - - - :return: The workspace of this GoalResponse. # noqa: E501 - :rtype: GoalResponseWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this GoalResponse. - - - :param workspace: The workspace of this GoalResponse. # noqa: E501 - :type: GoalResponseWorkspace - """ - - self._workspace = workspace - - @property - def followers(self): - """Gets the followers of this GoalResponse. # noqa: E501 - - Array of users who are members of this goal. # noqa: E501 - - :return: The followers of this GoalResponse. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this GoalResponse. - - Array of users who are members of this goal. # noqa: E501 - - :param followers: The followers of this GoalResponse. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._followers = followers - - @property - def time_period(self): - """Gets the time_period of this GoalResponse. # noqa: E501 - - - :return: The time_period of this GoalResponse. # noqa: E501 - :rtype: GoalResponseTimePeriod - """ - return self._time_period - - @time_period.setter - def time_period(self, time_period): - """Sets the time_period of this GoalResponse. - - - :param time_period: The time_period of this GoalResponse. # noqa: E501 - :type: GoalResponseTimePeriod - """ - - self._time_period = time_period - - @property - def metric(self): - """Gets the metric of this GoalResponse. # noqa: E501 - - - :return: The metric of this GoalResponse. # noqa: E501 - :rtype: GoalResponseMetric - """ - return self._metric - - @metric.setter - def metric(self, metric): - """Sets the metric of this GoalResponse. - - - :param metric: The metric of this GoalResponse. # noqa: E501 - :type: GoalResponseMetric - """ - - self._metric = metric - - @property - def owner(self): - """Gets the owner of this GoalResponse. # noqa: E501 - - - :return: The owner of this GoalResponse. # noqa: E501 - :rtype: CustomFieldResponseCreatedBy - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this GoalResponse. - - - :param owner: The owner of this GoalResponse. # noqa: E501 - :type: CustomFieldResponseCreatedBy - """ - - self._owner = owner - - @property - def current_status_update(self): - """Gets the current_status_update of this GoalResponse. # noqa: E501 - - - :return: The current_status_update of this GoalResponse. # noqa: E501 - :rtype: GoalResponseCurrentStatusUpdate - """ - return self._current_status_update - - @current_status_update.setter - def current_status_update(self, current_status_update): - """Sets the current_status_update of this GoalResponse. - - - :param current_status_update: The current_status_update of this GoalResponse. # noqa: E501 - :type: GoalResponseCurrentStatusUpdate - """ - - self._current_status_update = current_status_update - - @property - def status(self): - """Gets the status of this GoalResponse. # noqa: E501 - - The current status of this goal. When the goal is open, its status can be `green`, `yellow`, and `red` to reflect \"On Track\", \"At Risk\", and \"Off Track\", respectively. When the goal is closed, the value can be `missed`, `achieved`, `partial`, or `dropped`. *Note* you can only write to this property if `metric` is set. # noqa: E501 - - :return: The status of this GoalResponse. # noqa: E501 - :rtype: str - """ - return self._status - - @status.setter - def status(self, status): - """Sets the status of this GoalResponse. - - The current status of this goal. When the goal is open, its status can be `green`, `yellow`, and `red` to reflect \"On Track\", \"At Risk\", and \"Off Track\", respectively. When the goal is closed, the value can be `missed`, `achieved`, `partial`, or `dropped`. *Note* you can only write to this property if `metric` is set. # noqa: E501 - - :param status: The status of this GoalResponse. # noqa: E501 - :type: str - """ - - self._status = status - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_response_array.py b/asana/models/goal_response_array.py deleted file mode 100644 index 79dacce5..00000000 --- a/asana/models/goal_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[GoalResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """GoalResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this GoalResponseArray. # noqa: E501 - - - :return: The data of this GoalResponseArray. # noqa: E501 - :rtype: list[GoalResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this GoalResponseArray. - - - :param data: The data of this GoalResponseArray. # noqa: E501 - :type: list[GoalResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this GoalResponseArray. # noqa: E501 - - - :return: The next_page of this GoalResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this GoalResponseArray. - - - :param next_page: The next_page of this GoalResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_response_current_status_update.py b/asana/models/goal_response_current_status_update.py deleted file mode 100644 index f10158d9..00000000 --- a/asana/models/goal_response_current_status_update.py +++ /dev/null @@ -1,202 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalResponseCurrentStatusUpdate(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'resource_subtype': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'resource_subtype': 'resource_subtype' - } - - def __init__(self, gid=None, resource_type=None, title=None, resource_subtype=None): # noqa: E501 - """GoalResponseCurrentStatusUpdate - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._resource_subtype = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if resource_subtype is not None: - self.resource_subtype = resource_subtype - - @property - def gid(self): - """Gets the gid of this GoalResponseCurrentStatusUpdate. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalResponseCurrentStatusUpdate. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalResponseCurrentStatusUpdate. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalResponseCurrentStatusUpdate. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalResponseCurrentStatusUpdate. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalResponseCurrentStatusUpdate. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalResponseCurrentStatusUpdate. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalResponseCurrentStatusUpdate. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this GoalResponseCurrentStatusUpdate. # noqa: E501 - - The title of the status update. # noqa: E501 - - :return: The title of this GoalResponseCurrentStatusUpdate. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this GoalResponseCurrentStatusUpdate. - - The title of the status update. # noqa: E501 - - :param title: The title of this GoalResponseCurrentStatusUpdate. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def resource_subtype(self): - """Gets the resource_subtype of this GoalResponseCurrentStatusUpdate. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :return: The resource_subtype of this GoalResponseCurrentStatusUpdate. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this GoalResponseCurrentStatusUpdate. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :param resource_subtype: The resource_subtype of this GoalResponseCurrentStatusUpdate. # noqa: E501 - :type: str - """ - allowed_values = ["project_status_update", "portfolio_status_update", "goal_status_update"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalResponseCurrentStatusUpdate, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalResponseCurrentStatusUpdate): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_response_data.py b/asana/models/goal_response_data.py deleted file mode 100644 index c1ff335a..00000000 --- a/asana/models/goal_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'GoalResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """GoalResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this GoalResponseData. # noqa: E501 - - - :return: The data of this GoalResponseData. # noqa: E501 - :rtype: GoalResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this GoalResponseData. - - - :param data: The data of this GoalResponseData. # noqa: E501 - :type: GoalResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_response_likes.py b/asana/models/goal_response_likes.py deleted file mode 100644 index 1339253d..00000000 --- a/asana/models/goal_response_likes.py +++ /dev/null @@ -1,138 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalResponseLikes(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'user': 'CustomFieldResponsePeopleValue' - } - - attribute_map = { - 'gid': 'gid', - 'user': 'user' - } - - def __init__(self, gid=None, user=None): # noqa: E501 - """GoalResponseLikes - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._user = None - self.discriminator = None - if gid is not None: - self.gid = gid - if user is not None: - self.user = user - - @property - def gid(self): - """Gets the gid of this GoalResponseLikes. # noqa: E501 - - Globally unique identifier of the object, as a string. # noqa: E501 - - :return: The gid of this GoalResponseLikes. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalResponseLikes. - - Globally unique identifier of the object, as a string. # noqa: E501 - - :param gid: The gid of this GoalResponseLikes. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def user(self): - """Gets the user of this GoalResponseLikes. # noqa: E501 - - - :return: The user of this GoalResponseLikes. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this GoalResponseLikes. - - - :param user: The user of this GoalResponseLikes. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalResponseLikes, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalResponseLikes): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_response_metric.py b/asana/models/goal_response_metric.py deleted file mode 100644 index 5c4de0ea..00000000 --- a/asana/models/goal_response_metric.py +++ /dev/null @@ -1,438 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalResponseMetric(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'resource_subtype': 'str', - 'precision': 'int', - 'unit': 'str', - 'currency_code': 'str', - 'initial_number_value': 'float', - 'target_number_value': 'float', - 'current_number_value': 'float', - 'current_display_value': 'str', - 'progress_source': 'str', - 'can_manage': 'bool' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'precision': 'precision', - 'unit': 'unit', - 'currency_code': 'currency_code', - 'initial_number_value': 'initial_number_value', - 'target_number_value': 'target_number_value', - 'current_number_value': 'current_number_value', - 'current_display_value': 'current_display_value', - 'progress_source': 'progress_source', - 'can_manage': 'can_manage' - } - - def __init__(self, gid=None, resource_type=None, resource_subtype=None, precision=None, unit=None, currency_code=None, initial_number_value=None, target_number_value=None, current_number_value=None, current_display_value=None, progress_source=None, can_manage=None): # noqa: E501 - """GoalResponseMetric - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._resource_subtype = None - self._precision = None - self._unit = None - self._currency_code = None - self._initial_number_value = None - self._target_number_value = None - self._current_number_value = None - self._current_display_value = None - self._progress_source = None - self._can_manage = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if precision is not None: - self.precision = precision - if unit is not None: - self.unit = unit - if currency_code is not None: - self.currency_code = currency_code - if initial_number_value is not None: - self.initial_number_value = initial_number_value - if target_number_value is not None: - self.target_number_value = target_number_value - if current_number_value is not None: - self.current_number_value = current_number_value - if current_display_value is not None: - self.current_display_value = current_display_value - if progress_source is not None: - self.progress_source = progress_source - if can_manage is not None: - self.can_manage = can_manage - - @property - def gid(self): - """Gets the gid of this GoalResponseMetric. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalResponseMetric. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalResponseMetric. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalResponseMetric. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalResponseMetric. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalResponseMetric. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalResponseMetric. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalResponseMetric. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this GoalResponseMetric. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this GoalResponseMetric. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this GoalResponseMetric. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this GoalResponseMetric. # noqa: E501 - :type: str - """ - allowed_values = ["number"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def precision(self): - """Gets the precision of this GoalResponseMetric. # noqa: E501 - - *Conditional*. Only relevant for goal metrics of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. # noqa: E501 - - :return: The precision of this GoalResponseMetric. # noqa: E501 - :rtype: int - """ - return self._precision - - @precision.setter - def precision(self, precision): - """Sets the precision of this GoalResponseMetric. - - *Conditional*. Only relevant for goal metrics of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. # noqa: E501 - - :param precision: The precision of this GoalResponseMetric. # noqa: E501 - :type: int - """ - - self._precision = precision - - @property - def unit(self): - """Gets the unit of this GoalResponseMetric. # noqa: E501 - - A supported unit of measure for the goal metric, or none. # noqa: E501 - - :return: The unit of this GoalResponseMetric. # noqa: E501 - :rtype: str - """ - return self._unit - - @unit.setter - def unit(self, unit): - """Sets the unit of this GoalResponseMetric. - - A supported unit of measure for the goal metric, or none. # noqa: E501 - - :param unit: The unit of this GoalResponseMetric. # noqa: E501 - :type: str - """ - allowed_values = ["none", "currency", "percentage"] # noqa: E501 - if unit not in allowed_values: - raise ValueError( - "Invalid value for `unit` ({0}), must be one of {1}" # noqa: E501 - .format(unit, allowed_values) - ) - - self._unit = unit - - @property - def currency_code(self): - """Gets the currency_code of this GoalResponseMetric. # noqa: E501 - - ISO 4217 currency code to format this custom field. This will be null if the `unit` is not `currency`. # noqa: E501 - - :return: The currency_code of this GoalResponseMetric. # noqa: E501 - :rtype: str - """ - return self._currency_code - - @currency_code.setter - def currency_code(self, currency_code): - """Sets the currency_code of this GoalResponseMetric. - - ISO 4217 currency code to format this custom field. This will be null if the `unit` is not `currency`. # noqa: E501 - - :param currency_code: The currency_code of this GoalResponseMetric. # noqa: E501 - :type: str - """ - - self._currency_code = currency_code - - @property - def initial_number_value(self): - """Gets the initial_number_value of this GoalResponseMetric. # noqa: E501 - - This number is the start value of a goal metric of type number. # noqa: E501 - - :return: The initial_number_value of this GoalResponseMetric. # noqa: E501 - :rtype: float - """ - return self._initial_number_value - - @initial_number_value.setter - def initial_number_value(self, initial_number_value): - """Sets the initial_number_value of this GoalResponseMetric. - - This number is the start value of a goal metric of type number. # noqa: E501 - - :param initial_number_value: The initial_number_value of this GoalResponseMetric. # noqa: E501 - :type: float - """ - - self._initial_number_value = initial_number_value - - @property - def target_number_value(self): - """Gets the target_number_value of this GoalResponseMetric. # noqa: E501 - - This number is the end value of a goal metric of type number. This number cannot equal `initial_number_value`. # noqa: E501 - - :return: The target_number_value of this GoalResponseMetric. # noqa: E501 - :rtype: float - """ - return self._target_number_value - - @target_number_value.setter - def target_number_value(self, target_number_value): - """Sets the target_number_value of this GoalResponseMetric. - - This number is the end value of a goal metric of type number. This number cannot equal `initial_number_value`. # noqa: E501 - - :param target_number_value: The target_number_value of this GoalResponseMetric. # noqa: E501 - :type: float - """ - - self._target_number_value = target_number_value - - @property - def current_number_value(self): - """Gets the current_number_value of this GoalResponseMetric. # noqa: E501 - - This number is the current value of a goal metric of type number. # noqa: E501 - - :return: The current_number_value of this GoalResponseMetric. # noqa: E501 - :rtype: float - """ - return self._current_number_value - - @current_number_value.setter - def current_number_value(self, current_number_value): - """Sets the current_number_value of this GoalResponseMetric. - - This number is the current value of a goal metric of type number. # noqa: E501 - - :param current_number_value: The current_number_value of this GoalResponseMetric. # noqa: E501 - :type: float - """ - - self._current_number_value = current_number_value - - @property - def current_display_value(self): - """Gets the current_display_value of this GoalResponseMetric. # noqa: E501 - - This string is the current value of a goal metric of type string. # noqa: E501 - - :return: The current_display_value of this GoalResponseMetric. # noqa: E501 - :rtype: str - """ - return self._current_display_value - - @current_display_value.setter - def current_display_value(self, current_display_value): - """Sets the current_display_value of this GoalResponseMetric. - - This string is the current value of a goal metric of type string. # noqa: E501 - - :param current_display_value: The current_display_value of this GoalResponseMetric. # noqa: E501 - :type: str - """ - - self._current_display_value = current_display_value - - @property - def progress_source(self): - """Gets the progress_source of this GoalResponseMetric. # noqa: E501 - - This field defines how the progress value of a goal metric is being calculated. A goal's progress can be provided manually by the user, calculated automatically from contributing subgoals or projects, or managed by an integration with an external data source, such as Salesforce. # noqa: E501 - - :return: The progress_source of this GoalResponseMetric. # noqa: E501 - :rtype: str - """ - return self._progress_source - - @progress_source.setter - def progress_source(self, progress_source): - """Sets the progress_source of this GoalResponseMetric. - - This field defines how the progress value of a goal metric is being calculated. A goal's progress can be provided manually by the user, calculated automatically from contributing subgoals or projects, or managed by an integration with an external data source, such as Salesforce. # noqa: E501 - - :param progress_source: The progress_source of this GoalResponseMetric. # noqa: E501 - :type: str - """ - allowed_values = ["manual", "subgoal_progress", "project_task_completion", "project_milestone_completion", "external"] # noqa: E501 - if progress_source not in allowed_values: - raise ValueError( - "Invalid value for `progress_source` ({0}), must be one of {1}" # noqa: E501 - .format(progress_source, allowed_values) - ) - - self._progress_source = progress_source - - @property - def can_manage(self): - """Gets the can_manage of this GoalResponseMetric. # noqa: E501 - - *Conditional*. Only relevant for `progress_source` of type `external`. This boolean indicates whether the requester has the ability to update the current value of this metric. This returns `true` if the external metric was created by the requester, `false` otherwise. # noqa: E501 - - :return: The can_manage of this GoalResponseMetric. # noqa: E501 - :rtype: bool - """ - return self._can_manage - - @can_manage.setter - def can_manage(self, can_manage): - """Sets the can_manage of this GoalResponseMetric. - - *Conditional*. Only relevant for `progress_source` of type `external`. This boolean indicates whether the requester has the ability to update the current value of this metric. This returns `true` if the external metric was created by the requester, `false` otherwise. # noqa: E501 - - :param can_manage: The can_manage of this GoalResponseMetric. # noqa: E501 - :type: bool - """ - - self._can_manage = can_manage - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalResponseMetric, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalResponseMetric): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_response_team.py b/asana/models/goal_response_team.py deleted file mode 100644 index da5cae8f..00000000 --- a/asana/models/goal_response_team.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalResponseTeam(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """GoalResponseTeam - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this GoalResponseTeam. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalResponseTeam. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalResponseTeam. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalResponseTeam. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalResponseTeam. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalResponseTeam. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalResponseTeam. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalResponseTeam. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this GoalResponseTeam. # noqa: E501 - - The name of the team. # noqa: E501 - - :return: The name of this GoalResponseTeam. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this GoalResponseTeam. - - The name of the team. # noqa: E501 - - :param name: The name of this GoalResponseTeam. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalResponseTeam, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalResponseTeam): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_response_time_period.py b/asana/models/goal_response_time_period.py deleted file mode 100644 index 9aec77ab..00000000 --- a/asana/models/goal_response_time_period.py +++ /dev/null @@ -1,258 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalResponseTimePeriod(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'end_on': 'str', - 'start_on': 'str', - 'period': 'str', - 'display_name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'end_on': 'end_on', - 'start_on': 'start_on', - 'period': 'period', - 'display_name': 'display_name' - } - - def __init__(self, gid=None, resource_type=None, end_on=None, start_on=None, period=None, display_name=None): # noqa: E501 - """GoalResponseTimePeriod - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._end_on = None - self._start_on = None - self._period = None - self._display_name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if end_on is not None: - self.end_on = end_on - if start_on is not None: - self.start_on = start_on - if period is not None: - self.period = period - if display_name is not None: - self.display_name = display_name - - @property - def gid(self): - """Gets the gid of this GoalResponseTimePeriod. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalResponseTimePeriod. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalResponseTimePeriod. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalResponseTimePeriod. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalResponseTimePeriod. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalResponseTimePeriod. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalResponseTimePeriod. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalResponseTimePeriod. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def end_on(self): - """Gets the end_on of this GoalResponseTimePeriod. # noqa: E501 - - The localized end date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :return: The end_on of this GoalResponseTimePeriod. # noqa: E501 - :rtype: str - """ - return self._end_on - - @end_on.setter - def end_on(self, end_on): - """Sets the end_on of this GoalResponseTimePeriod. - - The localized end date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :param end_on: The end_on of this GoalResponseTimePeriod. # noqa: E501 - :type: str - """ - - self._end_on = end_on - - @property - def start_on(self): - """Gets the start_on of this GoalResponseTimePeriod. # noqa: E501 - - The localized start date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :return: The start_on of this GoalResponseTimePeriod. # noqa: E501 - :rtype: str - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this GoalResponseTimePeriod. - - The localized start date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :param start_on: The start_on of this GoalResponseTimePeriod. # noqa: E501 - :type: str - """ - - self._start_on = start_on - - @property - def period(self): - """Gets the period of this GoalResponseTimePeriod. # noqa: E501 - - The cadence and index of the time period. The value is one of: `FY`, `H1`, `H2`, `Q1`, `Q2`, `Q3`, or `Q4`. # noqa: E501 - - :return: The period of this GoalResponseTimePeriod. # noqa: E501 - :rtype: str - """ - return self._period - - @period.setter - def period(self, period): - """Sets the period of this GoalResponseTimePeriod. - - The cadence and index of the time period. The value is one of: `FY`, `H1`, `H2`, `Q1`, `Q2`, `Q3`, or `Q4`. # noqa: E501 - - :param period: The period of this GoalResponseTimePeriod. # noqa: E501 - :type: str - """ - allowed_values = ["FY", "H1", "H2", "Q1", "Q2", "Q3", "Q4"] # noqa: E501 - if period not in allowed_values: - raise ValueError( - "Invalid value for `period` ({0}), must be one of {1}" # noqa: E501 - .format(period, allowed_values) - ) - - self._period = period - - @property - def display_name(self): - """Gets the display_name of this GoalResponseTimePeriod. # noqa: E501 - - A string representing the cadence code and the fiscal year. # noqa: E501 - - :return: The display_name of this GoalResponseTimePeriod. # noqa: E501 - :rtype: str - """ - return self._display_name - - @display_name.setter - def display_name(self, display_name): - """Sets the display_name of this GoalResponseTimePeriod. - - A string representing the cadence code and the fiscal year. # noqa: E501 - - :param display_name: The display_name of this GoalResponseTimePeriod. # noqa: E501 - :type: str - """ - - self._display_name = display_name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalResponseTimePeriod, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalResponseTimePeriod): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_response_workspace.py b/asana/models/goal_response_workspace.py deleted file mode 100644 index 540a0ebd..00000000 --- a/asana/models/goal_response_workspace.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalResponseWorkspace(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """GoalResponseWorkspace - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this GoalResponseWorkspace. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalResponseWorkspace. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalResponseWorkspace. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalResponseWorkspace. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalResponseWorkspace. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalResponseWorkspace. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this GoalResponseWorkspace. # noqa: E501 - - The name of the workspace. # noqa: E501 - - :return: The name of this GoalResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this GoalResponseWorkspace. - - The name of the workspace. # noqa: E501 - - :param name: The name of this GoalResponseWorkspace. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalResponseWorkspace, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalResponseWorkspace): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goal_update_request.py b/asana/models/goal_update_request.py deleted file mode 100644 index 483f0509..00000000 --- a/asana/models/goal_update_request.py +++ /dev/null @@ -1,476 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalUpdateRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'html_notes': 'str', - 'notes': 'str', - 'due_on': 'str', - 'start_on': 'str', - 'is_workspace_level': 'bool', - 'liked': 'bool', - 'team': 'str', - 'workspace': 'str', - 'time_period': 'str', - 'owner': 'str', - 'status': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'html_notes': 'html_notes', - 'notes': 'notes', - 'due_on': 'due_on', - 'start_on': 'start_on', - 'is_workspace_level': 'is_workspace_level', - 'liked': 'liked', - 'team': 'team', - 'workspace': 'workspace', - 'time_period': 'time_period', - 'owner': 'owner', - 'status': 'status' - } - - def __init__(self, gid=None, resource_type=None, name=None, html_notes=None, notes=None, due_on=None, start_on=None, is_workspace_level=None, liked=None, team=None, workspace=None, time_period=None, owner=None, status=None): # noqa: E501 - """GoalUpdateRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._html_notes = None - self._notes = None - self._due_on = None - self._start_on = None - self._is_workspace_level = None - self._liked = None - self._team = None - self._workspace = None - self._time_period = None - self._owner = None - self._status = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if html_notes is not None: - self.html_notes = html_notes - if notes is not None: - self.notes = notes - if due_on is not None: - self.due_on = due_on - if start_on is not None: - self.start_on = start_on - if is_workspace_level is not None: - self.is_workspace_level = is_workspace_level - if liked is not None: - self.liked = liked - if team is not None: - self.team = team - if workspace is not None: - self.workspace = workspace - if time_period is not None: - self.time_period = time_period - if owner is not None: - self.owner = owner - if status is not None: - self.status = status - - @property - def gid(self): - """Gets the gid of this GoalUpdateRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this GoalUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this GoalUpdateRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this GoalUpdateRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this GoalUpdateRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this GoalUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this GoalUpdateRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this GoalUpdateRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this GoalUpdateRequest. # noqa: E501 - - The name of the goal. # noqa: E501 - - :return: The name of this GoalUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this GoalUpdateRequest. - - The name of the goal. # noqa: E501 - - :param name: The name of this GoalUpdateRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def html_notes(self): - """Gets the html_notes of this GoalUpdateRequest. # noqa: E501 - - The notes of the goal with formatting as HTML. # noqa: E501 - - :return: The html_notes of this GoalUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._html_notes - - @html_notes.setter - def html_notes(self, html_notes): - """Sets the html_notes of this GoalUpdateRequest. - - The notes of the goal with formatting as HTML. # noqa: E501 - - :param html_notes: The html_notes of this GoalUpdateRequest. # noqa: E501 - :type: str - """ - - self._html_notes = html_notes - - @property - def notes(self): - """Gets the notes of this GoalUpdateRequest. # noqa: E501 - - Free-form textual information associated with the goal (i.e. its description). # noqa: E501 - - :return: The notes of this GoalUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this GoalUpdateRequest. - - Free-form textual information associated with the goal (i.e. its description). # noqa: E501 - - :param notes: The notes of this GoalUpdateRequest. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def due_on(self): - """Gets the due_on of this GoalUpdateRequest. # noqa: E501 - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :return: The due_on of this GoalUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this GoalUpdateRequest. - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :param due_on: The due_on of this GoalUpdateRequest. # noqa: E501 - :type: str - """ - - self._due_on = due_on - - @property - def start_on(self): - """Gets the start_on of this GoalUpdateRequest. # noqa: E501 - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :return: The start_on of this GoalUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this GoalUpdateRequest. - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :param start_on: The start_on of this GoalUpdateRequest. # noqa: E501 - :type: str - """ - - self._start_on = start_on - - @property - def is_workspace_level(self): - """Gets the is_workspace_level of this GoalUpdateRequest. # noqa: E501 - - *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. # noqa: E501 - - :return: The is_workspace_level of this GoalUpdateRequest. # noqa: E501 - :rtype: bool - """ - return self._is_workspace_level - - @is_workspace_level.setter - def is_workspace_level(self, is_workspace_level): - """Sets the is_workspace_level of this GoalUpdateRequest. - - *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. # noqa: E501 - - :param is_workspace_level: The is_workspace_level of this GoalUpdateRequest. # noqa: E501 - :type: bool - """ - - self._is_workspace_level = is_workspace_level - - @property - def liked(self): - """Gets the liked of this GoalUpdateRequest. # noqa: E501 - - True if the goal is liked by the authorized user, false if not. # noqa: E501 - - :return: The liked of this GoalUpdateRequest. # noqa: E501 - :rtype: bool - """ - return self._liked - - @liked.setter - def liked(self, liked): - """Sets the liked of this GoalUpdateRequest. - - True if the goal is liked by the authorized user, false if not. # noqa: E501 - - :param liked: The liked of this GoalUpdateRequest. # noqa: E501 - :type: bool - """ - - self._liked = liked - - @property - def team(self): - """Gets the team of this GoalUpdateRequest. # noqa: E501 - - *Conditional*. This property is only present when the `workspace` provided is an organization. # noqa: E501 - - :return: The team of this GoalUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this GoalUpdateRequest. - - *Conditional*. This property is only present when the `workspace` provided is an organization. # noqa: E501 - - :param team: The team of this GoalUpdateRequest. # noqa: E501 - :type: str - """ - - self._team = team - - @property - def workspace(self): - """Gets the workspace of this GoalUpdateRequest. # noqa: E501 - - The `gid` of a workspace. # noqa: E501 - - :return: The workspace of this GoalUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this GoalUpdateRequest. - - The `gid` of a workspace. # noqa: E501 - - :param workspace: The workspace of this GoalUpdateRequest. # noqa: E501 - :type: str - """ - - self._workspace = workspace - - @property - def time_period(self): - """Gets the time_period of this GoalUpdateRequest. # noqa: E501 - - The `gid` of a time period. # noqa: E501 - - :return: The time_period of this GoalUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._time_period - - @time_period.setter - def time_period(self, time_period): - """Sets the time_period of this GoalUpdateRequest. - - The `gid` of a time period. # noqa: E501 - - :param time_period: The time_period of this GoalUpdateRequest. # noqa: E501 - :type: str - """ - - self._time_period = time_period - - @property - def owner(self): - """Gets the owner of this GoalUpdateRequest. # noqa: E501 - - The `gid` of a user. # noqa: E501 - - :return: The owner of this GoalUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this GoalUpdateRequest. - - The `gid` of a user. # noqa: E501 - - :param owner: The owner of this GoalUpdateRequest. # noqa: E501 - :type: str - """ - - self._owner = owner - - @property - def status(self): - """Gets the status of this GoalUpdateRequest. # noqa: E501 - - The current status of this goal. When the goal is open, its status can be `green`, `yellow`, and `red` to reflect \"On Track\", \"At Risk\", and \"Off Track\", respectively. When the goal is closed, the value can be `missed`, `achieved`, `partial`, or `dropped`. *Note* you can only write to this property if `metric` is set. # noqa: E501 - - :return: The status of this GoalUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._status - - @status.setter - def status(self, status): - """Sets the status of this GoalUpdateRequest. - - The current status of this goal. When the goal is open, its status can be `green`, `yellow`, and `red` to reflect \"On Track\", \"At Risk\", and \"Off Track\", respectively. When the goal is closed, the value can be `missed`, `achieved`, `partial`, or `dropped`. *Note* you can only write to this property if `metric` is set. # noqa: E501 - - :param status: The status of this GoalUpdateRequest. # noqa: E501 - :type: str - """ - - self._status = status - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalUpdateRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalUpdateRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goals_body.py b/asana/models/goals_body.py deleted file mode 100644 index 8c372927..00000000 --- a/asana/models/goals_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'GoalRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """GoalsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this GoalsBody. # noqa: E501 - - - :return: The data of this GoalsBody. # noqa: E501 - :rtype: GoalRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this GoalsBody. - - - :param data: The data of this GoalsBody. # noqa: E501 - :type: GoalRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/goals_goal_gid_body.py b/asana/models/goals_goal_gid_body.py deleted file mode 100644 index 03b1d7a7..00000000 --- a/asana/models/goals_goal_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class GoalsGoalGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'GoalUpdateRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """GoalsGoalGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this GoalsGoalGidBody. # noqa: E501 - - - :return: The data of this GoalsGoalGidBody. # noqa: E501 - :rtype: GoalUpdateRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this GoalsGoalGidBody. - - - :param data: The data of this GoalsGoalGidBody. # noqa: E501 - :type: GoalUpdateRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(GoalsGoalGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, GoalsGoalGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/inline_response412.py b/asana/models/inline_response412.py deleted file mode 100644 index 62b9746d..00000000 --- a/asana/models/inline_response412.py +++ /dev/null @@ -1,138 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class InlineResponse412(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'errors': 'list[InlineResponse412Errors]', - 'sync': 'str' - } - - attribute_map = { - 'errors': 'errors', - 'sync': 'sync' - } - - def __init__(self, errors=None, sync=None): # noqa: E501 - """InlineResponse412 - a model defined in Swagger""" # noqa: E501 - self._errors = None - self._sync = None - self.discriminator = None - if errors is not None: - self.errors = errors - if sync is not None: - self.sync = sync - - @property - def errors(self): - """Gets the errors of this InlineResponse412. # noqa: E501 - - - :return: The errors of this InlineResponse412. # noqa: E501 - :rtype: list[InlineResponse412Errors] - """ - return self._errors - - @errors.setter - def errors(self, errors): - """Sets the errors of this InlineResponse412. - - - :param errors: The errors of this InlineResponse412. # noqa: E501 - :type: list[InlineResponse412Errors] - """ - - self._errors = errors - - @property - def sync(self): - """Gets the sync of this InlineResponse412. # noqa: E501 - - A sync token to be used with the next call to the /events endpoint. # noqa: E501 - - :return: The sync of this InlineResponse412. # noqa: E501 - :rtype: str - """ - return self._sync - - @sync.setter - def sync(self, sync): - """Sets the sync of this InlineResponse412. - - A sync token to be used with the next call to the /events endpoint. # noqa: E501 - - :param sync: The sync of this InlineResponse412. # noqa: E501 - :type: str - """ - - self._sync = sync - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(InlineResponse412, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, InlineResponse412): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/inline_response412_errors.py b/asana/models/inline_response412_errors.py deleted file mode 100644 index 6d822a04..00000000 --- a/asana/models/inline_response412_errors.py +++ /dev/null @@ -1,112 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class InlineResponse412Errors(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'message': 'str' - } - - attribute_map = { - 'message': 'message' - } - - def __init__(self, message=None): # noqa: E501 - """InlineResponse412Errors - a model defined in Swagger""" # noqa: E501 - self._message = None - self.discriminator = None - if message is not None: - self.message = message - - @property - def message(self): - """Gets the message of this InlineResponse412Errors. # noqa: E501 - - Message providing more detail about the error that occurred, if available. # noqa: E501 - - :return: The message of this InlineResponse412Errors. # noqa: E501 - :rtype: str - """ - return self._message - - @message.setter - def message(self, message): - """Sets the message of this InlineResponse412Errors. - - Message providing more detail about the error that occurred, if available. # noqa: E501 - - :param message: The message of this InlineResponse412Errors. # noqa: E501 - :type: str - """ - - self._message = message - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(InlineResponse412Errors, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, InlineResponse412Errors): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/job_base.py b/asana/models/job_base.py deleted file mode 100644 index f1fc89fc..00000000 --- a/asana/models/job_base.py +++ /dev/null @@ -1,280 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class JobBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'resource_subtype': 'str', - 'status': 'str', - 'new_project': 'JobBaseNewProject', - 'new_task': 'JobBaseNewTask', - 'new_project_template': 'JobBaseNewProjectTemplate' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'status': 'status', - 'new_project': 'new_project', - 'new_task': 'new_task', - 'new_project_template': 'new_project_template' - } - - def __init__(self, gid=None, resource_type=None, resource_subtype=None, status=None, new_project=None, new_task=None, new_project_template=None): # noqa: E501 - """JobBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._resource_subtype = None - self._status = None - self._new_project = None - self._new_task = None - self._new_project_template = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if status is not None: - self.status = status - if new_project is not None: - self.new_project = new_project - if new_task is not None: - self.new_task = new_task - if new_project_template is not None: - self.new_project_template = new_project_template - - @property - def gid(self): - """Gets the gid of this JobBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this JobBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this JobBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this JobBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this JobBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this JobBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this JobBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this JobBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this JobBase. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this JobBase. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this JobBase. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this JobBase. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def status(self): - """Gets the status of this JobBase. # noqa: E501 - - The current status of this job. The value is one of: `not_started`, `in_progress`, `succeeded`, or `failed`. # noqa: E501 - - :return: The status of this JobBase. # noqa: E501 - :rtype: str - """ - return self._status - - @status.setter - def status(self, status): - """Sets the status of this JobBase. - - The current status of this job. The value is one of: `not_started`, `in_progress`, `succeeded`, or `failed`. # noqa: E501 - - :param status: The status of this JobBase. # noqa: E501 - :type: str - """ - allowed_values = ["not_started", "in_progress", "succeeded", "failed"] # noqa: E501 - if status not in allowed_values: - raise ValueError( - "Invalid value for `status` ({0}), must be one of {1}" # noqa: E501 - .format(status, allowed_values) - ) - - self._status = status - - @property - def new_project(self): - """Gets the new_project of this JobBase. # noqa: E501 - - - :return: The new_project of this JobBase. # noqa: E501 - :rtype: JobBaseNewProject - """ - return self._new_project - - @new_project.setter - def new_project(self, new_project): - """Sets the new_project of this JobBase. - - - :param new_project: The new_project of this JobBase. # noqa: E501 - :type: JobBaseNewProject - """ - - self._new_project = new_project - - @property - def new_task(self): - """Gets the new_task of this JobBase. # noqa: E501 - - - :return: The new_task of this JobBase. # noqa: E501 - :rtype: JobBaseNewTask - """ - return self._new_task - - @new_task.setter - def new_task(self, new_task): - """Sets the new_task of this JobBase. - - - :param new_task: The new_task of this JobBase. # noqa: E501 - :type: JobBaseNewTask - """ - - self._new_task = new_task - - @property - def new_project_template(self): - """Gets the new_project_template of this JobBase. # noqa: E501 - - - :return: The new_project_template of this JobBase. # noqa: E501 - :rtype: JobBaseNewProjectTemplate - """ - return self._new_project_template - - @new_project_template.setter - def new_project_template(self, new_project_template): - """Sets the new_project_template of this JobBase. - - - :param new_project_template: The new_project_template of this JobBase. # noqa: E501 - :type: JobBaseNewProjectTemplate - """ - - self._new_project_template = new_project_template - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(JobBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, JobBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/job_base_new_project.py b/asana/models/job_base_new_project.py deleted file mode 100644 index 0e8bba48..00000000 --- a/asana/models/job_base_new_project.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class JobBaseNewProject(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """JobBaseNewProject - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this JobBaseNewProject. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this JobBaseNewProject. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this JobBaseNewProject. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this JobBaseNewProject. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this JobBaseNewProject. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this JobBaseNewProject. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this JobBaseNewProject. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this JobBaseNewProject. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this JobBaseNewProject. # noqa: E501 - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this JobBaseNewProject. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this JobBaseNewProject. - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this JobBaseNewProject. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(JobBaseNewProject, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, JobBaseNewProject): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/job_base_new_project_template.py b/asana/models/job_base_new_project_template.py deleted file mode 100644 index 822724f8..00000000 --- a/asana/models/job_base_new_project_template.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class JobBaseNewProjectTemplate(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """JobBaseNewProjectTemplate - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this JobBaseNewProjectTemplate. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this JobBaseNewProjectTemplate. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this JobBaseNewProjectTemplate. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this JobBaseNewProjectTemplate. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this JobBaseNewProjectTemplate. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this JobBaseNewProjectTemplate. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this JobBaseNewProjectTemplate. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this JobBaseNewProjectTemplate. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this JobBaseNewProjectTemplate. # noqa: E501 - - Name of the project template. # noqa: E501 - - :return: The name of this JobBaseNewProjectTemplate. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this JobBaseNewProjectTemplate. - - Name of the project template. # noqa: E501 - - :param name: The name of this JobBaseNewProjectTemplate. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(JobBaseNewProjectTemplate, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, JobBaseNewProjectTemplate): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/job_base_new_task.py b/asana/models/job_base_new_task.py deleted file mode 100644 index 29d8803d..00000000 --- a/asana/models/job_base_new_task.py +++ /dev/null @@ -1,228 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class JobBaseNewTask(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'created_by': 'AttachmentResponseParentCreatedBy' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'created_by': 'created_by' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, created_by=None): # noqa: E501 - """JobBaseNewTask - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._created_by = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if created_by is not None: - self.created_by = created_by - - @property - def gid(self): - """Gets the gid of this JobBaseNewTask. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this JobBaseNewTask. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this JobBaseNewTask. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this JobBaseNewTask. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this JobBaseNewTask. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this JobBaseNewTask. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this JobBaseNewTask. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this JobBaseNewTask. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this JobBaseNewTask. # noqa: E501 - - The name of the task. # noqa: E501 - - :return: The name of this JobBaseNewTask. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this JobBaseNewTask. - - The name of the task. # noqa: E501 - - :param name: The name of this JobBaseNewTask. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this JobBaseNewTask. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :return: The resource_subtype of this JobBaseNewTask. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this JobBaseNewTask. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :param resource_subtype: The resource_subtype of this JobBaseNewTask. # noqa: E501 - :type: str - """ - allowed_values = ["default_task", "milestone", "section", "approval"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def created_by(self): - """Gets the created_by of this JobBaseNewTask. # noqa: E501 - - - :return: The created_by of this JobBaseNewTask. # noqa: E501 - :rtype: AttachmentResponseParentCreatedBy - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this JobBaseNewTask. - - - :param created_by: The created_by of this JobBaseNewTask. # noqa: E501 - :type: AttachmentResponseParentCreatedBy - """ - - self._created_by = created_by - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(JobBaseNewTask, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, JobBaseNewTask): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/job_compact.py b/asana/models/job_compact.py deleted file mode 100644 index 35452de5..00000000 --- a/asana/models/job_compact.py +++ /dev/null @@ -1,280 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class JobCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'resource_subtype': 'str', - 'status': 'str', - 'new_project': 'JobBaseNewProject', - 'new_task': 'JobBaseNewTask', - 'new_project_template': 'JobBaseNewProjectTemplate' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'status': 'status', - 'new_project': 'new_project', - 'new_task': 'new_task', - 'new_project_template': 'new_project_template' - } - - def __init__(self, gid=None, resource_type=None, resource_subtype=None, status=None, new_project=None, new_task=None, new_project_template=None): # noqa: E501 - """JobCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._resource_subtype = None - self._status = None - self._new_project = None - self._new_task = None - self._new_project_template = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if status is not None: - self.status = status - if new_project is not None: - self.new_project = new_project - if new_task is not None: - self.new_task = new_task - if new_project_template is not None: - self.new_project_template = new_project_template - - @property - def gid(self): - """Gets the gid of this JobCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this JobCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this JobCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this JobCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this JobCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this JobCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this JobCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this JobCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this JobCompact. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this JobCompact. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this JobCompact. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this JobCompact. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def status(self): - """Gets the status of this JobCompact. # noqa: E501 - - The current status of this job. The value is one of: `not_started`, `in_progress`, `succeeded`, or `failed`. # noqa: E501 - - :return: The status of this JobCompact. # noqa: E501 - :rtype: str - """ - return self._status - - @status.setter - def status(self, status): - """Sets the status of this JobCompact. - - The current status of this job. The value is one of: `not_started`, `in_progress`, `succeeded`, or `failed`. # noqa: E501 - - :param status: The status of this JobCompact. # noqa: E501 - :type: str - """ - allowed_values = ["not_started", "in_progress", "succeeded", "failed"] # noqa: E501 - if status not in allowed_values: - raise ValueError( - "Invalid value for `status` ({0}), must be one of {1}" # noqa: E501 - .format(status, allowed_values) - ) - - self._status = status - - @property - def new_project(self): - """Gets the new_project of this JobCompact. # noqa: E501 - - - :return: The new_project of this JobCompact. # noqa: E501 - :rtype: JobBaseNewProject - """ - return self._new_project - - @new_project.setter - def new_project(self, new_project): - """Sets the new_project of this JobCompact. - - - :param new_project: The new_project of this JobCompact. # noqa: E501 - :type: JobBaseNewProject - """ - - self._new_project = new_project - - @property - def new_task(self): - """Gets the new_task of this JobCompact. # noqa: E501 - - - :return: The new_task of this JobCompact. # noqa: E501 - :rtype: JobBaseNewTask - """ - return self._new_task - - @new_task.setter - def new_task(self, new_task): - """Sets the new_task of this JobCompact. - - - :param new_task: The new_task of this JobCompact. # noqa: E501 - :type: JobBaseNewTask - """ - - self._new_task = new_task - - @property - def new_project_template(self): - """Gets the new_project_template of this JobCompact. # noqa: E501 - - - :return: The new_project_template of this JobCompact. # noqa: E501 - :rtype: JobBaseNewProjectTemplate - """ - return self._new_project_template - - @new_project_template.setter - def new_project_template(self, new_project_template): - """Sets the new_project_template of this JobCompact. - - - :param new_project_template: The new_project_template of this JobCompact. # noqa: E501 - :type: JobBaseNewProjectTemplate - """ - - self._new_project_template = new_project_template - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(JobCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, JobCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/job_response.py b/asana/models/job_response.py deleted file mode 100644 index 63bfd137..00000000 --- a/asana/models/job_response.py +++ /dev/null @@ -1,280 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class JobResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'resource_subtype': 'str', - 'status': 'str', - 'new_project': 'JobBaseNewProject', - 'new_task': 'JobBaseNewTask', - 'new_project_template': 'JobBaseNewProjectTemplate' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'status': 'status', - 'new_project': 'new_project', - 'new_task': 'new_task', - 'new_project_template': 'new_project_template' - } - - def __init__(self, gid=None, resource_type=None, resource_subtype=None, status=None, new_project=None, new_task=None, new_project_template=None): # noqa: E501 - """JobResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._resource_subtype = None - self._status = None - self._new_project = None - self._new_task = None - self._new_project_template = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if status is not None: - self.status = status - if new_project is not None: - self.new_project = new_project - if new_task is not None: - self.new_task = new_task - if new_project_template is not None: - self.new_project_template = new_project_template - - @property - def gid(self): - """Gets the gid of this JobResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this JobResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this JobResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this JobResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this JobResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this JobResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this JobResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this JobResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this JobResponse. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this JobResponse. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this JobResponse. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this JobResponse. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def status(self): - """Gets the status of this JobResponse. # noqa: E501 - - The current status of this job. The value is one of: `not_started`, `in_progress`, `succeeded`, or `failed`. # noqa: E501 - - :return: The status of this JobResponse. # noqa: E501 - :rtype: str - """ - return self._status - - @status.setter - def status(self, status): - """Sets the status of this JobResponse. - - The current status of this job. The value is one of: `not_started`, `in_progress`, `succeeded`, or `failed`. # noqa: E501 - - :param status: The status of this JobResponse. # noqa: E501 - :type: str - """ - allowed_values = ["not_started", "in_progress", "succeeded", "failed"] # noqa: E501 - if status not in allowed_values: - raise ValueError( - "Invalid value for `status` ({0}), must be one of {1}" # noqa: E501 - .format(status, allowed_values) - ) - - self._status = status - - @property - def new_project(self): - """Gets the new_project of this JobResponse. # noqa: E501 - - - :return: The new_project of this JobResponse. # noqa: E501 - :rtype: JobBaseNewProject - """ - return self._new_project - - @new_project.setter - def new_project(self, new_project): - """Sets the new_project of this JobResponse. - - - :param new_project: The new_project of this JobResponse. # noqa: E501 - :type: JobBaseNewProject - """ - - self._new_project = new_project - - @property - def new_task(self): - """Gets the new_task of this JobResponse. # noqa: E501 - - - :return: The new_task of this JobResponse. # noqa: E501 - :rtype: JobBaseNewTask - """ - return self._new_task - - @new_task.setter - def new_task(self, new_task): - """Sets the new_task of this JobResponse. - - - :param new_task: The new_task of this JobResponse. # noqa: E501 - :type: JobBaseNewTask - """ - - self._new_task = new_task - - @property - def new_project_template(self): - """Gets the new_project_template of this JobResponse. # noqa: E501 - - - :return: The new_project_template of this JobResponse. # noqa: E501 - :rtype: JobBaseNewProjectTemplate - """ - return self._new_project_template - - @new_project_template.setter - def new_project_template(self, new_project_template): - """Sets the new_project_template of this JobResponse. - - - :param new_project_template: The new_project_template of this JobResponse. # noqa: E501 - :type: JobBaseNewProjectTemplate - """ - - self._new_project_template = new_project_template - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(JobResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, JobResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/job_response_data.py b/asana/models/job_response_data.py deleted file mode 100644 index 0946bb21..00000000 --- a/asana/models/job_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class JobResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'JobResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """JobResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this JobResponseData. # noqa: E501 - - - :return: The data of this JobResponseData. # noqa: E501 - :rtype: JobResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this JobResponseData. - - - :param data: The data of this JobResponseData. # noqa: E501 - :type: JobResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(JobResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, JobResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/like.py b/asana/models/like.py deleted file mode 100644 index 632970bd..00000000 --- a/asana/models/like.py +++ /dev/null @@ -1,138 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class Like(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'user': 'CustomFieldResponsePeopleValue' - } - - attribute_map = { - 'gid': 'gid', - 'user': 'user' - } - - def __init__(self, gid=None, user=None): # noqa: E501 - """Like - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._user = None - self.discriminator = None - if gid is not None: - self.gid = gid - if user is not None: - self.user = user - - @property - def gid(self): - """Gets the gid of this Like. # noqa: E501 - - Globally unique identifier of the object, as a string. # noqa: E501 - - :return: The gid of this Like. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this Like. - - Globally unique identifier of the object, as a string. # noqa: E501 - - :param gid: The gid of this Like. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def user(self): - """Gets the user of this Like. # noqa: E501 - - - :return: The user of this Like. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this Like. - - - :param user: The user of this Like. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(Like, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, Like): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/member_compact.py b/asana/models/member_compact.py deleted file mode 100644 index 87a7b850..00000000 --- a/asana/models/member_compact.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class MemberCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """MemberCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this MemberCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this MemberCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this MemberCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this MemberCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this MemberCompact. # noqa: E501 - - The type of the member (team or user) # noqa: E501 - - :return: The resource_type of this MemberCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this MemberCompact. - - The type of the member (team or user) # noqa: E501 - - :param resource_type: The resource_type of this MemberCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this MemberCompact. # noqa: E501 - - The name of the member # noqa: E501 - - :return: The name of this MemberCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this MemberCompact. - - The name of the member # noqa: E501 - - :param name: The name of this MemberCompact. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(MemberCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, MemberCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/membership_compact.py b/asana/models/membership_compact.py deleted file mode 100644 index b3193b49..00000000 --- a/asana/models/membership_compact.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class MembershipCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """MembershipCompact - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(MembershipCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, MembershipCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/membership_compact_goal.py b/asana/models/membership_compact_goal.py deleted file mode 100644 index ffca8eea..00000000 --- a/asana/models/membership_compact_goal.py +++ /dev/null @@ -1,194 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class MembershipCompactGoal(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'owner': 'CustomFieldResponseCreatedBy' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'owner': 'owner' - } - - def __init__(self, gid=None, resource_type=None, name=None, owner=None): # noqa: E501 - """MembershipCompactGoal - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._owner = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if owner is not None: - self.owner = owner - - @property - def gid(self): - """Gets the gid of this MembershipCompactGoal. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this MembershipCompactGoal. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this MembershipCompactGoal. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this MembershipCompactGoal. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this MembershipCompactGoal. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this MembershipCompactGoal. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this MembershipCompactGoal. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this MembershipCompactGoal. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this MembershipCompactGoal. # noqa: E501 - - The name of the goal. # noqa: E501 - - :return: The name of this MembershipCompactGoal. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this MembershipCompactGoal. - - The name of the goal. # noqa: E501 - - :param name: The name of this MembershipCompactGoal. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def owner(self): - """Gets the owner of this MembershipCompactGoal. # noqa: E501 - - - :return: The owner of this MembershipCompactGoal. # noqa: E501 - :rtype: CustomFieldResponseCreatedBy - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this MembershipCompactGoal. - - - :param owner: The owner of this MembershipCompactGoal. # noqa: E501 - :type: CustomFieldResponseCreatedBy - """ - - self._owner = owner - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(MembershipCompactGoal, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, MembershipCompactGoal): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/membership_compact_member.py b/asana/models/membership_compact_member.py deleted file mode 100644 index a711c94c..00000000 --- a/asana/models/membership_compact_member.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class MembershipCompactMember(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """MembershipCompactMember - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this MembershipCompactMember. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this MembershipCompactMember. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this MembershipCompactMember. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this MembershipCompactMember. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this MembershipCompactMember. # noqa: E501 - - The type of the member (team or user) # noqa: E501 - - :return: The resource_type of this MembershipCompactMember. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this MembershipCompactMember. - - The type of the member (team or user) # noqa: E501 - - :param resource_type: The resource_type of this MembershipCompactMember. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this MembershipCompactMember. # noqa: E501 - - The name of the member # noqa: E501 - - :return: The name of this MembershipCompactMember. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this MembershipCompactMember. - - The name of the member # noqa: E501 - - :param name: The name of this MembershipCompactMember. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(MembershipCompactMember, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, MembershipCompactMember): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/membership_compact_parent.py b/asana/models/membership_compact_parent.py deleted file mode 100644 index 996911b4..00000000 --- a/asana/models/membership_compact_parent.py +++ /dev/null @@ -1,194 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class MembershipCompactParent(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'owner': 'CustomFieldResponseCreatedBy' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'owner': 'owner' - } - - def __init__(self, gid=None, resource_type=None, name=None, owner=None): # noqa: E501 - """MembershipCompactParent - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._owner = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if owner is not None: - self.owner = owner - - @property - def gid(self): - """Gets the gid of this MembershipCompactParent. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this MembershipCompactParent. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this MembershipCompactParent. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this MembershipCompactParent. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this MembershipCompactParent. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this MembershipCompactParent. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this MembershipCompactParent. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this MembershipCompactParent. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this MembershipCompactParent. # noqa: E501 - - The name of the goal. # noqa: E501 - - :return: The name of this MembershipCompactParent. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this MembershipCompactParent. - - The name of the goal. # noqa: E501 - - :param name: The name of this MembershipCompactParent. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def owner(self): - """Gets the owner of this MembershipCompactParent. # noqa: E501 - - - :return: The owner of this MembershipCompactParent. # noqa: E501 - :rtype: CustomFieldResponseCreatedBy - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this MembershipCompactParent. - - - :param owner: The owner of this MembershipCompactParent. # noqa: E501 - :type: CustomFieldResponseCreatedBy - """ - - self._owner = owner - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(MembershipCompactParent, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, MembershipCompactParent): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/membership_request.py b/asana/models/membership_request.py deleted file mode 100644 index 250c97d8..00000000 --- a/asana/models/membership_request.py +++ /dev/null @@ -1,112 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class MembershipRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'is_active': 'bool' - } - - attribute_map = { - 'is_active': 'is_active' - } - - def __init__(self, is_active=None): # noqa: E501 - """MembershipRequest - a model defined in Swagger""" # noqa: E501 - self._is_active = None - self.discriminator = None - if is_active is not None: - self.is_active = is_active - - @property - def is_active(self): - """Gets the is_active of this MembershipRequest. # noqa: E501 - - *Optional*. Denotes if a member is active. Applies to all memberships # noqa: E501 - - :return: The is_active of this MembershipRequest. # noqa: E501 - :rtype: bool - """ - return self._is_active - - @is_active.setter - def is_active(self, is_active): - """Sets the is_active of this MembershipRequest. - - *Optional*. Denotes if a member is active. Applies to all memberships # noqa: E501 - - :param is_active: The is_active of this MembershipRequest. # noqa: E501 - :type: bool - """ - - self._is_active = is_active - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(MembershipRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, MembershipRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/membership_response.py b/asana/models/membership_response.py deleted file mode 100644 index fed9d3da..00000000 --- a/asana/models/membership_response.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class MembershipResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - } - - attribute_map = { - } - - def __init__(self): # noqa: E501 - """MembershipResponse - a model defined in Swagger""" # noqa: E501 - self.discriminator = None - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(MembershipResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, MembershipResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/membership_response_array.py b/asana/models/membership_response_array.py deleted file mode 100644 index abacdd09..00000000 --- a/asana/models/membership_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class MembershipResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[MembershipResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """MembershipResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this MembershipResponseArray. # noqa: E501 - - - :return: The data of this MembershipResponseArray. # noqa: E501 - :rtype: list[MembershipResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this MembershipResponseArray. - - - :param data: The data of this MembershipResponseArray. # noqa: E501 - :type: list[MembershipResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this MembershipResponseArray. # noqa: E501 - - - :return: The next_page of this MembershipResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this MembershipResponseArray. - - - :param next_page: The next_page of this MembershipResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(MembershipResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, MembershipResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/membership_response_data.py b/asana/models/membership_response_data.py deleted file mode 100644 index dc8e1252..00000000 --- a/asana/models/membership_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class MembershipResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'MembershipResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """MembershipResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this MembershipResponseData. # noqa: E501 - - - :return: The data of this MembershipResponseData. # noqa: E501 - :rtype: MembershipResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this MembershipResponseData. - - - :param data: The data of this MembershipResponseData. # noqa: E501 - :type: MembershipResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(MembershipResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, MembershipResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/memberships_body.py b/asana/models/memberships_body.py deleted file mode 100644 index 4bc24391..00000000 --- a/asana/models/memberships_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class MembershipsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'CreateMembershipRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """MembershipsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this MembershipsBody. # noqa: E501 - - - :return: The data of this MembershipsBody. # noqa: E501 - :rtype: CreateMembershipRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this MembershipsBody. - - - :param data: The data of this MembershipsBody. # noqa: E501 - :type: CreateMembershipRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(MembershipsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, MembershipsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/modify_dependencies_request.py b/asana/models/modify_dependencies_request.py deleted file mode 100644 index 8d25cc4a..00000000 --- a/asana/models/modify_dependencies_request.py +++ /dev/null @@ -1,112 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ModifyDependenciesRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'dependencies': 'list[str]' - } - - attribute_map = { - 'dependencies': 'dependencies' - } - - def __init__(self, dependencies=None): # noqa: E501 - """ModifyDependenciesRequest - a model defined in Swagger""" # noqa: E501 - self._dependencies = None - self.discriminator = None - if dependencies is not None: - self.dependencies = dependencies - - @property - def dependencies(self): - """Gets the dependencies of this ModifyDependenciesRequest. # noqa: E501 - - An array of task gids that a task depends on. # noqa: E501 - - :return: The dependencies of this ModifyDependenciesRequest. # noqa: E501 - :rtype: list[str] - """ - return self._dependencies - - @dependencies.setter - def dependencies(self, dependencies): - """Sets the dependencies of this ModifyDependenciesRequest. - - An array of task gids that a task depends on. # noqa: E501 - - :param dependencies: The dependencies of this ModifyDependenciesRequest. # noqa: E501 - :type: list[str] - """ - - self._dependencies = dependencies - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ModifyDependenciesRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ModifyDependenciesRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/modify_dependents_request.py b/asana/models/modify_dependents_request.py deleted file mode 100644 index 2962716c..00000000 --- a/asana/models/modify_dependents_request.py +++ /dev/null @@ -1,112 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ModifyDependentsRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'dependents': 'list[str]' - } - - attribute_map = { - 'dependents': 'dependents' - } - - def __init__(self, dependents=None): # noqa: E501 - """ModifyDependentsRequest - a model defined in Swagger""" # noqa: E501 - self._dependents = None - self.discriminator = None - if dependents is not None: - self.dependents = dependents - - @property - def dependents(self): - """Gets the dependents of this ModifyDependentsRequest. # noqa: E501 - - An array of task gids that are dependents of the given task. # noqa: E501 - - :return: The dependents of this ModifyDependentsRequest. # noqa: E501 - :rtype: list[str] - """ - return self._dependents - - @dependents.setter - def dependents(self, dependents): - """Sets the dependents of this ModifyDependentsRequest. - - An array of task gids that are dependents of the given task. # noqa: E501 - - :param dependents: The dependents of this ModifyDependentsRequest. # noqa: E501 - :type: list[str] - """ - - self._dependents = dependents - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ModifyDependentsRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ModifyDependentsRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/next_page.py b/asana/models/next_page.py deleted file mode 100644 index d78e9fe1..00000000 --- a/asana/models/next_page.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class NextPage(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'offset': 'str', - 'path': 'str', - 'uri': 'str' - } - - attribute_map = { - 'offset': 'offset', - 'path': 'path', - 'uri': 'uri' - } - - def __init__(self, offset=None, path=None, uri=None): # noqa: E501 - """NextPage - a model defined in Swagger""" # noqa: E501 - self._offset = None - self._path = None - self._uri = None - self.discriminator = None - if offset is not None: - self.offset = offset - if path is not None: - self.path = path - if uri is not None: - self.uri = uri - - @property - def offset(self): - """Gets the offset of this NextPage. # noqa: E501 - - Pagination offset for the request. # noqa: E501 - - :return: The offset of this NextPage. # noqa: E501 - :rtype: str - """ - return self._offset - - @offset.setter - def offset(self, offset): - """Sets the offset of this NextPage. - - Pagination offset for the request. # noqa: E501 - - :param offset: The offset of this NextPage. # noqa: E501 - :type: str - """ - - self._offset = offset - - @property - def path(self): - """Gets the path of this NextPage. # noqa: E501 - - A relative path containing the query parameters to fetch for next_page # noqa: E501 - - :return: The path of this NextPage. # noqa: E501 - :rtype: str - """ - return self._path - - @path.setter - def path(self, path): - """Sets the path of this NextPage. - - A relative path containing the query parameters to fetch for next_page # noqa: E501 - - :param path: The path of this NextPage. # noqa: E501 - :type: str - """ - - self._path = path - - @property - def uri(self): - """Gets the uri of this NextPage. # noqa: E501 - - A full uri containing the query parameters to fetch for next_page # noqa: E501 - - :return: The uri of this NextPage. # noqa: E501 - :rtype: str - """ - return self._uri - - @uri.setter - def uri(self, uri): - """Sets the uri of this NextPage. - - A full uri containing the query parameters to fetch for next_page # noqa: E501 - - :param uri: The uri of this NextPage. # noqa: E501 - :type: str - """ - - self._uri = uri - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(NextPage, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, NextPage): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/organization_export_base.py b/asana/models/organization_export_base.py deleted file mode 100644 index 1c9e4e66..00000000 --- a/asana/models/organization_export_base.py +++ /dev/null @@ -1,256 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class OrganizationExportBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'created_at': 'datetime', - 'download_url': 'str', - 'state': 'str', - 'organization': 'GoalResponseWorkspace' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'created_at': 'created_at', - 'download_url': 'download_url', - 'state': 'state', - 'organization': 'organization' - } - - def __init__(self, gid=None, resource_type=None, created_at=None, download_url=None, state=None, organization=None): # noqa: E501 - """OrganizationExportBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._created_at = None - self._download_url = None - self._state = None - self._organization = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if created_at is not None: - self.created_at = created_at - if download_url is not None: - self.download_url = download_url - if state is not None: - self.state = state - if organization is not None: - self.organization = organization - - @property - def gid(self): - """Gets the gid of this OrganizationExportBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this OrganizationExportBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this OrganizationExportBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this OrganizationExportBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this OrganizationExportBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this OrganizationExportBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this OrganizationExportBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this OrganizationExportBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def created_at(self): - """Gets the created_at of this OrganizationExportBase. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this OrganizationExportBase. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this OrganizationExportBase. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this OrganizationExportBase. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def download_url(self): - """Gets the download_url of this OrganizationExportBase. # noqa: E501 - - Download this URL to retreive the full export of the organization in JSON format. It will be compressed in a gzip (.gz) container. *Note: May be null if the export is still in progress or failed. If present, this URL may only be valid for 1 hour from the time of retrieval. You should avoid persisting this URL somewhere and rather refresh on demand to ensure you do not keep stale URLs.* # noqa: E501 - - :return: The download_url of this OrganizationExportBase. # noqa: E501 - :rtype: str - """ - return self._download_url - - @download_url.setter - def download_url(self, download_url): - """Sets the download_url of this OrganizationExportBase. - - Download this URL to retreive the full export of the organization in JSON format. It will be compressed in a gzip (.gz) container. *Note: May be null if the export is still in progress or failed. If present, this URL may only be valid for 1 hour from the time of retrieval. You should avoid persisting this URL somewhere and rather refresh on demand to ensure you do not keep stale URLs.* # noqa: E501 - - :param download_url: The download_url of this OrganizationExportBase. # noqa: E501 - :type: str - """ - - self._download_url = download_url - - @property - def state(self): - """Gets the state of this OrganizationExportBase. # noqa: E501 - - The current state of the export. # noqa: E501 - - :return: The state of this OrganizationExportBase. # noqa: E501 - :rtype: str - """ - return self._state - - @state.setter - def state(self, state): - """Sets the state of this OrganizationExportBase. - - The current state of the export. # noqa: E501 - - :param state: The state of this OrganizationExportBase. # noqa: E501 - :type: str - """ - allowed_values = ["pending", "started", "finished", "error"] # noqa: E501 - if state not in allowed_values: - raise ValueError( - "Invalid value for `state` ({0}), must be one of {1}" # noqa: E501 - .format(state, allowed_values) - ) - - self._state = state - - @property - def organization(self): - """Gets the organization of this OrganizationExportBase. # noqa: E501 - - - :return: The organization of this OrganizationExportBase. # noqa: E501 - :rtype: GoalResponseWorkspace - """ - return self._organization - - @organization.setter - def organization(self, organization): - """Sets the organization of this OrganizationExportBase. - - - :param organization: The organization of this OrganizationExportBase. # noqa: E501 - :type: GoalResponseWorkspace - """ - - self._organization = organization - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(OrganizationExportBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, OrganizationExportBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/organization_export_compact.py b/asana/models/organization_export_compact.py deleted file mode 100644 index cd61e5e4..00000000 --- a/asana/models/organization_export_compact.py +++ /dev/null @@ -1,256 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class OrganizationExportCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'created_at': 'datetime', - 'download_url': 'str', - 'state': 'str', - 'organization': 'GoalResponseWorkspace' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'created_at': 'created_at', - 'download_url': 'download_url', - 'state': 'state', - 'organization': 'organization' - } - - def __init__(self, gid=None, resource_type=None, created_at=None, download_url=None, state=None, organization=None): # noqa: E501 - """OrganizationExportCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._created_at = None - self._download_url = None - self._state = None - self._organization = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if created_at is not None: - self.created_at = created_at - if download_url is not None: - self.download_url = download_url - if state is not None: - self.state = state - if organization is not None: - self.organization = organization - - @property - def gid(self): - """Gets the gid of this OrganizationExportCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this OrganizationExportCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this OrganizationExportCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this OrganizationExportCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this OrganizationExportCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this OrganizationExportCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this OrganizationExportCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this OrganizationExportCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def created_at(self): - """Gets the created_at of this OrganizationExportCompact. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this OrganizationExportCompact. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this OrganizationExportCompact. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this OrganizationExportCompact. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def download_url(self): - """Gets the download_url of this OrganizationExportCompact. # noqa: E501 - - Download this URL to retreive the full export of the organization in JSON format. It will be compressed in a gzip (.gz) container. *Note: May be null if the export is still in progress or failed. If present, this URL may only be valid for 1 hour from the time of retrieval. You should avoid persisting this URL somewhere and rather refresh on demand to ensure you do not keep stale URLs.* # noqa: E501 - - :return: The download_url of this OrganizationExportCompact. # noqa: E501 - :rtype: str - """ - return self._download_url - - @download_url.setter - def download_url(self, download_url): - """Sets the download_url of this OrganizationExportCompact. - - Download this URL to retreive the full export of the organization in JSON format. It will be compressed in a gzip (.gz) container. *Note: May be null if the export is still in progress or failed. If present, this URL may only be valid for 1 hour from the time of retrieval. You should avoid persisting this URL somewhere and rather refresh on demand to ensure you do not keep stale URLs.* # noqa: E501 - - :param download_url: The download_url of this OrganizationExportCompact. # noqa: E501 - :type: str - """ - - self._download_url = download_url - - @property - def state(self): - """Gets the state of this OrganizationExportCompact. # noqa: E501 - - The current state of the export. # noqa: E501 - - :return: The state of this OrganizationExportCompact. # noqa: E501 - :rtype: str - """ - return self._state - - @state.setter - def state(self, state): - """Sets the state of this OrganizationExportCompact. - - The current state of the export. # noqa: E501 - - :param state: The state of this OrganizationExportCompact. # noqa: E501 - :type: str - """ - allowed_values = ["pending", "started", "finished", "error"] # noqa: E501 - if state not in allowed_values: - raise ValueError( - "Invalid value for `state` ({0}), must be one of {1}" # noqa: E501 - .format(state, allowed_values) - ) - - self._state = state - - @property - def organization(self): - """Gets the organization of this OrganizationExportCompact. # noqa: E501 - - - :return: The organization of this OrganizationExportCompact. # noqa: E501 - :rtype: GoalResponseWorkspace - """ - return self._organization - - @organization.setter - def organization(self, organization): - """Sets the organization of this OrganizationExportCompact. - - - :param organization: The organization of this OrganizationExportCompact. # noqa: E501 - :type: GoalResponseWorkspace - """ - - self._organization = organization - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(OrganizationExportCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, OrganizationExportCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/organization_export_request.py b/asana/models/organization_export_request.py deleted file mode 100644 index a19a5867..00000000 --- a/asana/models/organization_export_request.py +++ /dev/null @@ -1,112 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class OrganizationExportRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'organization': 'str' - } - - attribute_map = { - 'organization': 'organization' - } - - def __init__(self, organization=None): # noqa: E501 - """OrganizationExportRequest - a model defined in Swagger""" # noqa: E501 - self._organization = None - self.discriminator = None - if organization is not None: - self.organization = organization - - @property - def organization(self): - """Gets the organization of this OrganizationExportRequest. # noqa: E501 - - Globally unique identifier for the workspace or organization. # noqa: E501 - - :return: The organization of this OrganizationExportRequest. # noqa: E501 - :rtype: str - """ - return self._organization - - @organization.setter - def organization(self, organization): - """Sets the organization of this OrganizationExportRequest. - - Globally unique identifier for the workspace or organization. # noqa: E501 - - :param organization: The organization of this OrganizationExportRequest. # noqa: E501 - :type: str - """ - - self._organization = organization - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(OrganizationExportRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, OrganizationExportRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/organization_export_response.py b/asana/models/organization_export_response.py deleted file mode 100644 index 7b753507..00000000 --- a/asana/models/organization_export_response.py +++ /dev/null @@ -1,256 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class OrganizationExportResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'created_at': 'datetime', - 'download_url': 'str', - 'state': 'str', - 'organization': 'GoalResponseWorkspace' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'created_at': 'created_at', - 'download_url': 'download_url', - 'state': 'state', - 'organization': 'organization' - } - - def __init__(self, gid=None, resource_type=None, created_at=None, download_url=None, state=None, organization=None): # noqa: E501 - """OrganizationExportResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._created_at = None - self._download_url = None - self._state = None - self._organization = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if created_at is not None: - self.created_at = created_at - if download_url is not None: - self.download_url = download_url - if state is not None: - self.state = state - if organization is not None: - self.organization = organization - - @property - def gid(self): - """Gets the gid of this OrganizationExportResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this OrganizationExportResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this OrganizationExportResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this OrganizationExportResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this OrganizationExportResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this OrganizationExportResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this OrganizationExportResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this OrganizationExportResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def created_at(self): - """Gets the created_at of this OrganizationExportResponse. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this OrganizationExportResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this OrganizationExportResponse. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this OrganizationExportResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def download_url(self): - """Gets the download_url of this OrganizationExportResponse. # noqa: E501 - - Download this URL to retreive the full export of the organization in JSON format. It will be compressed in a gzip (.gz) container. *Note: May be null if the export is still in progress or failed. If present, this URL may only be valid for 1 hour from the time of retrieval. You should avoid persisting this URL somewhere and rather refresh on demand to ensure you do not keep stale URLs.* # noqa: E501 - - :return: The download_url of this OrganizationExportResponse. # noqa: E501 - :rtype: str - """ - return self._download_url - - @download_url.setter - def download_url(self, download_url): - """Sets the download_url of this OrganizationExportResponse. - - Download this URL to retreive the full export of the organization in JSON format. It will be compressed in a gzip (.gz) container. *Note: May be null if the export is still in progress or failed. If present, this URL may only be valid for 1 hour from the time of retrieval. You should avoid persisting this URL somewhere and rather refresh on demand to ensure you do not keep stale URLs.* # noqa: E501 - - :param download_url: The download_url of this OrganizationExportResponse. # noqa: E501 - :type: str - """ - - self._download_url = download_url - - @property - def state(self): - """Gets the state of this OrganizationExportResponse. # noqa: E501 - - The current state of the export. # noqa: E501 - - :return: The state of this OrganizationExportResponse. # noqa: E501 - :rtype: str - """ - return self._state - - @state.setter - def state(self, state): - """Sets the state of this OrganizationExportResponse. - - The current state of the export. # noqa: E501 - - :param state: The state of this OrganizationExportResponse. # noqa: E501 - :type: str - """ - allowed_values = ["pending", "started", "finished", "error"] # noqa: E501 - if state not in allowed_values: - raise ValueError( - "Invalid value for `state` ({0}), must be one of {1}" # noqa: E501 - .format(state, allowed_values) - ) - - self._state = state - - @property - def organization(self): - """Gets the organization of this OrganizationExportResponse. # noqa: E501 - - - :return: The organization of this OrganizationExportResponse. # noqa: E501 - :rtype: GoalResponseWorkspace - """ - return self._organization - - @organization.setter - def organization(self, organization): - """Sets the organization of this OrganizationExportResponse. - - - :param organization: The organization of this OrganizationExportResponse. # noqa: E501 - :type: GoalResponseWorkspace - """ - - self._organization = organization - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(OrganizationExportResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, OrganizationExportResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/organization_export_response_data.py b/asana/models/organization_export_response_data.py deleted file mode 100644 index eca91407..00000000 --- a/asana/models/organization_export_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class OrganizationExportResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'OrganizationExportResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """OrganizationExportResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this OrganizationExportResponseData. # noqa: E501 - - - :return: The data of this OrganizationExportResponseData. # noqa: E501 - :rtype: OrganizationExportResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this OrganizationExportResponseData. - - - :param data: The data of this OrganizationExportResponseData. # noqa: E501 - :type: OrganizationExportResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(OrganizationExportResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, OrganizationExportResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/organization_exports_body.py b/asana/models/organization_exports_body.py deleted file mode 100644 index c28771c9..00000000 --- a/asana/models/organization_exports_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class OrganizationExportsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'OrganizationExportRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """OrganizationExportsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this OrganizationExportsBody. # noqa: E501 - - - :return: The data of this OrganizationExportsBody. # noqa: E501 - :rtype: OrganizationExportRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this OrganizationExportsBody. - - - :param data: The data of this OrganizationExportsBody. # noqa: E501 - :type: OrganizationExportRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(OrganizationExportsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, OrganizationExportsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_add_item_request.py b/asana/models/portfolio_add_item_request.py deleted file mode 100644 index 21006daa..00000000 --- a/asana/models/portfolio_add_item_request.py +++ /dev/null @@ -1,169 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioAddItemRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'item': 'str', - 'insert_before': 'str', - 'insert_after': 'str' - } - - attribute_map = { - 'item': 'item', - 'insert_before': 'insert_before', - 'insert_after': 'insert_after' - } - - def __init__(self, item=None, insert_before=None, insert_after=None): # noqa: E501 - """PortfolioAddItemRequest - a model defined in Swagger""" # noqa: E501 - self._item = None - self._insert_before = None - self._insert_after = None - self.discriminator = None - self.item = item - if insert_before is not None: - self.insert_before = insert_before - if insert_after is not None: - self.insert_after = insert_after - - @property - def item(self): - """Gets the item of this PortfolioAddItemRequest. # noqa: E501 - - The item to add to the portfolio. # noqa: E501 - - :return: The item of this PortfolioAddItemRequest. # noqa: E501 - :rtype: str - """ - return self._item - - @item.setter - def item(self, item): - """Sets the item of this PortfolioAddItemRequest. - - The item to add to the portfolio. # noqa: E501 - - :param item: The item of this PortfolioAddItemRequest. # noqa: E501 - :type: str - """ - if item is None: - raise ValueError("Invalid value for `item`, must not be `None`") # noqa: E501 - - self._item = item - - @property - def insert_before(self): - """Gets the insert_before of this PortfolioAddItemRequest. # noqa: E501 - - An id of an item in this portfolio. The new item will be added before the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. # noqa: E501 - - :return: The insert_before of this PortfolioAddItemRequest. # noqa: E501 - :rtype: str - """ - return self._insert_before - - @insert_before.setter - def insert_before(self, insert_before): - """Sets the insert_before of this PortfolioAddItemRequest. - - An id of an item in this portfolio. The new item will be added before the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. # noqa: E501 - - :param insert_before: The insert_before of this PortfolioAddItemRequest. # noqa: E501 - :type: str - """ - - self._insert_before = insert_before - - @property - def insert_after(self): - """Gets the insert_after of this PortfolioAddItemRequest. # noqa: E501 - - An id of an item in this portfolio. The new item will be added after the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. # noqa: E501 - - :return: The insert_after of this PortfolioAddItemRequest. # noqa: E501 - :rtype: str - """ - return self._insert_after - - @insert_after.setter - def insert_after(self, insert_after): - """Sets the insert_after of this PortfolioAddItemRequest. - - An id of an item in this portfolio. The new item will be added after the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. # noqa: E501 - - :param insert_after: The insert_after of this PortfolioAddItemRequest. # noqa: E501 - :type: str - """ - - self._insert_after = insert_after - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioAddItemRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioAddItemRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_base.py b/asana/models/portfolio_base.py deleted file mode 100644 index 44f87200..00000000 --- a/asana/models/portfolio_base.py +++ /dev/null @@ -1,202 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'color': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'color': 'color' - } - - def __init__(self, gid=None, resource_type=None, name=None, color=None): # noqa: E501 - """PortfolioBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._color = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if color is not None: - self.color = color - - @property - def gid(self): - """Gets the gid of this PortfolioBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this PortfolioBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this PortfolioBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this PortfolioBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this PortfolioBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this PortfolioBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this PortfolioBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this PortfolioBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this PortfolioBase. # noqa: E501 - - The name of the portfolio. # noqa: E501 - - :return: The name of this PortfolioBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this PortfolioBase. - - The name of the portfolio. # noqa: E501 - - :param name: The name of this PortfolioBase. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def color(self): - """Gets the color of this PortfolioBase. # noqa: E501 - - Color of the portfolio. # noqa: E501 - - :return: The color of this PortfolioBase. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this PortfolioBase. - - Color of the portfolio. # noqa: E501 - - :param color: The color of this PortfolioBase. # noqa: E501 - :type: str - """ - allowed_values = ["dark-pink", "dark-green", "dark-blue", "dark-red", "dark-teal", "dark-brown", "dark-orange", "dark-purple", "dark-warm-gray", "light-pink", "light-green", "light-blue", "light-red", "light-teal", "light-brown", "light-orange", "light-purple", "light-warm-gray"] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_compact.py b/asana/models/portfolio_compact.py deleted file mode 100644 index 09c5bdc3..00000000 --- a/asana/models/portfolio_compact.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """PortfolioCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this PortfolioCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this PortfolioCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this PortfolioCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this PortfolioCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this PortfolioCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this PortfolioCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this PortfolioCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this PortfolioCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this PortfolioCompact. # noqa: E501 - - The name of the portfolio. # noqa: E501 - - :return: The name of this PortfolioCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this PortfolioCompact. - - The name of the portfolio. # noqa: E501 - - :param name: The name of this PortfolioCompact. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_gid_add_custom_field_setting_body.py b/asana/models/portfolio_gid_add_custom_field_setting_body.py deleted file mode 100644 index 5c1bf538..00000000 --- a/asana/models/portfolio_gid_add_custom_field_setting_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioGidAddCustomFieldSettingBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'AddCustomFieldSettingRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """PortfolioGidAddCustomFieldSettingBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this PortfolioGidAddCustomFieldSettingBody. # noqa: E501 - - - :return: The data of this PortfolioGidAddCustomFieldSettingBody. # noqa: E501 - :rtype: AddCustomFieldSettingRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this PortfolioGidAddCustomFieldSettingBody. - - - :param data: The data of this PortfolioGidAddCustomFieldSettingBody. # noqa: E501 - :type: AddCustomFieldSettingRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioGidAddCustomFieldSettingBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioGidAddCustomFieldSettingBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_gid_add_item_body.py b/asana/models/portfolio_gid_add_item_body.py deleted file mode 100644 index 67aed623..00000000 --- a/asana/models/portfolio_gid_add_item_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioGidAddItemBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'PortfolioAddItemRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """PortfolioGidAddItemBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this PortfolioGidAddItemBody. # noqa: E501 - - - :return: The data of this PortfolioGidAddItemBody. # noqa: E501 - :rtype: PortfolioAddItemRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this PortfolioGidAddItemBody. - - - :param data: The data of this PortfolioGidAddItemBody. # noqa: E501 - :type: PortfolioAddItemRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioGidAddItemBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioGidAddItemBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_gid_add_members_body.py b/asana/models/portfolio_gid_add_members_body.py deleted file mode 100644 index e462a25d..00000000 --- a/asana/models/portfolio_gid_add_members_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioGidAddMembersBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'AddMembersRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """PortfolioGidAddMembersBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this PortfolioGidAddMembersBody. # noqa: E501 - - - :return: The data of this PortfolioGidAddMembersBody. # noqa: E501 - :rtype: AddMembersRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this PortfolioGidAddMembersBody. - - - :param data: The data of this PortfolioGidAddMembersBody. # noqa: E501 - :type: AddMembersRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioGidAddMembersBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioGidAddMembersBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_gid_remove_custom_field_setting_body.py b/asana/models/portfolio_gid_remove_custom_field_setting_body.py deleted file mode 100644 index ae8b3876..00000000 --- a/asana/models/portfolio_gid_remove_custom_field_setting_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioGidRemoveCustomFieldSettingBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'RemoveCustomFieldSettingRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """PortfolioGidRemoveCustomFieldSettingBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this PortfolioGidRemoveCustomFieldSettingBody. # noqa: E501 - - - :return: The data of this PortfolioGidRemoveCustomFieldSettingBody. # noqa: E501 - :rtype: RemoveCustomFieldSettingRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this PortfolioGidRemoveCustomFieldSettingBody. - - - :param data: The data of this PortfolioGidRemoveCustomFieldSettingBody. # noqa: E501 - :type: RemoveCustomFieldSettingRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioGidRemoveCustomFieldSettingBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioGidRemoveCustomFieldSettingBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_gid_remove_item_body.py b/asana/models/portfolio_gid_remove_item_body.py deleted file mode 100644 index 8546361f..00000000 --- a/asana/models/portfolio_gid_remove_item_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioGidRemoveItemBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'PortfolioRemoveItemRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """PortfolioGidRemoveItemBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this PortfolioGidRemoveItemBody. # noqa: E501 - - - :return: The data of this PortfolioGidRemoveItemBody. # noqa: E501 - :rtype: PortfolioRemoveItemRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this PortfolioGidRemoveItemBody. - - - :param data: The data of this PortfolioGidRemoveItemBody. # noqa: E501 - :type: PortfolioRemoveItemRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioGidRemoveItemBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioGidRemoveItemBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_gid_remove_members_body.py b/asana/models/portfolio_gid_remove_members_body.py deleted file mode 100644 index 13edc0e7..00000000 --- a/asana/models/portfolio_gid_remove_members_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioGidRemoveMembersBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'RemoveMembersRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """PortfolioGidRemoveMembersBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this PortfolioGidRemoveMembersBody. # noqa: E501 - - - :return: The data of this PortfolioGidRemoveMembersBody. # noqa: E501 - :rtype: RemoveMembersRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this PortfolioGidRemoveMembersBody. - - - :param data: The data of this PortfolioGidRemoveMembersBody. # noqa: E501 - :type: RemoveMembersRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioGidRemoveMembersBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioGidRemoveMembersBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_membership_base.py b/asana/models/portfolio_membership_base.py deleted file mode 100644 index 0fa4ee3d..00000000 --- a/asana/models/portfolio_membership_base.py +++ /dev/null @@ -1,192 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioMembershipBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'portfolio': 'PortfolioMembershipBasePortfolio', - 'user': 'CustomFieldResponsePeopleValue' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'portfolio': 'portfolio', - 'user': 'user' - } - - def __init__(self, gid=None, resource_type=None, portfolio=None, user=None): # noqa: E501 - """PortfolioMembershipBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._portfolio = None - self._user = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if portfolio is not None: - self.portfolio = portfolio - if user is not None: - self.user = user - - @property - def gid(self): - """Gets the gid of this PortfolioMembershipBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this PortfolioMembershipBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this PortfolioMembershipBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this PortfolioMembershipBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this PortfolioMembershipBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this PortfolioMembershipBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this PortfolioMembershipBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this PortfolioMembershipBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def portfolio(self): - """Gets the portfolio of this PortfolioMembershipBase. # noqa: E501 - - - :return: The portfolio of this PortfolioMembershipBase. # noqa: E501 - :rtype: PortfolioMembershipBasePortfolio - """ - return self._portfolio - - @portfolio.setter - def portfolio(self, portfolio): - """Sets the portfolio of this PortfolioMembershipBase. - - - :param portfolio: The portfolio of this PortfolioMembershipBase. # noqa: E501 - :type: PortfolioMembershipBasePortfolio - """ - - self._portfolio = portfolio - - @property - def user(self): - """Gets the user of this PortfolioMembershipBase. # noqa: E501 - - - :return: The user of this PortfolioMembershipBase. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this PortfolioMembershipBase. - - - :param user: The user of this PortfolioMembershipBase. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioMembershipBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioMembershipBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_membership_base_portfolio.py b/asana/models/portfolio_membership_base_portfolio.py deleted file mode 100644 index b830b156..00000000 --- a/asana/models/portfolio_membership_base_portfolio.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioMembershipBasePortfolio(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """PortfolioMembershipBasePortfolio - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this PortfolioMembershipBasePortfolio. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this PortfolioMembershipBasePortfolio. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this PortfolioMembershipBasePortfolio. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this PortfolioMembershipBasePortfolio. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this PortfolioMembershipBasePortfolio. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this PortfolioMembershipBasePortfolio. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this PortfolioMembershipBasePortfolio. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this PortfolioMembershipBasePortfolio. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this PortfolioMembershipBasePortfolio. # noqa: E501 - - The name of the portfolio. # noqa: E501 - - :return: The name of this PortfolioMembershipBasePortfolio. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this PortfolioMembershipBasePortfolio. - - The name of the portfolio. # noqa: E501 - - :param name: The name of this PortfolioMembershipBasePortfolio. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioMembershipBasePortfolio, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioMembershipBasePortfolio): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_membership_compact.py b/asana/models/portfolio_membership_compact.py deleted file mode 100644 index d4957004..00000000 --- a/asana/models/portfolio_membership_compact.py +++ /dev/null @@ -1,192 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioMembershipCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'portfolio': 'PortfolioMembershipBasePortfolio', - 'user': 'CustomFieldResponsePeopleValue' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'portfolio': 'portfolio', - 'user': 'user' - } - - def __init__(self, gid=None, resource_type=None, portfolio=None, user=None): # noqa: E501 - """PortfolioMembershipCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._portfolio = None - self._user = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if portfolio is not None: - self.portfolio = portfolio - if user is not None: - self.user = user - - @property - def gid(self): - """Gets the gid of this PortfolioMembershipCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this PortfolioMembershipCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this PortfolioMembershipCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this PortfolioMembershipCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this PortfolioMembershipCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this PortfolioMembershipCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this PortfolioMembershipCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this PortfolioMembershipCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def portfolio(self): - """Gets the portfolio of this PortfolioMembershipCompact. # noqa: E501 - - - :return: The portfolio of this PortfolioMembershipCompact. # noqa: E501 - :rtype: PortfolioMembershipBasePortfolio - """ - return self._portfolio - - @portfolio.setter - def portfolio(self, portfolio): - """Sets the portfolio of this PortfolioMembershipCompact. - - - :param portfolio: The portfolio of this PortfolioMembershipCompact. # noqa: E501 - :type: PortfolioMembershipBasePortfolio - """ - - self._portfolio = portfolio - - @property - def user(self): - """Gets the user of this PortfolioMembershipCompact. # noqa: E501 - - - :return: The user of this PortfolioMembershipCompact. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this PortfolioMembershipCompact. - - - :param user: The user of this PortfolioMembershipCompact. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioMembershipCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioMembershipCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_membership_response.py b/asana/models/portfolio_membership_response.py deleted file mode 100644 index d8792a3a..00000000 --- a/asana/models/portfolio_membership_response.py +++ /dev/null @@ -1,192 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioMembershipResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'portfolio': 'PortfolioMembershipBasePortfolio', - 'user': 'CustomFieldResponsePeopleValue' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'portfolio': 'portfolio', - 'user': 'user' - } - - def __init__(self, gid=None, resource_type=None, portfolio=None, user=None): # noqa: E501 - """PortfolioMembershipResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._portfolio = None - self._user = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if portfolio is not None: - self.portfolio = portfolio - if user is not None: - self.user = user - - @property - def gid(self): - """Gets the gid of this PortfolioMembershipResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this PortfolioMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this PortfolioMembershipResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this PortfolioMembershipResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this PortfolioMembershipResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this PortfolioMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this PortfolioMembershipResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this PortfolioMembershipResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def portfolio(self): - """Gets the portfolio of this PortfolioMembershipResponse. # noqa: E501 - - - :return: The portfolio of this PortfolioMembershipResponse. # noqa: E501 - :rtype: PortfolioMembershipBasePortfolio - """ - return self._portfolio - - @portfolio.setter - def portfolio(self, portfolio): - """Sets the portfolio of this PortfolioMembershipResponse. - - - :param portfolio: The portfolio of this PortfolioMembershipResponse. # noqa: E501 - :type: PortfolioMembershipBasePortfolio - """ - - self._portfolio = portfolio - - @property - def user(self): - """Gets the user of this PortfolioMembershipResponse. # noqa: E501 - - - :return: The user of this PortfolioMembershipResponse. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this PortfolioMembershipResponse. - - - :param user: The user of this PortfolioMembershipResponse. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioMembershipResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioMembershipResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_membership_response_array.py b/asana/models/portfolio_membership_response_array.py deleted file mode 100644 index 4ed87406..00000000 --- a/asana/models/portfolio_membership_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioMembershipResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[PortfolioMembershipResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """PortfolioMembershipResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this PortfolioMembershipResponseArray. # noqa: E501 - - - :return: The data of this PortfolioMembershipResponseArray. # noqa: E501 - :rtype: list[PortfolioMembershipResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this PortfolioMembershipResponseArray. - - - :param data: The data of this PortfolioMembershipResponseArray. # noqa: E501 - :type: list[PortfolioMembershipResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this PortfolioMembershipResponseArray. # noqa: E501 - - - :return: The next_page of this PortfolioMembershipResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this PortfolioMembershipResponseArray. - - - :param next_page: The next_page of this PortfolioMembershipResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioMembershipResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioMembershipResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_membership_response_data.py b/asana/models/portfolio_membership_response_data.py deleted file mode 100644 index 08694c06..00000000 --- a/asana/models/portfolio_membership_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioMembershipResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'PortfolioMembershipResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """PortfolioMembershipResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this PortfolioMembershipResponseData. # noqa: E501 - - - :return: The data of this PortfolioMembershipResponseData. # noqa: E501 - :rtype: PortfolioMembershipResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this PortfolioMembershipResponseData. - - - :param data: The data of this PortfolioMembershipResponseData. # noqa: E501 - :type: PortfolioMembershipResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioMembershipResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioMembershipResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_remove_item_request.py b/asana/models/portfolio_remove_item_request.py deleted file mode 100644 index 2285efe4..00000000 --- a/asana/models/portfolio_remove_item_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioRemoveItemRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'item': 'str' - } - - attribute_map = { - 'item': 'item' - } - - def __init__(self, item=None): # noqa: E501 - """PortfolioRemoveItemRequest - a model defined in Swagger""" # noqa: E501 - self._item = None - self.discriminator = None - self.item = item - - @property - def item(self): - """Gets the item of this PortfolioRemoveItemRequest. # noqa: E501 - - The item to remove from the portfolio. # noqa: E501 - - :return: The item of this PortfolioRemoveItemRequest. # noqa: E501 - :rtype: str - """ - return self._item - - @item.setter - def item(self, item): - """Sets the item of this PortfolioRemoveItemRequest. - - The item to remove from the portfolio. # noqa: E501 - - :param item: The item of this PortfolioRemoveItemRequest. # noqa: E501 - :type: str - """ - if item is None: - raise ValueError("Invalid value for `item`, must not be `None`") # noqa: E501 - - self._item = item - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioRemoveItemRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioRemoveItemRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_request.py b/asana/models/portfolio_request.py deleted file mode 100644 index 336f5cd3..00000000 --- a/asana/models/portfolio_request.py +++ /dev/null @@ -1,286 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'color': 'str', - 'members': 'list[str]', - 'workspace': 'str', - 'public': 'bool' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'color': 'color', - 'members': 'members', - 'workspace': 'workspace', - 'public': 'public' - } - - def __init__(self, gid=None, resource_type=None, name=None, color=None, members=None, workspace=None, public=None): # noqa: E501 - """PortfolioRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._color = None - self._members = None - self._workspace = None - self._public = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if color is not None: - self.color = color - if members is not None: - self.members = members - if workspace is not None: - self.workspace = workspace - if public is not None: - self.public = public - - @property - def gid(self): - """Gets the gid of this PortfolioRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this PortfolioRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this PortfolioRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this PortfolioRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this PortfolioRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this PortfolioRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this PortfolioRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this PortfolioRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this PortfolioRequest. # noqa: E501 - - The name of the portfolio. # noqa: E501 - - :return: The name of this PortfolioRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this PortfolioRequest. - - The name of the portfolio. # noqa: E501 - - :param name: The name of this PortfolioRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def color(self): - """Gets the color of this PortfolioRequest. # noqa: E501 - - Color of the portfolio. # noqa: E501 - - :return: The color of this PortfolioRequest. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this PortfolioRequest. - - Color of the portfolio. # noqa: E501 - - :param color: The color of this PortfolioRequest. # noqa: E501 - :type: str - """ - allowed_values = ["dark-pink", "dark-green", "dark-blue", "dark-red", "dark-teal", "dark-brown", "dark-orange", "dark-purple", "dark-warm-gray", "light-pink", "light-green", "light-blue", "light-red", "light-teal", "light-brown", "light-orange", "light-purple", "light-warm-gray"] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def members(self): - """Gets the members of this PortfolioRequest. # noqa: E501 - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :return: The members of this PortfolioRequest. # noqa: E501 - :rtype: list[str] - """ - return self._members - - @members.setter - def members(self, members): - """Sets the members of this PortfolioRequest. - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :param members: The members of this PortfolioRequest. # noqa: E501 - :type: list[str] - """ - - self._members = members - - @property - def workspace(self): - """Gets the workspace of this PortfolioRequest. # noqa: E501 - - Gid of an object. # noqa: E501 - - :return: The workspace of this PortfolioRequest. # noqa: E501 - :rtype: str - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this PortfolioRequest. - - Gid of an object. # noqa: E501 - - :param workspace: The workspace of this PortfolioRequest. # noqa: E501 - :type: str - """ - - self._workspace = workspace - - @property - def public(self): - """Gets the public of this PortfolioRequest. # noqa: E501 - - True if the portfolio is public to its workspace members. # noqa: E501 - - :return: The public of this PortfolioRequest. # noqa: E501 - :rtype: bool - """ - return self._public - - @public.setter - def public(self, public): - """Sets the public of this PortfolioRequest. - - True if the portfolio is public to its workspace members. # noqa: E501 - - :param public: The public of this PortfolioRequest. # noqa: E501 - :type: bool - """ - - self._public = public - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_response.py b/asana/models/portfolio_response.py deleted file mode 100644 index d533abb7..00000000 --- a/asana/models/portfolio_response.py +++ /dev/null @@ -1,556 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'color': 'str', - 'created_at': 'datetime', - 'created_by': 'CustomFieldResponsePeopleValue', - 'custom_field_settings': 'list[PortfolioResponseCustomFieldSettings]', - 'current_status_update': 'PortfolioResponseCurrentStatusUpdate', - 'due_on': 'date', - 'custom_fields': 'list[PortfolioResponseCustomFields]', - 'members': 'list[CustomFieldResponsePeopleValue]', - 'owner': 'CustomFieldResponsePeopleValue', - 'start_on': 'date', - 'workspace': 'PortfolioResponseWorkspace', - 'permalink_url': 'str', - 'public': 'bool', - 'project_templates': 'list[JobBaseNewProjectTemplate]' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'color': 'color', - 'created_at': 'created_at', - 'created_by': 'created_by', - 'custom_field_settings': 'custom_field_settings', - 'current_status_update': 'current_status_update', - 'due_on': 'due_on', - 'custom_fields': 'custom_fields', - 'members': 'members', - 'owner': 'owner', - 'start_on': 'start_on', - 'workspace': 'workspace', - 'permalink_url': 'permalink_url', - 'public': 'public', - 'project_templates': 'project_templates' - } - - def __init__(self, gid=None, resource_type=None, name=None, color=None, created_at=None, created_by=None, custom_field_settings=None, current_status_update=None, due_on=None, custom_fields=None, members=None, owner=None, start_on=None, workspace=None, permalink_url=None, public=None, project_templates=None): # noqa: E501 - """PortfolioResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._color = None - self._created_at = None - self._created_by = None - self._custom_field_settings = None - self._current_status_update = None - self._due_on = None - self._custom_fields = None - self._members = None - self._owner = None - self._start_on = None - self._workspace = None - self._permalink_url = None - self._public = None - self._project_templates = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if color is not None: - self.color = color - if created_at is not None: - self.created_at = created_at - if created_by is not None: - self.created_by = created_by - if custom_field_settings is not None: - self.custom_field_settings = custom_field_settings - if current_status_update is not None: - self.current_status_update = current_status_update - if due_on is not None: - self.due_on = due_on - if custom_fields is not None: - self.custom_fields = custom_fields - if members is not None: - self.members = members - if owner is not None: - self.owner = owner - if start_on is not None: - self.start_on = start_on - if workspace is not None: - self.workspace = workspace - if permalink_url is not None: - self.permalink_url = permalink_url - if public is not None: - self.public = public - if project_templates is not None: - self.project_templates = project_templates - - @property - def gid(self): - """Gets the gid of this PortfolioResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this PortfolioResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this PortfolioResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this PortfolioResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this PortfolioResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this PortfolioResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this PortfolioResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this PortfolioResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this PortfolioResponse. # noqa: E501 - - The name of the portfolio. # noqa: E501 - - :return: The name of this PortfolioResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this PortfolioResponse. - - The name of the portfolio. # noqa: E501 - - :param name: The name of this PortfolioResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def color(self): - """Gets the color of this PortfolioResponse. # noqa: E501 - - Color of the portfolio. # noqa: E501 - - :return: The color of this PortfolioResponse. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this PortfolioResponse. - - Color of the portfolio. # noqa: E501 - - :param color: The color of this PortfolioResponse. # noqa: E501 - :type: str - """ - allowed_values = ["dark-pink", "dark-green", "dark-blue", "dark-red", "dark-teal", "dark-brown", "dark-orange", "dark-purple", "dark-warm-gray", "light-pink", "light-green", "light-blue", "light-red", "light-teal", "light-brown", "light-orange", "light-purple", "light-warm-gray"] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def created_at(self): - """Gets the created_at of this PortfolioResponse. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this PortfolioResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this PortfolioResponse. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this PortfolioResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def created_by(self): - """Gets the created_by of this PortfolioResponse. # noqa: E501 - - - :return: The created_by of this PortfolioResponse. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this PortfolioResponse. - - - :param created_by: The created_by of this PortfolioResponse. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._created_by = created_by - - @property - def custom_field_settings(self): - """Gets the custom_field_settings of this PortfolioResponse. # noqa: E501 - - Array of custom field settings applied to the portfolio. # noqa: E501 - - :return: The custom_field_settings of this PortfolioResponse. # noqa: E501 - :rtype: list[PortfolioResponseCustomFieldSettings] - """ - return self._custom_field_settings - - @custom_field_settings.setter - def custom_field_settings(self, custom_field_settings): - """Sets the custom_field_settings of this PortfolioResponse. - - Array of custom field settings applied to the portfolio. # noqa: E501 - - :param custom_field_settings: The custom_field_settings of this PortfolioResponse. # noqa: E501 - :type: list[PortfolioResponseCustomFieldSettings] - """ - - self._custom_field_settings = custom_field_settings - - @property - def current_status_update(self): - """Gets the current_status_update of this PortfolioResponse. # noqa: E501 - - - :return: The current_status_update of this PortfolioResponse. # noqa: E501 - :rtype: PortfolioResponseCurrentStatusUpdate - """ - return self._current_status_update - - @current_status_update.setter - def current_status_update(self, current_status_update): - """Sets the current_status_update of this PortfolioResponse. - - - :param current_status_update: The current_status_update of this PortfolioResponse. # noqa: E501 - :type: PortfolioResponseCurrentStatusUpdate - """ - - self._current_status_update = current_status_update - - @property - def due_on(self): - """Gets the due_on of this PortfolioResponse. # noqa: E501 - - The localized day on which this portfolio is due. This takes a date with format YYYY-MM-DD. # noqa: E501 - - :return: The due_on of this PortfolioResponse. # noqa: E501 - :rtype: date - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this PortfolioResponse. - - The localized day on which this portfolio is due. This takes a date with format YYYY-MM-DD. # noqa: E501 - - :param due_on: The due_on of this PortfolioResponse. # noqa: E501 - :type: date - """ - - self._due_on = due_on - - @property - def custom_fields(self): - """Gets the custom_fields of this PortfolioResponse. # noqa: E501 - - Array of Custom Fields. # noqa: E501 - - :return: The custom_fields of this PortfolioResponse. # noqa: E501 - :rtype: list[PortfolioResponseCustomFields] - """ - return self._custom_fields - - @custom_fields.setter - def custom_fields(self, custom_fields): - """Sets the custom_fields of this PortfolioResponse. - - Array of Custom Fields. # noqa: E501 - - :param custom_fields: The custom_fields of this PortfolioResponse. # noqa: E501 - :type: list[PortfolioResponseCustomFields] - """ - - self._custom_fields = custom_fields - - @property - def members(self): - """Gets the members of this PortfolioResponse. # noqa: E501 - - - :return: The members of this PortfolioResponse. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._members - - @members.setter - def members(self, members): - """Sets the members of this PortfolioResponse. - - - :param members: The members of this PortfolioResponse. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._members = members - - @property - def owner(self): - """Gets the owner of this PortfolioResponse. # noqa: E501 - - - :return: The owner of this PortfolioResponse. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this PortfolioResponse. - - - :param owner: The owner of this PortfolioResponse. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._owner = owner - - @property - def start_on(self): - """Gets the start_on of this PortfolioResponse. # noqa: E501 - - The day on which work for this portfolio begins, or null if the portfolio has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* # noqa: E501 - - :return: The start_on of this PortfolioResponse. # noqa: E501 - :rtype: date - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this PortfolioResponse. - - The day on which work for this portfolio begins, or null if the portfolio has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* # noqa: E501 - - :param start_on: The start_on of this PortfolioResponse. # noqa: E501 - :type: date - """ - - self._start_on = start_on - - @property - def workspace(self): - """Gets the workspace of this PortfolioResponse. # noqa: E501 - - - :return: The workspace of this PortfolioResponse. # noqa: E501 - :rtype: PortfolioResponseWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this PortfolioResponse. - - - :param workspace: The workspace of this PortfolioResponse. # noqa: E501 - :type: PortfolioResponseWorkspace - """ - - self._workspace = workspace - - @property - def permalink_url(self): - """Gets the permalink_url of this PortfolioResponse. # noqa: E501 - - A url that points directly to the object within Asana. # noqa: E501 - - :return: The permalink_url of this PortfolioResponse. # noqa: E501 - :rtype: str - """ - return self._permalink_url - - @permalink_url.setter - def permalink_url(self, permalink_url): - """Sets the permalink_url of this PortfolioResponse. - - A url that points directly to the object within Asana. # noqa: E501 - - :param permalink_url: The permalink_url of this PortfolioResponse. # noqa: E501 - :type: str - """ - - self._permalink_url = permalink_url - - @property - def public(self): - """Gets the public of this PortfolioResponse. # noqa: E501 - - True if the portfolio is public to its workspace members. # noqa: E501 - - :return: The public of this PortfolioResponse. # noqa: E501 - :rtype: bool - """ - return self._public - - @public.setter - def public(self, public): - """Sets the public of this PortfolioResponse. - - True if the portfolio is public to its workspace members. # noqa: E501 - - :param public: The public of this PortfolioResponse. # noqa: E501 - :type: bool - """ - - self._public = public - - @property - def project_templates(self): - """Gets the project_templates of this PortfolioResponse. # noqa: E501 - - Array of project templates that are in the portfolio # noqa: E501 - - :return: The project_templates of this PortfolioResponse. # noqa: E501 - :rtype: list[JobBaseNewProjectTemplate] - """ - return self._project_templates - - @project_templates.setter - def project_templates(self, project_templates): - """Sets the project_templates of this PortfolioResponse. - - Array of project templates that are in the portfolio # noqa: E501 - - :param project_templates: The project_templates of this PortfolioResponse. # noqa: E501 - :type: list[JobBaseNewProjectTemplate] - """ - - self._project_templates = project_templates - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_response_array.py b/asana/models/portfolio_response_array.py deleted file mode 100644 index 12da3e7d..00000000 --- a/asana/models/portfolio_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[PortfolioResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """PortfolioResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this PortfolioResponseArray. # noqa: E501 - - - :return: The data of this PortfolioResponseArray. # noqa: E501 - :rtype: list[PortfolioResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this PortfolioResponseArray. - - - :param data: The data of this PortfolioResponseArray. # noqa: E501 - :type: list[PortfolioResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this PortfolioResponseArray. # noqa: E501 - - - :return: The next_page of this PortfolioResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this PortfolioResponseArray. - - - :param next_page: The next_page of this PortfolioResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_response_current_status_update.py b/asana/models/portfolio_response_current_status_update.py deleted file mode 100644 index cecc6f60..00000000 --- a/asana/models/portfolio_response_current_status_update.py +++ /dev/null @@ -1,202 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioResponseCurrentStatusUpdate(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'resource_subtype': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'resource_subtype': 'resource_subtype' - } - - def __init__(self, gid=None, resource_type=None, title=None, resource_subtype=None): # noqa: E501 - """PortfolioResponseCurrentStatusUpdate - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._resource_subtype = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if resource_subtype is not None: - self.resource_subtype = resource_subtype - - @property - def gid(self): - """Gets the gid of this PortfolioResponseCurrentStatusUpdate. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this PortfolioResponseCurrentStatusUpdate. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this PortfolioResponseCurrentStatusUpdate. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this PortfolioResponseCurrentStatusUpdate. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this PortfolioResponseCurrentStatusUpdate. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this PortfolioResponseCurrentStatusUpdate. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this PortfolioResponseCurrentStatusUpdate. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this PortfolioResponseCurrentStatusUpdate. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this PortfolioResponseCurrentStatusUpdate. # noqa: E501 - - The title of the status update. # noqa: E501 - - :return: The title of this PortfolioResponseCurrentStatusUpdate. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this PortfolioResponseCurrentStatusUpdate. - - The title of the status update. # noqa: E501 - - :param title: The title of this PortfolioResponseCurrentStatusUpdate. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def resource_subtype(self): - """Gets the resource_subtype of this PortfolioResponseCurrentStatusUpdate. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :return: The resource_subtype of this PortfolioResponseCurrentStatusUpdate. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this PortfolioResponseCurrentStatusUpdate. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :param resource_subtype: The resource_subtype of this PortfolioResponseCurrentStatusUpdate. # noqa: E501 - :type: str - """ - allowed_values = ["project_status_update", "portfolio_status_update", "goal_status_update"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioResponseCurrentStatusUpdate, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioResponseCurrentStatusUpdate): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_response_custom_field_settings.py b/asana/models/portfolio_response_custom_field_settings.py deleted file mode 100644 index 69969b2b..00000000 --- a/asana/models/portfolio_response_custom_field_settings.py +++ /dev/null @@ -1,246 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioResponseCustomFieldSettings(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'project': 'CustomFieldSettingResponseProject', - 'is_important': 'bool', - 'parent': 'CustomFieldSettingResponseParent', - 'custom_field': 'CustomFieldSettingResponseCustomField' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'project': 'project', - 'is_important': 'is_important', - 'parent': 'parent', - 'custom_field': 'custom_field' - } - - def __init__(self, gid=None, resource_type=None, project=None, is_important=None, parent=None, custom_field=None): # noqa: E501 - """PortfolioResponseCustomFieldSettings - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._project = None - self._is_important = None - self._parent = None - self._custom_field = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if project is not None: - self.project = project - if is_important is not None: - self.is_important = is_important - if parent is not None: - self.parent = parent - if custom_field is not None: - self.custom_field = custom_field - - @property - def gid(self): - """Gets the gid of this PortfolioResponseCustomFieldSettings. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this PortfolioResponseCustomFieldSettings. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this PortfolioResponseCustomFieldSettings. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this PortfolioResponseCustomFieldSettings. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this PortfolioResponseCustomFieldSettings. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this PortfolioResponseCustomFieldSettings. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this PortfolioResponseCustomFieldSettings. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this PortfolioResponseCustomFieldSettings. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def project(self): - """Gets the project of this PortfolioResponseCustomFieldSettings. # noqa: E501 - - - :return: The project of this PortfolioResponseCustomFieldSettings. # noqa: E501 - :rtype: CustomFieldSettingResponseProject - """ - return self._project - - @project.setter - def project(self, project): - """Sets the project of this PortfolioResponseCustomFieldSettings. - - - :param project: The project of this PortfolioResponseCustomFieldSettings. # noqa: E501 - :type: CustomFieldSettingResponseProject - """ - - self._project = project - - @property - def is_important(self): - """Gets the is_important of this PortfolioResponseCustomFieldSettings. # noqa: E501 - - `is_important` is used in the Asana web application to determine if this custom field is displayed in the list/grid view of a project or portfolio. # noqa: E501 - - :return: The is_important of this PortfolioResponseCustomFieldSettings. # noqa: E501 - :rtype: bool - """ - return self._is_important - - @is_important.setter - def is_important(self, is_important): - """Sets the is_important of this PortfolioResponseCustomFieldSettings. - - `is_important` is used in the Asana web application to determine if this custom field is displayed in the list/grid view of a project or portfolio. # noqa: E501 - - :param is_important: The is_important of this PortfolioResponseCustomFieldSettings. # noqa: E501 - :type: bool - """ - - self._is_important = is_important - - @property - def parent(self): - """Gets the parent of this PortfolioResponseCustomFieldSettings. # noqa: E501 - - - :return: The parent of this PortfolioResponseCustomFieldSettings. # noqa: E501 - :rtype: CustomFieldSettingResponseParent - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this PortfolioResponseCustomFieldSettings. - - - :param parent: The parent of this PortfolioResponseCustomFieldSettings. # noqa: E501 - :type: CustomFieldSettingResponseParent - """ - - self._parent = parent - - @property - def custom_field(self): - """Gets the custom_field of this PortfolioResponseCustomFieldSettings. # noqa: E501 - - - :return: The custom_field of this PortfolioResponseCustomFieldSettings. # noqa: E501 - :rtype: CustomFieldSettingResponseCustomField - """ - return self._custom_field - - @custom_field.setter - def custom_field(self, custom_field): - """Sets the custom_field of this PortfolioResponseCustomFieldSettings. - - - :param custom_field: The custom_field of this PortfolioResponseCustomFieldSettings. # noqa: E501 - :type: CustomFieldSettingResponseCustomField - """ - - self._custom_field = custom_field - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioResponseCustomFieldSettings, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioResponseCustomFieldSettings): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_response_custom_fields.py b/asana/models/portfolio_response_custom_fields.py deleted file mode 100644 index 09ea2c40..00000000 --- a/asana/models/portfolio_response_custom_fields.py +++ /dev/null @@ -1,484 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioResponseCustomFields(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'type': 'str', - 'enum_options': 'list[CustomFieldBaseEnumOptions]', - 'enabled': 'bool', - 'is_formula_field': 'bool', - 'date_value': 'CustomFieldBaseDateValue', - 'enum_value': 'CustomFieldBaseEnumValue', - 'multi_enum_values': 'list[CustomFieldBaseEnumOptions]', - 'number_value': 'float', - 'text_value': 'str', - 'display_value': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'type': 'type', - 'enum_options': 'enum_options', - 'enabled': 'enabled', - 'is_formula_field': 'is_formula_field', - 'date_value': 'date_value', - 'enum_value': 'enum_value', - 'multi_enum_values': 'multi_enum_values', - 'number_value': 'number_value', - 'text_value': 'text_value', - 'display_value': 'display_value' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, type=None, enum_options=None, enabled=None, is_formula_field=None, date_value=None, enum_value=None, multi_enum_values=None, number_value=None, text_value=None, display_value=None): # noqa: E501 - """PortfolioResponseCustomFields - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._type = None - self._enum_options = None - self._enabled = None - self._is_formula_field = None - self._date_value = None - self._enum_value = None - self._multi_enum_values = None - self._number_value = None - self._text_value = None - self._display_value = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if type is not None: - self.type = type - if enum_options is not None: - self.enum_options = enum_options - if enabled is not None: - self.enabled = enabled - if is_formula_field is not None: - self.is_formula_field = is_formula_field - if date_value is not None: - self.date_value = date_value - if enum_value is not None: - self.enum_value = enum_value - if multi_enum_values is not None: - self.multi_enum_values = multi_enum_values - if number_value is not None: - self.number_value = number_value - if text_value is not None: - self.text_value = text_value - if display_value is not None: - self.display_value = display_value - - @property - def gid(self): - """Gets the gid of this PortfolioResponseCustomFields. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this PortfolioResponseCustomFields. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this PortfolioResponseCustomFields. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this PortfolioResponseCustomFields. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this PortfolioResponseCustomFields. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this PortfolioResponseCustomFields. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this PortfolioResponseCustomFields. # noqa: E501 - - The name of the custom field. # noqa: E501 - - :return: The name of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this PortfolioResponseCustomFields. - - The name of the custom field. # noqa: E501 - - :param name: The name of this PortfolioResponseCustomFields. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this PortfolioResponseCustomFields. # noqa: E501 - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The resource_subtype of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this PortfolioResponseCustomFields. - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :param resource_subtype: The resource_subtype of this PortfolioResponseCustomFields. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def type(self): - """Gets the type of this PortfolioResponseCustomFields. # noqa: E501 - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The type of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this PortfolioResponseCustomFields. - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :param type: The type of this PortfolioResponseCustomFields. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if type not in allowed_values: - raise ValueError( - "Invalid value for `type` ({0}), must be one of {1}" # noqa: E501 - .format(type, allowed_values) - ) - - self._type = type - - @property - def enum_options(self): - """Gets the enum_options of this PortfolioResponseCustomFields. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :return: The enum_options of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._enum_options - - @enum_options.setter - def enum_options(self, enum_options): - """Sets the enum_options of this PortfolioResponseCustomFields. - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :param enum_options: The enum_options of this PortfolioResponseCustomFields. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._enum_options = enum_options - - @property - def enabled(self): - """Gets the enabled of this PortfolioResponseCustomFields. # noqa: E501 - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :return: The enabled of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this PortfolioResponseCustomFields. - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :param enabled: The enabled of this PortfolioResponseCustomFields. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def is_formula_field(self): - """Gets the is_formula_field of this PortfolioResponseCustomFields. # noqa: E501 - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :return: The is_formula_field of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: bool - """ - return self._is_formula_field - - @is_formula_field.setter - def is_formula_field(self, is_formula_field): - """Sets the is_formula_field of this PortfolioResponseCustomFields. - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :param is_formula_field: The is_formula_field of this PortfolioResponseCustomFields. # noqa: E501 - :type: bool - """ - - self._is_formula_field = is_formula_field - - @property - def date_value(self): - """Gets the date_value of this PortfolioResponseCustomFields. # noqa: E501 - - - :return: The date_value of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: CustomFieldBaseDateValue - """ - return self._date_value - - @date_value.setter - def date_value(self, date_value): - """Sets the date_value of this PortfolioResponseCustomFields. - - - :param date_value: The date_value of this PortfolioResponseCustomFields. # noqa: E501 - :type: CustomFieldBaseDateValue - """ - - self._date_value = date_value - - @property - def enum_value(self): - """Gets the enum_value of this PortfolioResponseCustomFields. # noqa: E501 - - - :return: The enum_value of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: CustomFieldBaseEnumValue - """ - return self._enum_value - - @enum_value.setter - def enum_value(self, enum_value): - """Sets the enum_value of this PortfolioResponseCustomFields. - - - :param enum_value: The enum_value of this PortfolioResponseCustomFields. # noqa: E501 - :type: CustomFieldBaseEnumValue - """ - - self._enum_value = enum_value - - @property - def multi_enum_values(self): - """Gets the multi_enum_values of this PortfolioResponseCustomFields. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :return: The multi_enum_values of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._multi_enum_values - - @multi_enum_values.setter - def multi_enum_values(self, multi_enum_values): - """Sets the multi_enum_values of this PortfolioResponseCustomFields. - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :param multi_enum_values: The multi_enum_values of this PortfolioResponseCustomFields. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._multi_enum_values = multi_enum_values - - @property - def number_value(self): - """Gets the number_value of this PortfolioResponseCustomFields. # noqa: E501 - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :return: The number_value of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: float - """ - return self._number_value - - @number_value.setter - def number_value(self, number_value): - """Sets the number_value of this PortfolioResponseCustomFields. - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :param number_value: The number_value of this PortfolioResponseCustomFields. # noqa: E501 - :type: float - """ - - self._number_value = number_value - - @property - def text_value(self): - """Gets the text_value of this PortfolioResponseCustomFields. # noqa: E501 - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :return: The text_value of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._text_value - - @text_value.setter - def text_value(self, text_value): - """Sets the text_value of this PortfolioResponseCustomFields. - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :param text_value: The text_value of this PortfolioResponseCustomFields. # noqa: E501 - :type: str - """ - - self._text_value = text_value - - @property - def display_value(self): - """Gets the display_value of this PortfolioResponseCustomFields. # noqa: E501 - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :return: The display_value of this PortfolioResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this PortfolioResponseCustomFields. - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :param display_value: The display_value of this PortfolioResponseCustomFields. # noqa: E501 - :type: str - """ - - self._display_value = display_value - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioResponseCustomFields, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioResponseCustomFields): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_response_data.py b/asana/models/portfolio_response_data.py deleted file mode 100644 index 8c484778..00000000 --- a/asana/models/portfolio_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'PortfolioResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """PortfolioResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this PortfolioResponseData. # noqa: E501 - - - :return: The data of this PortfolioResponseData. # noqa: E501 - :rtype: PortfolioResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this PortfolioResponseData. - - - :param data: The data of this PortfolioResponseData. # noqa: E501 - :type: PortfolioResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolio_response_workspace.py b/asana/models/portfolio_response_workspace.py deleted file mode 100644 index 70a66ff5..00000000 --- a/asana/models/portfolio_response_workspace.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfolioResponseWorkspace(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """PortfolioResponseWorkspace - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this PortfolioResponseWorkspace. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this PortfolioResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this PortfolioResponseWorkspace. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this PortfolioResponseWorkspace. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this PortfolioResponseWorkspace. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this PortfolioResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this PortfolioResponseWorkspace. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this PortfolioResponseWorkspace. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this PortfolioResponseWorkspace. # noqa: E501 - - The name of the workspace. # noqa: E501 - - :return: The name of this PortfolioResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this PortfolioResponseWorkspace. - - The name of the workspace. # noqa: E501 - - :param name: The name of this PortfolioResponseWorkspace. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfolioResponseWorkspace, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfolioResponseWorkspace): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolios_body.py b/asana/models/portfolios_body.py deleted file mode 100644 index ab0f68e6..00000000 --- a/asana/models/portfolios_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfoliosBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'PortfolioRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """PortfoliosBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this PortfoliosBody. # noqa: E501 - - - :return: The data of this PortfoliosBody. # noqa: E501 - :rtype: PortfolioRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this PortfoliosBody. - - - :param data: The data of this PortfoliosBody. # noqa: E501 - :type: PortfolioRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfoliosBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfoliosBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/portfolios_portfolio_gid_body.py b/asana/models/portfolios_portfolio_gid_body.py deleted file mode 100644 index 4d71f189..00000000 --- a/asana/models/portfolios_portfolio_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class PortfoliosPortfolioGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'PortfolioRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """PortfoliosPortfolioGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this PortfoliosPortfolioGidBody. # noqa: E501 - - - :return: The data of this PortfoliosPortfolioGidBody. # noqa: E501 - :rtype: PortfolioRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this PortfoliosPortfolioGidBody. - - - :param data: The data of this PortfoliosPortfolioGidBody. # noqa: E501 - :type: PortfolioRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(PortfoliosPortfolioGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, PortfoliosPortfolioGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/preview.py b/asana/models/preview.py deleted file mode 100644 index dd499bb1..00000000 --- a/asana/models/preview.py +++ /dev/null @@ -1,308 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class Preview(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'fallback': 'str', - 'footer': 'str', - 'header': 'str', - 'header_link': 'str', - 'html_text': 'str', - 'text': 'str', - 'title': 'str', - 'title_link': 'str' - } - - attribute_map = { - 'fallback': 'fallback', - 'footer': 'footer', - 'header': 'header', - 'header_link': 'header_link', - 'html_text': 'html_text', - 'text': 'text', - 'title': 'title', - 'title_link': 'title_link' - } - - def __init__(self, fallback=None, footer=None, header=None, header_link=None, html_text=None, text=None, title=None, title_link=None): # noqa: E501 - """Preview - a model defined in Swagger""" # noqa: E501 - self._fallback = None - self._footer = None - self._header = None - self._header_link = None - self._html_text = None - self._text = None - self._title = None - self._title_link = None - self.discriminator = None - if fallback is not None: - self.fallback = fallback - if footer is not None: - self.footer = footer - if header is not None: - self.header = header - if header_link is not None: - self.header_link = header_link - if html_text is not None: - self.html_text = html_text - if text is not None: - self.text = text - if title is not None: - self.title = title - if title_link is not None: - self.title_link = title_link - - @property - def fallback(self): - """Gets the fallback of this Preview. # noqa: E501 - - Some fallback text to display if unable to display the full preview. # noqa: E501 - - :return: The fallback of this Preview. # noqa: E501 - :rtype: str - """ - return self._fallback - - @fallback.setter - def fallback(self, fallback): - """Sets the fallback of this Preview. - - Some fallback text to display if unable to display the full preview. # noqa: E501 - - :param fallback: The fallback of this Preview. # noqa: E501 - :type: str - """ - - self._fallback = fallback - - @property - def footer(self): - """Gets the footer of this Preview. # noqa: E501 - - Text to display in the footer. # noqa: E501 - - :return: The footer of this Preview. # noqa: E501 - :rtype: str - """ - return self._footer - - @footer.setter - def footer(self, footer): - """Sets the footer of this Preview. - - Text to display in the footer. # noqa: E501 - - :param footer: The footer of this Preview. # noqa: E501 - :type: str - """ - - self._footer = footer - - @property - def header(self): - """Gets the header of this Preview. # noqa: E501 - - Text to display in the header. # noqa: E501 - - :return: The header of this Preview. # noqa: E501 - :rtype: str - """ - return self._header - - @header.setter - def header(self, header): - """Sets the header of this Preview. - - Text to display in the header. # noqa: E501 - - :param header: The header of this Preview. # noqa: E501 - :type: str - """ - - self._header = header - - @property - def header_link(self): - """Gets the header_link of this Preview. # noqa: E501 - - Where the header will link to. # noqa: E501 - - :return: The header_link of this Preview. # noqa: E501 - :rtype: str - """ - return self._header_link - - @header_link.setter - def header_link(self, header_link): - """Sets the header_link of this Preview. - - Where the header will link to. # noqa: E501 - - :param header_link: The header_link of this Preview. # noqa: E501 - :type: str - """ - - self._header_link = header_link - - @property - def html_text(self): - """Gets the html_text of this Preview. # noqa: E501 - - HTML formatted text for the body of the preview. # noqa: E501 - - :return: The html_text of this Preview. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this Preview. - - HTML formatted text for the body of the preview. # noqa: E501 - - :param html_text: The html_text of this Preview. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def text(self): - """Gets the text of this Preview. # noqa: E501 - - Text for the body of the preview. # noqa: E501 - - :return: The text of this Preview. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this Preview. - - Text for the body of the preview. # noqa: E501 - - :param text: The text of this Preview. # noqa: E501 - :type: str - """ - - self._text = text - - @property - def title(self): - """Gets the title of this Preview. # noqa: E501 - - Text to display as the title. # noqa: E501 - - :return: The title of this Preview. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this Preview. - - Text to display as the title. # noqa: E501 - - :param title: The title of this Preview. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def title_link(self): - """Gets the title_link of this Preview. # noqa: E501 - - Where to title will link to. # noqa: E501 - - :return: The title_link of this Preview. # noqa: E501 - :rtype: str - """ - return self._title_link - - @title_link.setter - def title_link(self, title_link): - """Sets the title_link of this Preview. - - Where to title will link to. # noqa: E501 - - :param title_link: The title_link of this Preview. # noqa: E501 - :type: str - """ - - self._title_link = title_link - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(Preview, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, Preview): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_base.py b/asana/models/project_base.py deleted file mode 100644 index 3f90fe14..00000000 --- a/asana/models/project_base.py +++ /dev/null @@ -1,698 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'archived': 'bool', - 'color': 'str', - 'created_at': 'datetime', - 'current_status': 'ProjectBaseCurrentStatus', - 'current_status_update': 'ProjectBaseCurrentStatusUpdate', - 'custom_field_settings': 'list[PortfolioResponseCustomFieldSettings]', - 'default_view': 'str', - 'due_date': 'date', - 'due_on': 'date', - 'html_notes': 'str', - 'members': 'list[CustomFieldResponsePeopleValue]', - 'modified_at': 'datetime', - 'notes': 'str', - 'public': 'bool', - 'start_on': 'date', - 'default_access_level': 'str', - 'minimum_access_level_for_customization': 'str', - 'minimum_access_level_for_sharing': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'archived': 'archived', - 'color': 'color', - 'created_at': 'created_at', - 'current_status': 'current_status', - 'current_status_update': 'current_status_update', - 'custom_field_settings': 'custom_field_settings', - 'default_view': 'default_view', - 'due_date': 'due_date', - 'due_on': 'due_on', - 'html_notes': 'html_notes', - 'members': 'members', - 'modified_at': 'modified_at', - 'notes': 'notes', - 'public': 'public', - 'start_on': 'start_on', - 'default_access_level': 'default_access_level', - 'minimum_access_level_for_customization': 'minimum_access_level_for_customization', - 'minimum_access_level_for_sharing': 'minimum_access_level_for_sharing' - } - - def __init__(self, gid=None, resource_type=None, name=None, archived=None, color=None, created_at=None, current_status=None, current_status_update=None, custom_field_settings=None, default_view=None, due_date=None, due_on=None, html_notes=None, members=None, modified_at=None, notes=None, public=None, start_on=None, default_access_level=None, minimum_access_level_for_customization=None, minimum_access_level_for_sharing=None): # noqa: E501 - """ProjectBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._archived = None - self._color = None - self._created_at = None - self._current_status = None - self._current_status_update = None - self._custom_field_settings = None - self._default_view = None - self._due_date = None - self._due_on = None - self._html_notes = None - self._members = None - self._modified_at = None - self._notes = None - self._public = None - self._start_on = None - self._default_access_level = None - self._minimum_access_level_for_customization = None - self._minimum_access_level_for_sharing = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if archived is not None: - self.archived = archived - if color is not None: - self.color = color - if created_at is not None: - self.created_at = created_at - if current_status is not None: - self.current_status = current_status - if current_status_update is not None: - self.current_status_update = current_status_update - if custom_field_settings is not None: - self.custom_field_settings = custom_field_settings - if default_view is not None: - self.default_view = default_view - if due_date is not None: - self.due_date = due_date - if due_on is not None: - self.due_on = due_on - if html_notes is not None: - self.html_notes = html_notes - if members is not None: - self.members = members - if modified_at is not None: - self.modified_at = modified_at - if notes is not None: - self.notes = notes - if public is not None: - self.public = public - if start_on is not None: - self.start_on = start_on - if default_access_level is not None: - self.default_access_level = default_access_level - if minimum_access_level_for_customization is not None: - self.minimum_access_level_for_customization = minimum_access_level_for_customization - if minimum_access_level_for_sharing is not None: - self.minimum_access_level_for_sharing = minimum_access_level_for_sharing - - @property - def gid(self): - """Gets the gid of this ProjectBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectBase. # noqa: E501 - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this ProjectBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectBase. - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this ProjectBase. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def archived(self): - """Gets the archived of this ProjectBase. # noqa: E501 - - True if the project is archived, false if not. Archived projects do not show in the UI by default and may be treated differently for queries. # noqa: E501 - - :return: The archived of this ProjectBase. # noqa: E501 - :rtype: bool - """ - return self._archived - - @archived.setter - def archived(self, archived): - """Sets the archived of this ProjectBase. - - True if the project is archived, false if not. Archived projects do not show in the UI by default and may be treated differently for queries. # noqa: E501 - - :param archived: The archived of this ProjectBase. # noqa: E501 - :type: bool - """ - - self._archived = archived - - @property - def color(self): - """Gets the color of this ProjectBase. # noqa: E501 - - Color of the project. # noqa: E501 - - :return: The color of this ProjectBase. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this ProjectBase. - - Color of the project. # noqa: E501 - - :param color: The color of this ProjectBase. # noqa: E501 - :type: str - """ - allowed_values = ["dark-pink", "dark-green", "dark-blue", "dark-red", "dark-teal", "dark-brown", "dark-orange", "dark-purple", "dark-warm-gray", "light-pink", "light-green", "light-blue", "light-red", "light-teal", "light-brown", "light-orange", "light-purple", "light-warm-gray", "none", ""] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def created_at(self): - """Gets the created_at of this ProjectBase. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this ProjectBase. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this ProjectBase. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this ProjectBase. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def current_status(self): - """Gets the current_status of this ProjectBase. # noqa: E501 - - - :return: The current_status of this ProjectBase. # noqa: E501 - :rtype: ProjectBaseCurrentStatus - """ - return self._current_status - - @current_status.setter - def current_status(self, current_status): - """Sets the current_status of this ProjectBase. - - - :param current_status: The current_status of this ProjectBase. # noqa: E501 - :type: ProjectBaseCurrentStatus - """ - - self._current_status = current_status - - @property - def current_status_update(self): - """Gets the current_status_update of this ProjectBase. # noqa: E501 - - - :return: The current_status_update of this ProjectBase. # noqa: E501 - :rtype: ProjectBaseCurrentStatusUpdate - """ - return self._current_status_update - - @current_status_update.setter - def current_status_update(self, current_status_update): - """Sets the current_status_update of this ProjectBase. - - - :param current_status_update: The current_status_update of this ProjectBase. # noqa: E501 - :type: ProjectBaseCurrentStatusUpdate - """ - - self._current_status_update = current_status_update - - @property - def custom_field_settings(self): - """Gets the custom_field_settings of this ProjectBase. # noqa: E501 - - Array of Custom Field Settings (in compact form). # noqa: E501 - - :return: The custom_field_settings of this ProjectBase. # noqa: E501 - :rtype: list[PortfolioResponseCustomFieldSettings] - """ - return self._custom_field_settings - - @custom_field_settings.setter - def custom_field_settings(self, custom_field_settings): - """Sets the custom_field_settings of this ProjectBase. - - Array of Custom Field Settings (in compact form). # noqa: E501 - - :param custom_field_settings: The custom_field_settings of this ProjectBase. # noqa: E501 - :type: list[PortfolioResponseCustomFieldSettings] - """ - - self._custom_field_settings = custom_field_settings - - @property - def default_view(self): - """Gets the default_view of this ProjectBase. # noqa: E501 - - The default view (list, board, calendar, or timeline) of a project. # noqa: E501 - - :return: The default_view of this ProjectBase. # noqa: E501 - :rtype: str - """ - return self._default_view - - @default_view.setter - def default_view(self, default_view): - """Sets the default_view of this ProjectBase. - - The default view (list, board, calendar, or timeline) of a project. # noqa: E501 - - :param default_view: The default_view of this ProjectBase. # noqa: E501 - :type: str - """ - allowed_values = ["list", "board", "calendar", "timeline"] # noqa: E501 - if default_view not in allowed_values: - raise ValueError( - "Invalid value for `default_view` ({0}), must be one of {1}" # noqa: E501 - .format(default_view, allowed_values) - ) - - self._default_view = default_view - - @property - def due_date(self): - """Gets the due_date of this ProjectBase. # noqa: E501 - - *Deprecated: new integrations should prefer the `due_on` field.* # noqa: E501 - - :return: The due_date of this ProjectBase. # noqa: E501 - :rtype: date - """ - return self._due_date - - @due_date.setter - def due_date(self, due_date): - """Sets the due_date of this ProjectBase. - - *Deprecated: new integrations should prefer the `due_on` field.* # noqa: E501 - - :param due_date: The due_date of this ProjectBase. # noqa: E501 - :type: date - """ - - self._due_date = due_date - - @property - def due_on(self): - """Gets the due_on of this ProjectBase. # noqa: E501 - - The day on which this project is due. This takes a date with format YYYY-MM-DD. # noqa: E501 - - :return: The due_on of this ProjectBase. # noqa: E501 - :rtype: date - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this ProjectBase. - - The day on which this project is due. This takes a date with format YYYY-MM-DD. # noqa: E501 - - :param due_on: The due_on of this ProjectBase. # noqa: E501 - :type: date - """ - - self._due_on = due_on - - @property - def html_notes(self): - """Gets the html_notes of this ProjectBase. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The notes of the project with formatting as HTML. # noqa: E501 - - :return: The html_notes of this ProjectBase. # noqa: E501 - :rtype: str - """ - return self._html_notes - - @html_notes.setter - def html_notes(self, html_notes): - """Sets the html_notes of this ProjectBase. - - [Opt In](/docs/inputoutput-options). The notes of the project with formatting as HTML. # noqa: E501 - - :param html_notes: The html_notes of this ProjectBase. # noqa: E501 - :type: str - """ - - self._html_notes = html_notes - - @property - def members(self): - """Gets the members of this ProjectBase. # noqa: E501 - - Array of users who are members of this project. # noqa: E501 - - :return: The members of this ProjectBase. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._members - - @members.setter - def members(self, members): - """Sets the members of this ProjectBase. - - Array of users who are members of this project. # noqa: E501 - - :param members: The members of this ProjectBase. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._members = members - - @property - def modified_at(self): - """Gets the modified_at of this ProjectBase. # noqa: E501 - - The time at which this project was last modified. *Note: This does not currently reflect any changes in associations such as tasks or comments that may have been added or removed from the project.* # noqa: E501 - - :return: The modified_at of this ProjectBase. # noqa: E501 - :rtype: datetime - """ - return self._modified_at - - @modified_at.setter - def modified_at(self, modified_at): - """Sets the modified_at of this ProjectBase. - - The time at which this project was last modified. *Note: This does not currently reflect any changes in associations such as tasks or comments that may have been added or removed from the project.* # noqa: E501 - - :param modified_at: The modified_at of this ProjectBase. # noqa: E501 - :type: datetime - """ - - self._modified_at = modified_at - - @property - def notes(self): - """Gets the notes of this ProjectBase. # noqa: E501 - - Free-form textual information associated with the project (ie., its description). # noqa: E501 - - :return: The notes of this ProjectBase. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this ProjectBase. - - Free-form textual information associated with the project (ie., its description). # noqa: E501 - - :param notes: The notes of this ProjectBase. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def public(self): - """Gets the public of this ProjectBase. # noqa: E501 - - True if the project is public to its team. # noqa: E501 - - :return: The public of this ProjectBase. # noqa: E501 - :rtype: bool - """ - return self._public - - @public.setter - def public(self, public): - """Sets the public of this ProjectBase. - - True if the project is public to its team. # noqa: E501 - - :param public: The public of this ProjectBase. # noqa: E501 - :type: bool - """ - - self._public = public - - @property - def start_on(self): - """Gets the start_on of this ProjectBase. # noqa: E501 - - The day on which work for this project begins, or null if the project has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* # noqa: E501 - - :return: The start_on of this ProjectBase. # noqa: E501 - :rtype: date - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this ProjectBase. - - The day on which work for this project begins, or null if the project has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* # noqa: E501 - - :param start_on: The start_on of this ProjectBase. # noqa: E501 - :type: date - """ - - self._start_on = start_on - - @property - def default_access_level(self): - """Gets the default_access_level of this ProjectBase. # noqa: E501 - - The default access for users or teams who join or are added as members to the project. # noqa: E501 - - :return: The default_access_level of this ProjectBase. # noqa: E501 - :rtype: str - """ - return self._default_access_level - - @default_access_level.setter - def default_access_level(self, default_access_level): - """Sets the default_access_level of this ProjectBase. - - The default access for users or teams who join or are added as members to the project. # noqa: E501 - - :param default_access_level: The default_access_level of this ProjectBase. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor", "commenter", "viewer"] # noqa: E501 - if default_access_level not in allowed_values: - raise ValueError( - "Invalid value for `default_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(default_access_level, allowed_values) - ) - - self._default_access_level = default_access_level - - @property - def minimum_access_level_for_customization(self): - """Gets the minimum_access_level_for_customization of this ProjectBase. # noqa: E501 - - The minimum access level needed for project members to modify this project's workflow and appearance. # noqa: E501 - - :return: The minimum_access_level_for_customization of this ProjectBase. # noqa: E501 - :rtype: str - """ - return self._minimum_access_level_for_customization - - @minimum_access_level_for_customization.setter - def minimum_access_level_for_customization(self, minimum_access_level_for_customization): - """Sets the minimum_access_level_for_customization of this ProjectBase. - - The minimum access level needed for project members to modify this project's workflow and appearance. # noqa: E501 - - :param minimum_access_level_for_customization: The minimum_access_level_for_customization of this ProjectBase. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor"] # noqa: E501 - if minimum_access_level_for_customization not in allowed_values: - raise ValueError( - "Invalid value for `minimum_access_level_for_customization` ({0}), must be one of {1}" # noqa: E501 - .format(minimum_access_level_for_customization, allowed_values) - ) - - self._minimum_access_level_for_customization = minimum_access_level_for_customization - - @property - def minimum_access_level_for_sharing(self): - """Gets the minimum_access_level_for_sharing of this ProjectBase. # noqa: E501 - - The minimum access level needed for project members to share the project and manage project memberships. # noqa: E501 - - :return: The minimum_access_level_for_sharing of this ProjectBase. # noqa: E501 - :rtype: str - """ - return self._minimum_access_level_for_sharing - - @minimum_access_level_for_sharing.setter - def minimum_access_level_for_sharing(self, minimum_access_level_for_sharing): - """Sets the minimum_access_level_for_sharing of this ProjectBase. - - The minimum access level needed for project members to share the project and manage project memberships. # noqa: E501 - - :param minimum_access_level_for_sharing: The minimum_access_level_for_sharing of this ProjectBase. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor"] # noqa: E501 - if minimum_access_level_for_sharing not in allowed_values: - raise ValueError( - "Invalid value for `minimum_access_level_for_sharing` ({0}), must be one of {1}" # noqa: E501 - .format(minimum_access_level_for_sharing, allowed_values) - ) - - self._minimum_access_level_for_sharing = minimum_access_level_for_sharing - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_base_current_status.py b/asana/models/project_base_current_status.py deleted file mode 100644 index 9c509562..00000000 --- a/asana/models/project_base_current_status.py +++ /dev/null @@ -1,366 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectBaseCurrentStatus(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'text': 'str', - 'html_text': 'str', - 'color': 'str', - 'author': 'CustomFieldResponsePeopleValue', - 'created_at': 'datetime', - 'created_by': 'CustomFieldResponsePeopleValue', - 'modified_at': 'datetime' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'text': 'text', - 'html_text': 'html_text', - 'color': 'color', - 'author': 'author', - 'created_at': 'created_at', - 'created_by': 'created_by', - 'modified_at': 'modified_at' - } - - def __init__(self, gid=None, resource_type=None, title=None, text=None, html_text=None, color=None, author=None, created_at=None, created_by=None, modified_at=None): # noqa: E501 - """ProjectBaseCurrentStatus - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._text = None - self._html_text = None - self._color = None - self._author = None - self._created_at = None - self._created_by = None - self._modified_at = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if text is not None: - self.text = text - if html_text is not None: - self.html_text = html_text - if color is not None: - self.color = color - if author is not None: - self.author = author - if created_at is not None: - self.created_at = created_at - if created_by is not None: - self.created_by = created_by - if modified_at is not None: - self.modified_at = modified_at - - @property - def gid(self): - """Gets the gid of this ProjectBaseCurrentStatus. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectBaseCurrentStatus. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectBaseCurrentStatus. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectBaseCurrentStatus. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectBaseCurrentStatus. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectBaseCurrentStatus. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectBaseCurrentStatus. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectBaseCurrentStatus. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this ProjectBaseCurrentStatus. # noqa: E501 - - The title of the project status update. # noqa: E501 - - :return: The title of this ProjectBaseCurrentStatus. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this ProjectBaseCurrentStatus. - - The title of the project status update. # noqa: E501 - - :param title: The title of this ProjectBaseCurrentStatus. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def text(self): - """Gets the text of this ProjectBaseCurrentStatus. # noqa: E501 - - The text content of the status update. # noqa: E501 - - :return: The text of this ProjectBaseCurrentStatus. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this ProjectBaseCurrentStatus. - - The text content of the status update. # noqa: E501 - - :param text: The text of this ProjectBaseCurrentStatus. # noqa: E501 - :type: str - """ - - self._text = text - - @property - def html_text(self): - """Gets the html_text of this ProjectBaseCurrentStatus. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :return: The html_text of this ProjectBaseCurrentStatus. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this ProjectBaseCurrentStatus. - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :param html_text: The html_text of this ProjectBaseCurrentStatus. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def color(self): - """Gets the color of this ProjectBaseCurrentStatus. # noqa: E501 - - The color associated with the status update. # noqa: E501 - - :return: The color of this ProjectBaseCurrentStatus. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this ProjectBaseCurrentStatus. - - The color associated with the status update. # noqa: E501 - - :param color: The color of this ProjectBaseCurrentStatus. # noqa: E501 - :type: str - """ - allowed_values = ["green", "yellow", "red", "blue", "complete"] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def author(self): - """Gets the author of this ProjectBaseCurrentStatus. # noqa: E501 - - - :return: The author of this ProjectBaseCurrentStatus. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._author - - @author.setter - def author(self, author): - """Sets the author of this ProjectBaseCurrentStatus. - - - :param author: The author of this ProjectBaseCurrentStatus. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._author = author - - @property - def created_at(self): - """Gets the created_at of this ProjectBaseCurrentStatus. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this ProjectBaseCurrentStatus. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this ProjectBaseCurrentStatus. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this ProjectBaseCurrentStatus. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def created_by(self): - """Gets the created_by of this ProjectBaseCurrentStatus. # noqa: E501 - - - :return: The created_by of this ProjectBaseCurrentStatus. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this ProjectBaseCurrentStatus. - - - :param created_by: The created_by of this ProjectBaseCurrentStatus. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._created_by = created_by - - @property - def modified_at(self): - """Gets the modified_at of this ProjectBaseCurrentStatus. # noqa: E501 - - The time at which this project status was last modified. *Note: This does not currently reflect any changes in associations such as comments that may have been added or removed from the project status.* # noqa: E501 - - :return: The modified_at of this ProjectBaseCurrentStatus. # noqa: E501 - :rtype: datetime - """ - return self._modified_at - - @modified_at.setter - def modified_at(self, modified_at): - """Sets the modified_at of this ProjectBaseCurrentStatus. - - The time at which this project status was last modified. *Note: This does not currently reflect any changes in associations such as comments that may have been added or removed from the project status.* # noqa: E501 - - :param modified_at: The modified_at of this ProjectBaseCurrentStatus. # noqa: E501 - :type: datetime - """ - - self._modified_at = modified_at - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectBaseCurrentStatus, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectBaseCurrentStatus): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_base_current_status_update.py b/asana/models/project_base_current_status_update.py deleted file mode 100644 index 1112d24d..00000000 --- a/asana/models/project_base_current_status_update.py +++ /dev/null @@ -1,202 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectBaseCurrentStatusUpdate(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'resource_subtype': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'resource_subtype': 'resource_subtype' - } - - def __init__(self, gid=None, resource_type=None, title=None, resource_subtype=None): # noqa: E501 - """ProjectBaseCurrentStatusUpdate - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._resource_subtype = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if resource_subtype is not None: - self.resource_subtype = resource_subtype - - @property - def gid(self): - """Gets the gid of this ProjectBaseCurrentStatusUpdate. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectBaseCurrentStatusUpdate. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectBaseCurrentStatusUpdate. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectBaseCurrentStatusUpdate. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectBaseCurrentStatusUpdate. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectBaseCurrentStatusUpdate. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectBaseCurrentStatusUpdate. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectBaseCurrentStatusUpdate. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this ProjectBaseCurrentStatusUpdate. # noqa: E501 - - The title of the status update. # noqa: E501 - - :return: The title of this ProjectBaseCurrentStatusUpdate. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this ProjectBaseCurrentStatusUpdate. - - The title of the status update. # noqa: E501 - - :param title: The title of this ProjectBaseCurrentStatusUpdate. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def resource_subtype(self): - """Gets the resource_subtype of this ProjectBaseCurrentStatusUpdate. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :return: The resource_subtype of this ProjectBaseCurrentStatusUpdate. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this ProjectBaseCurrentStatusUpdate. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :param resource_subtype: The resource_subtype of this ProjectBaseCurrentStatusUpdate. # noqa: E501 - :type: str - """ - allowed_values = ["project_status_update", "portfolio_status_update", "goal_status_update"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectBaseCurrentStatusUpdate, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectBaseCurrentStatusUpdate): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_base_workspace.py b/asana/models/project_base_workspace.py deleted file mode 100644 index a71947c6..00000000 --- a/asana/models/project_base_workspace.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectBaseWorkspace(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """ProjectBaseWorkspace - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this ProjectBaseWorkspace. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectBaseWorkspace. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectBaseWorkspace. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectBaseWorkspace. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectBaseWorkspace. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectBaseWorkspace. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectBaseWorkspace. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectBaseWorkspace. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectBaseWorkspace. # noqa: E501 - - The name of the workspace. # noqa: E501 - - :return: The name of this ProjectBaseWorkspace. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectBaseWorkspace. - - The name of the workspace. # noqa: E501 - - :param name: The name of this ProjectBaseWorkspace. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectBaseWorkspace, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectBaseWorkspace): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_brief_base.py b/asana/models/project_brief_base.py deleted file mode 100644 index 5a8c22c9..00000000 --- a/asana/models/project_brief_base.py +++ /dev/null @@ -1,196 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectBriefBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'html_text': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'html_text': 'html_text' - } - - def __init__(self, gid=None, resource_type=None, title=None, html_text=None): # noqa: E501 - """ProjectBriefBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._html_text = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if html_text is not None: - self.html_text = html_text - - @property - def gid(self): - """Gets the gid of this ProjectBriefBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectBriefBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectBriefBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectBriefBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectBriefBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectBriefBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectBriefBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectBriefBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this ProjectBriefBase. # noqa: E501 - - The title of the project brief. # noqa: E501 - - :return: The title of this ProjectBriefBase. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this ProjectBriefBase. - - The title of the project brief. # noqa: E501 - - :param title: The title of this ProjectBriefBase. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def html_text(self): - """Gets the html_text of this ProjectBriefBase. # noqa: E501 - - HTML formatted text for the project brief. # noqa: E501 - - :return: The html_text of this ProjectBriefBase. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this ProjectBriefBase. - - HTML formatted text for the project brief. # noqa: E501 - - :param html_text: The html_text of this ProjectBriefBase. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectBriefBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectBriefBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_brief_compact.py b/asana/models/project_brief_compact.py deleted file mode 100644 index 1afe6343..00000000 --- a/asana/models/project_brief_compact.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectBriefCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type' - } - - def __init__(self, gid=None, resource_type=None): # noqa: E501 - """ProjectBriefCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - - @property - def gid(self): - """Gets the gid of this ProjectBriefCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectBriefCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectBriefCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectBriefCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectBriefCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectBriefCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectBriefCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectBriefCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectBriefCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectBriefCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_brief_request.py b/asana/models/project_brief_request.py deleted file mode 100644 index f527559c..00000000 --- a/asana/models/project_brief_request.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectBriefRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'html_text': 'str', - 'text': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'html_text': 'html_text', - 'text': 'text' - } - - def __init__(self, gid=None, resource_type=None, title=None, html_text=None, text=None): # noqa: E501 - """ProjectBriefRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._html_text = None - self._text = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if html_text is not None: - self.html_text = html_text - if text is not None: - self.text = text - - @property - def gid(self): - """Gets the gid of this ProjectBriefRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectBriefRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectBriefRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectBriefRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectBriefRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectBriefRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectBriefRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectBriefRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this ProjectBriefRequest. # noqa: E501 - - The title of the project brief. # noqa: E501 - - :return: The title of this ProjectBriefRequest. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this ProjectBriefRequest. - - The title of the project brief. # noqa: E501 - - :param title: The title of this ProjectBriefRequest. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def html_text(self): - """Gets the html_text of this ProjectBriefRequest. # noqa: E501 - - HTML formatted text for the project brief. # noqa: E501 - - :return: The html_text of this ProjectBriefRequest. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this ProjectBriefRequest. - - HTML formatted text for the project brief. # noqa: E501 - - :param html_text: The html_text of this ProjectBriefRequest. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def text(self): - """Gets the text of this ProjectBriefRequest. # noqa: E501 - - The plain text of the project brief. When writing to a project brief, you can specify either `html_text` (preferred) or `text`, but not both. # noqa: E501 - - :return: The text of this ProjectBriefRequest. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this ProjectBriefRequest. - - The plain text of the project brief. When writing to a project brief, you can specify either `html_text` (preferred) or `text`, but not both. # noqa: E501 - - :param text: The text of this ProjectBriefRequest. # noqa: E501 - :type: str - """ - - self._text = text - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectBriefRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectBriefRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_brief_response.py b/asana/models/project_brief_response.py deleted file mode 100644 index 761cc7f4..00000000 --- a/asana/models/project_brief_response.py +++ /dev/null @@ -1,278 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectBriefResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'html_text': 'str', - 'text': 'str', - 'permalink_url': 'str', - 'project': 'ProjectBriefResponseProject' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'html_text': 'html_text', - 'text': 'text', - 'permalink_url': 'permalink_url', - 'project': 'project' - } - - def __init__(self, gid=None, resource_type=None, title=None, html_text=None, text=None, permalink_url=None, project=None): # noqa: E501 - """ProjectBriefResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._html_text = None - self._text = None - self._permalink_url = None - self._project = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if html_text is not None: - self.html_text = html_text - if text is not None: - self.text = text - if permalink_url is not None: - self.permalink_url = permalink_url - if project is not None: - self.project = project - - @property - def gid(self): - """Gets the gid of this ProjectBriefResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectBriefResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectBriefResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectBriefResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectBriefResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectBriefResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectBriefResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectBriefResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this ProjectBriefResponse. # noqa: E501 - - The title of the project brief. # noqa: E501 - - :return: The title of this ProjectBriefResponse. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this ProjectBriefResponse. - - The title of the project brief. # noqa: E501 - - :param title: The title of this ProjectBriefResponse. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def html_text(self): - """Gets the html_text of this ProjectBriefResponse. # noqa: E501 - - HTML formatted text for the project brief. # noqa: E501 - - :return: The html_text of this ProjectBriefResponse. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this ProjectBriefResponse. - - HTML formatted text for the project brief. # noqa: E501 - - :param html_text: The html_text of this ProjectBriefResponse. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def text(self): - """Gets the text of this ProjectBriefResponse. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The plain text of the project brief. # noqa: E501 - - :return: The text of this ProjectBriefResponse. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this ProjectBriefResponse. - - [Opt In](/docs/inputoutput-options). The plain text of the project brief. # noqa: E501 - - :param text: The text of this ProjectBriefResponse. # noqa: E501 - :type: str - """ - - self._text = text - - @property - def permalink_url(self): - """Gets the permalink_url of this ProjectBriefResponse. # noqa: E501 - - A url that points directly to the object within Asana. # noqa: E501 - - :return: The permalink_url of this ProjectBriefResponse. # noqa: E501 - :rtype: str - """ - return self._permalink_url - - @permalink_url.setter - def permalink_url(self, permalink_url): - """Sets the permalink_url of this ProjectBriefResponse. - - A url that points directly to the object within Asana. # noqa: E501 - - :param permalink_url: The permalink_url of this ProjectBriefResponse. # noqa: E501 - :type: str - """ - - self._permalink_url = permalink_url - - @property - def project(self): - """Gets the project of this ProjectBriefResponse. # noqa: E501 - - - :return: The project of this ProjectBriefResponse. # noqa: E501 - :rtype: ProjectBriefResponseProject - """ - return self._project - - @project.setter - def project(self, project): - """Sets the project of this ProjectBriefResponse. - - - :param project: The project of this ProjectBriefResponse. # noqa: E501 - :type: ProjectBriefResponseProject - """ - - self._project = project - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectBriefResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectBriefResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_brief_response_data.py b/asana/models/project_brief_response_data.py deleted file mode 100644 index c54bf3a4..00000000 --- a/asana/models/project_brief_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectBriefResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectBriefResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectBriefResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this ProjectBriefResponseData. # noqa: E501 - - - :return: The data of this ProjectBriefResponseData. # noqa: E501 - :rtype: ProjectBriefResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectBriefResponseData. - - - :param data: The data of this ProjectBriefResponseData. # noqa: E501 - :type: ProjectBriefResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectBriefResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectBriefResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_brief_response_project.py b/asana/models/project_brief_response_project.py deleted file mode 100644 index 551e4f22..00000000 --- a/asana/models/project_brief_response_project.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectBriefResponseProject(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """ProjectBriefResponseProject - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this ProjectBriefResponseProject. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectBriefResponseProject. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectBriefResponseProject. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectBriefResponseProject. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectBriefResponseProject. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectBriefResponseProject. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectBriefResponseProject. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectBriefResponseProject. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectBriefResponseProject. # noqa: E501 - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this ProjectBriefResponseProject. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectBriefResponseProject. - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this ProjectBriefResponseProject. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectBriefResponseProject, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectBriefResponseProject): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_briefs_project_brief_gid_body.py b/asana/models/project_briefs_project_brief_gid_body.py deleted file mode 100644 index f4665e83..00000000 --- a/asana/models/project_briefs_project_brief_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectBriefsProjectBriefGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectBriefRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectBriefsProjectBriefGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectBriefsProjectBriefGidBody. # noqa: E501 - - - :return: The data of this ProjectBriefsProjectBriefGidBody. # noqa: E501 - :rtype: ProjectBriefRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectBriefsProjectBriefGidBody. - - - :param data: The data of this ProjectBriefsProjectBriefGidBody. # noqa: E501 - :type: ProjectBriefRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectBriefsProjectBriefGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectBriefsProjectBriefGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_compact.py b/asana/models/project_compact.py deleted file mode 100644 index 141916ac..00000000 --- a/asana/models/project_compact.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """ProjectCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this ProjectCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectCompact. # noqa: E501 - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this ProjectCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectCompact. - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this ProjectCompact. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_duplicate_request.py b/asana/models/project_duplicate_request.py deleted file mode 100644 index 74a5ed29..00000000 --- a/asana/models/project_duplicate_request.py +++ /dev/null @@ -1,195 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectDuplicateRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'name': 'str', - 'team': 'str', - 'include': 'str', - 'schedule_dates': 'ProjectDuplicateRequestScheduleDates' - } - - attribute_map = { - 'name': 'name', - 'team': 'team', - 'include': 'include', - 'schedule_dates': 'schedule_dates' - } - - def __init__(self, name=None, team=None, include=None, schedule_dates=None): # noqa: E501 - """ProjectDuplicateRequest - a model defined in Swagger""" # noqa: E501 - self._name = None - self._team = None - self._include = None - self._schedule_dates = None - self.discriminator = None - self.name = name - if team is not None: - self.team = team - if include is not None: - self.include = include - if schedule_dates is not None: - self.schedule_dates = schedule_dates - - @property - def name(self): - """Gets the name of this ProjectDuplicateRequest. # noqa: E501 - - The name of the new project. # noqa: E501 - - :return: The name of this ProjectDuplicateRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectDuplicateRequest. - - The name of the new project. # noqa: E501 - - :param name: The name of this ProjectDuplicateRequest. # noqa: E501 - :type: str - """ - if name is None: - raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 - - self._name = name - - @property - def team(self): - """Gets the team of this ProjectDuplicateRequest. # noqa: E501 - - Sets the team of the new project. If team is not defined, the new project will be in the same team as the the original project. # noqa: E501 - - :return: The team of this ProjectDuplicateRequest. # noqa: E501 - :rtype: str - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this ProjectDuplicateRequest. - - Sets the team of the new project. If team is not defined, the new project will be in the same team as the the original project. # noqa: E501 - - :param team: The team of this ProjectDuplicateRequest. # noqa: E501 - :type: str - """ - - self._team = team - - @property - def include(self): - """Gets the include of this ProjectDuplicateRequest. # noqa: E501 - - A comma-separated list of elements that will be duplicated to the new project. Tasks are always included. ##### Fields - forms - members - notes - task_assignee - task_attachments - task_dates - task_dependencies - task_followers - task_notes - task_projects - task_subtasks - task_tags # noqa: E501 - - :return: The include of this ProjectDuplicateRequest. # noqa: E501 - :rtype: str - """ - return self._include - - @include.setter - def include(self, include): - """Sets the include of this ProjectDuplicateRequest. - - A comma-separated list of elements that will be duplicated to the new project. Tasks are always included. ##### Fields - forms - members - notes - task_assignee - task_attachments - task_dates - task_dependencies - task_followers - task_notes - task_projects - task_subtasks - task_tags # noqa: E501 - - :param include: The include of this ProjectDuplicateRequest. # noqa: E501 - :type: str - """ - - self._include = include - - @property - def schedule_dates(self): - """Gets the schedule_dates of this ProjectDuplicateRequest. # noqa: E501 - - - :return: The schedule_dates of this ProjectDuplicateRequest. # noqa: E501 - :rtype: ProjectDuplicateRequestScheduleDates - """ - return self._schedule_dates - - @schedule_dates.setter - def schedule_dates(self, schedule_dates): - """Sets the schedule_dates of this ProjectDuplicateRequest. - - - :param schedule_dates: The schedule_dates of this ProjectDuplicateRequest. # noqa: E501 - :type: ProjectDuplicateRequestScheduleDates - """ - - self._schedule_dates = schedule_dates - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectDuplicateRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectDuplicateRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_duplicate_request_schedule_dates.py b/asana/models/project_duplicate_request_schedule_dates.py deleted file mode 100644 index 5d92a311..00000000 --- a/asana/models/project_duplicate_request_schedule_dates.py +++ /dev/null @@ -1,169 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectDuplicateRequestScheduleDates(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'should_skip_weekends': 'bool', - 'due_on': 'str', - 'start_on': 'str' - } - - attribute_map = { - 'should_skip_weekends': 'should_skip_weekends', - 'due_on': 'due_on', - 'start_on': 'start_on' - } - - def __init__(self, should_skip_weekends=None, due_on=None, start_on=None): # noqa: E501 - """ProjectDuplicateRequestScheduleDates - a model defined in Swagger""" # noqa: E501 - self._should_skip_weekends = None - self._due_on = None - self._start_on = None - self.discriminator = None - self.should_skip_weekends = should_skip_weekends - if due_on is not None: - self.due_on = due_on - if start_on is not None: - self.start_on = start_on - - @property - def should_skip_weekends(self): - """Gets the should_skip_weekends of this ProjectDuplicateRequestScheduleDates. # noqa: E501 - - Determines if the auto-shifted dates should skip weekends. # noqa: E501 - - :return: The should_skip_weekends of this ProjectDuplicateRequestScheduleDates. # noqa: E501 - :rtype: bool - """ - return self._should_skip_weekends - - @should_skip_weekends.setter - def should_skip_weekends(self, should_skip_weekends): - """Sets the should_skip_weekends of this ProjectDuplicateRequestScheduleDates. - - Determines if the auto-shifted dates should skip weekends. # noqa: E501 - - :param should_skip_weekends: The should_skip_weekends of this ProjectDuplicateRequestScheduleDates. # noqa: E501 - :type: bool - """ - if should_skip_weekends is None: - raise ValueError("Invalid value for `should_skip_weekends`, must not be `None`") # noqa: E501 - - self._should_skip_weekends = should_skip_weekends - - @property - def due_on(self): - """Gets the due_on of this ProjectDuplicateRequestScheduleDates. # noqa: E501 - - Sets the last due date in the duplicated project to the given date. The rest of the due dates will be offset by the same amount as the due dates in the original project. # noqa: E501 - - :return: The due_on of this ProjectDuplicateRequestScheduleDates. # noqa: E501 - :rtype: str - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this ProjectDuplicateRequestScheduleDates. - - Sets the last due date in the duplicated project to the given date. The rest of the due dates will be offset by the same amount as the due dates in the original project. # noqa: E501 - - :param due_on: The due_on of this ProjectDuplicateRequestScheduleDates. # noqa: E501 - :type: str - """ - - self._due_on = due_on - - @property - def start_on(self): - """Gets the start_on of this ProjectDuplicateRequestScheduleDates. # noqa: E501 - - Sets the first start date in the duplicated project to the given date. The rest of the start dates will be offset by the same amount as the start dates in the original project. # noqa: E501 - - :return: The start_on of this ProjectDuplicateRequestScheduleDates. # noqa: E501 - :rtype: str - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this ProjectDuplicateRequestScheduleDates. - - Sets the first start date in the duplicated project to the given date. The rest of the start dates will be offset by the same amount as the start dates in the original project. # noqa: E501 - - :param start_on: The start_on of this ProjectDuplicateRequestScheduleDates. # noqa: E501 - :type: str - """ - - self._start_on = start_on - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectDuplicateRequestScheduleDates, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectDuplicateRequestScheduleDates): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_gid_add_custom_field_setting_body.py b/asana/models/project_gid_add_custom_field_setting_body.py deleted file mode 100644 index bacf52ca..00000000 --- a/asana/models/project_gid_add_custom_field_setting_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectGidAddCustomFieldSettingBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'AddCustomFieldSettingRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectGidAddCustomFieldSettingBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectGidAddCustomFieldSettingBody. # noqa: E501 - - - :return: The data of this ProjectGidAddCustomFieldSettingBody. # noqa: E501 - :rtype: AddCustomFieldSettingRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectGidAddCustomFieldSettingBody. - - - :param data: The data of this ProjectGidAddCustomFieldSettingBody. # noqa: E501 - :type: AddCustomFieldSettingRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectGidAddCustomFieldSettingBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectGidAddCustomFieldSettingBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_gid_add_followers_body.py b/asana/models/project_gid_add_followers_body.py deleted file mode 100644 index f55acc66..00000000 --- a/asana/models/project_gid_add_followers_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectGidAddFollowersBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'AddFollowersRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectGidAddFollowersBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectGidAddFollowersBody. # noqa: E501 - - - :return: The data of this ProjectGidAddFollowersBody. # noqa: E501 - :rtype: AddFollowersRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectGidAddFollowersBody. - - - :param data: The data of this ProjectGidAddFollowersBody. # noqa: E501 - :type: AddFollowersRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectGidAddFollowersBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectGidAddFollowersBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_gid_add_members_body.py b/asana/models/project_gid_add_members_body.py deleted file mode 100644 index 314a1fbd..00000000 --- a/asana/models/project_gid_add_members_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectGidAddMembersBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'AddMembersRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectGidAddMembersBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectGidAddMembersBody. # noqa: E501 - - - :return: The data of this ProjectGidAddMembersBody. # noqa: E501 - :rtype: AddMembersRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectGidAddMembersBody. - - - :param data: The data of this ProjectGidAddMembersBody. # noqa: E501 - :type: AddMembersRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectGidAddMembersBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectGidAddMembersBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_gid_duplicate_body.py b/asana/models/project_gid_duplicate_body.py deleted file mode 100644 index 654232e5..00000000 --- a/asana/models/project_gid_duplicate_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectGidDuplicateBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectDuplicateRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectGidDuplicateBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectGidDuplicateBody. # noqa: E501 - - - :return: The data of this ProjectGidDuplicateBody. # noqa: E501 - :rtype: ProjectDuplicateRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectGidDuplicateBody. - - - :param data: The data of this ProjectGidDuplicateBody. # noqa: E501 - :type: ProjectDuplicateRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectGidDuplicateBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectGidDuplicateBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_gid_project_briefs_body.py b/asana/models/project_gid_project_briefs_body.py deleted file mode 100644 index b106e98e..00000000 --- a/asana/models/project_gid_project_briefs_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectGidProjectBriefsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectBriefRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectGidProjectBriefsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectGidProjectBriefsBody. # noqa: E501 - - - :return: The data of this ProjectGidProjectBriefsBody. # noqa: E501 - :rtype: ProjectBriefRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectGidProjectBriefsBody. - - - :param data: The data of this ProjectGidProjectBriefsBody. # noqa: E501 - :type: ProjectBriefRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectGidProjectBriefsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectGidProjectBriefsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_gid_project_statuses_body.py b/asana/models/project_gid_project_statuses_body.py deleted file mode 100644 index 52872ec6..00000000 --- a/asana/models/project_gid_project_statuses_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectGidProjectStatusesBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectStatusRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectGidProjectStatusesBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectGidProjectStatusesBody. # noqa: E501 - - - :return: The data of this ProjectGidProjectStatusesBody. # noqa: E501 - :rtype: ProjectStatusRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectGidProjectStatusesBody. - - - :param data: The data of this ProjectGidProjectStatusesBody. # noqa: E501 - :type: ProjectStatusRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectGidProjectStatusesBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectGidProjectStatusesBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_gid_remove_custom_field_setting_body.py b/asana/models/project_gid_remove_custom_field_setting_body.py deleted file mode 100644 index e9af8d8b..00000000 --- a/asana/models/project_gid_remove_custom_field_setting_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectGidRemoveCustomFieldSettingBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'RemoveCustomFieldSettingRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectGidRemoveCustomFieldSettingBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectGidRemoveCustomFieldSettingBody. # noqa: E501 - - - :return: The data of this ProjectGidRemoveCustomFieldSettingBody. # noqa: E501 - :rtype: RemoveCustomFieldSettingRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectGidRemoveCustomFieldSettingBody. - - - :param data: The data of this ProjectGidRemoveCustomFieldSettingBody. # noqa: E501 - :type: RemoveCustomFieldSettingRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectGidRemoveCustomFieldSettingBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectGidRemoveCustomFieldSettingBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_gid_remove_followers_body.py b/asana/models/project_gid_remove_followers_body.py deleted file mode 100644 index 2bd00178..00000000 --- a/asana/models/project_gid_remove_followers_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectGidRemoveFollowersBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'RemoveFollowersRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectGidRemoveFollowersBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectGidRemoveFollowersBody. # noqa: E501 - - - :return: The data of this ProjectGidRemoveFollowersBody. # noqa: E501 - :rtype: RemoveFollowersRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectGidRemoveFollowersBody. - - - :param data: The data of this ProjectGidRemoveFollowersBody. # noqa: E501 - :type: RemoveFollowersRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectGidRemoveFollowersBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectGidRemoveFollowersBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_gid_remove_members_body.py b/asana/models/project_gid_remove_members_body.py deleted file mode 100644 index a2972bc5..00000000 --- a/asana/models/project_gid_remove_members_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectGidRemoveMembersBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'RemoveMembersRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectGidRemoveMembersBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectGidRemoveMembersBody. # noqa: E501 - - - :return: The data of this ProjectGidRemoveMembersBody. # noqa: E501 - :rtype: RemoveMembersRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectGidRemoveMembersBody. - - - :param data: The data of this ProjectGidRemoveMembersBody. # noqa: E501 - :type: RemoveMembersRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectGidRemoveMembersBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectGidRemoveMembersBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_gid_save_as_template_body.py b/asana/models/project_gid_save_as_template_body.py deleted file mode 100644 index d9c9b5a9..00000000 --- a/asana/models/project_gid_save_as_template_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectGidSaveAsTemplateBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectSaveAsTemplateRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectGidSaveAsTemplateBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectGidSaveAsTemplateBody. # noqa: E501 - - - :return: The data of this ProjectGidSaveAsTemplateBody. # noqa: E501 - :rtype: ProjectSaveAsTemplateRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectGidSaveAsTemplateBody. - - - :param data: The data of this ProjectGidSaveAsTemplateBody. # noqa: E501 - :type: ProjectSaveAsTemplateRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectGidSaveAsTemplateBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectGidSaveAsTemplateBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_gid_sections_body.py b/asana/models/project_gid_sections_body.py deleted file mode 100644 index 287974d7..00000000 --- a/asana/models/project_gid_sections_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectGidSectionsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'SectionRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectGidSectionsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectGidSectionsBody. # noqa: E501 - - - :return: The data of this ProjectGidSectionsBody. # noqa: E501 - :rtype: SectionRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectGidSectionsBody. - - - :param data: The data of this ProjectGidSectionsBody. # noqa: E501 - :type: SectionRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectGidSectionsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectGidSectionsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_membership_base.py b/asana/models/project_membership_base.py deleted file mode 100644 index c7633ced..00000000 --- a/asana/models/project_membership_base.py +++ /dev/null @@ -1,226 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectMembershipBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'parent': 'JobBaseNewProject', - 'member': 'MembershipCompactMember', - 'access_level': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'parent': 'parent', - 'member': 'member', - 'access_level': 'access_level' - } - - def __init__(self, gid=None, resource_type=None, parent=None, member=None, access_level=None): # noqa: E501 - """ProjectMembershipBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._parent = None - self._member = None - self._access_level = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if parent is not None: - self.parent = parent - if member is not None: - self.member = member - if access_level is not None: - self.access_level = access_level - - @property - def gid(self): - """Gets the gid of this ProjectMembershipBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectMembershipBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectMembershipBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectMembershipBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectMembershipBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectMembershipBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectMembershipBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectMembershipBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def parent(self): - """Gets the parent of this ProjectMembershipBase. # noqa: E501 - - - :return: The parent of this ProjectMembershipBase. # noqa: E501 - :rtype: JobBaseNewProject - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this ProjectMembershipBase. - - - :param parent: The parent of this ProjectMembershipBase. # noqa: E501 - :type: JobBaseNewProject - """ - - self._parent = parent - - @property - def member(self): - """Gets the member of this ProjectMembershipBase. # noqa: E501 - - - :return: The member of this ProjectMembershipBase. # noqa: E501 - :rtype: MembershipCompactMember - """ - return self._member - - @member.setter - def member(self, member): - """Sets the member of this ProjectMembershipBase. - - - :param member: The member of this ProjectMembershipBase. # noqa: E501 - :type: MembershipCompactMember - """ - - self._member = member - - @property - def access_level(self): - """Gets the access_level of this ProjectMembershipBase. # noqa: E501 - - Whether the member has admin, editor, commenter, or viewer access to the project. # noqa: E501 - - :return: The access_level of this ProjectMembershipBase. # noqa: E501 - :rtype: str - """ - return self._access_level - - @access_level.setter - def access_level(self, access_level): - """Sets the access_level of this ProjectMembershipBase. - - Whether the member has admin, editor, commenter, or viewer access to the project. # noqa: E501 - - :param access_level: The access_level of this ProjectMembershipBase. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor", "commenter", "viewer"] # noqa: E501 - if access_level not in allowed_values: - raise ValueError( - "Invalid value for `access_level` ({0}), must be one of {1}" # noqa: E501 - .format(access_level, allowed_values) - ) - - self._access_level = access_level - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectMembershipBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectMembershipBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_membership_compact.py b/asana/models/project_membership_compact.py deleted file mode 100644 index 4b403f68..00000000 --- a/asana/models/project_membership_compact.py +++ /dev/null @@ -1,226 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectMembershipCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'parent': 'JobBaseNewProject', - 'member': 'MembershipCompactMember', - 'access_level': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'parent': 'parent', - 'member': 'member', - 'access_level': 'access_level' - } - - def __init__(self, gid=None, resource_type=None, parent=None, member=None, access_level=None): # noqa: E501 - """ProjectMembershipCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._parent = None - self._member = None - self._access_level = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if parent is not None: - self.parent = parent - if member is not None: - self.member = member - if access_level is not None: - self.access_level = access_level - - @property - def gid(self): - """Gets the gid of this ProjectMembershipCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectMembershipCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectMembershipCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectMembershipCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectMembershipCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectMembershipCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectMembershipCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectMembershipCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def parent(self): - """Gets the parent of this ProjectMembershipCompact. # noqa: E501 - - - :return: The parent of this ProjectMembershipCompact. # noqa: E501 - :rtype: JobBaseNewProject - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this ProjectMembershipCompact. - - - :param parent: The parent of this ProjectMembershipCompact. # noqa: E501 - :type: JobBaseNewProject - """ - - self._parent = parent - - @property - def member(self): - """Gets the member of this ProjectMembershipCompact. # noqa: E501 - - - :return: The member of this ProjectMembershipCompact. # noqa: E501 - :rtype: MembershipCompactMember - """ - return self._member - - @member.setter - def member(self, member): - """Sets the member of this ProjectMembershipCompact. - - - :param member: The member of this ProjectMembershipCompact. # noqa: E501 - :type: MembershipCompactMember - """ - - self._member = member - - @property - def access_level(self): - """Gets the access_level of this ProjectMembershipCompact. # noqa: E501 - - Whether the member has admin, editor, commenter, or viewer access to the project. # noqa: E501 - - :return: The access_level of this ProjectMembershipCompact. # noqa: E501 - :rtype: str - """ - return self._access_level - - @access_level.setter - def access_level(self, access_level): - """Sets the access_level of this ProjectMembershipCompact. - - Whether the member has admin, editor, commenter, or viewer access to the project. # noqa: E501 - - :param access_level: The access_level of this ProjectMembershipCompact. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor", "commenter", "viewer"] # noqa: E501 - if access_level not in allowed_values: - raise ValueError( - "Invalid value for `access_level` ({0}), must be one of {1}" # noqa: E501 - .format(access_level, allowed_values) - ) - - self._access_level = access_level - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectMembershipCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectMembershipCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_membership_compact_array.py b/asana/models/project_membership_compact_array.py deleted file mode 100644 index 98f23265..00000000 --- a/asana/models/project_membership_compact_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectMembershipCompactArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[ProjectMembershipCompact]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """ProjectMembershipCompactArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this ProjectMembershipCompactArray. # noqa: E501 - - - :return: The data of this ProjectMembershipCompactArray. # noqa: E501 - :rtype: list[ProjectMembershipCompact] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectMembershipCompactArray. - - - :param data: The data of this ProjectMembershipCompactArray. # noqa: E501 - :type: list[ProjectMembershipCompact] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this ProjectMembershipCompactArray. # noqa: E501 - - - :return: The next_page of this ProjectMembershipCompactArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this ProjectMembershipCompactArray. - - - :param next_page: The next_page of this ProjectMembershipCompactArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectMembershipCompactArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectMembershipCompactArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_membership_compact_response.py b/asana/models/project_membership_compact_response.py deleted file mode 100644 index 56529c44..00000000 --- a/asana/models/project_membership_compact_response.py +++ /dev/null @@ -1,254 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectMembershipCompactResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'parent': 'JobBaseNewProject', - 'member': 'MembershipCompactMember', - 'access_level': 'str', - 'resource_subtype': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'parent': 'parent', - 'member': 'member', - 'access_level': 'access_level', - 'resource_subtype': 'resource_subtype' - } - - def __init__(self, gid=None, resource_type=None, parent=None, member=None, access_level=None, resource_subtype=None): # noqa: E501 - """ProjectMembershipCompactResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._parent = None - self._member = None - self._access_level = None - self._resource_subtype = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if parent is not None: - self.parent = parent - if member is not None: - self.member = member - if access_level is not None: - self.access_level = access_level - if resource_subtype is not None: - self.resource_subtype = resource_subtype - - @property - def gid(self): - """Gets the gid of this ProjectMembershipCompactResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectMembershipCompactResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectMembershipCompactResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectMembershipCompactResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectMembershipCompactResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectMembershipCompactResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectMembershipCompactResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectMembershipCompactResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def parent(self): - """Gets the parent of this ProjectMembershipCompactResponse. # noqa: E501 - - - :return: The parent of this ProjectMembershipCompactResponse. # noqa: E501 - :rtype: JobBaseNewProject - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this ProjectMembershipCompactResponse. - - - :param parent: The parent of this ProjectMembershipCompactResponse. # noqa: E501 - :type: JobBaseNewProject - """ - - self._parent = parent - - @property - def member(self): - """Gets the member of this ProjectMembershipCompactResponse. # noqa: E501 - - - :return: The member of this ProjectMembershipCompactResponse. # noqa: E501 - :rtype: MembershipCompactMember - """ - return self._member - - @member.setter - def member(self, member): - """Sets the member of this ProjectMembershipCompactResponse. - - - :param member: The member of this ProjectMembershipCompactResponse. # noqa: E501 - :type: MembershipCompactMember - """ - - self._member = member - - @property - def access_level(self): - """Gets the access_level of this ProjectMembershipCompactResponse. # noqa: E501 - - Whether the member has admin, editor, commenter, or viewer access to the project. # noqa: E501 - - :return: The access_level of this ProjectMembershipCompactResponse. # noqa: E501 - :rtype: str - """ - return self._access_level - - @access_level.setter - def access_level(self, access_level): - """Sets the access_level of this ProjectMembershipCompactResponse. - - Whether the member has admin, editor, commenter, or viewer access to the project. # noqa: E501 - - :param access_level: The access_level of this ProjectMembershipCompactResponse. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor", "commenter", "viewer"] # noqa: E501 - if access_level not in allowed_values: - raise ValueError( - "Invalid value for `access_level` ({0}), must be one of {1}" # noqa: E501 - .format(access_level, allowed_values) - ) - - self._access_level = access_level - - @property - def resource_subtype(self): - """Gets the resource_subtype of this ProjectMembershipCompactResponse. # noqa: E501 - - Type of the membership. # noqa: E501 - - :return: The resource_subtype of this ProjectMembershipCompactResponse. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this ProjectMembershipCompactResponse. - - Type of the membership. # noqa: E501 - - :param resource_subtype: The resource_subtype of this ProjectMembershipCompactResponse. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectMembershipCompactResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectMembershipCompactResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_membership_compact_response_data.py b/asana/models/project_membership_compact_response_data.py deleted file mode 100644 index a883a304..00000000 --- a/asana/models/project_membership_compact_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectMembershipCompactResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectMembershipCompactResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectMembershipCompactResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this ProjectMembershipCompactResponseData. # noqa: E501 - - - :return: The data of this ProjectMembershipCompactResponseData. # noqa: E501 - :rtype: ProjectMembershipCompactResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectMembershipCompactResponseData. - - - :param data: The data of this ProjectMembershipCompactResponseData. # noqa: E501 - :type: ProjectMembershipCompactResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectMembershipCompactResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectMembershipCompactResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_membership_normal_response.py b/asana/models/project_membership_normal_response.py deleted file mode 100644 index 4e77689d..00000000 --- a/asana/models/project_membership_normal_response.py +++ /dev/null @@ -1,312 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectMembershipNormalResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'parent': 'JobBaseNewProject', - 'member': 'MembershipCompactMember', - 'access_level': 'str', - 'user': 'CustomFieldResponsePeopleValue', - 'project': 'JobBaseNewProject', - 'write_access': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'parent': 'parent', - 'member': 'member', - 'access_level': 'access_level', - 'user': 'user', - 'project': 'project', - 'write_access': 'write_access' - } - - def __init__(self, gid=None, resource_type=None, parent=None, member=None, access_level=None, user=None, project=None, write_access=None): # noqa: E501 - """ProjectMembershipNormalResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._parent = None - self._member = None - self._access_level = None - self._user = None - self._project = None - self._write_access = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if parent is not None: - self.parent = parent - if member is not None: - self.member = member - if access_level is not None: - self.access_level = access_level - if user is not None: - self.user = user - if project is not None: - self.project = project - if write_access is not None: - self.write_access = write_access - - @property - def gid(self): - """Gets the gid of this ProjectMembershipNormalResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectMembershipNormalResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectMembershipNormalResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectMembershipNormalResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectMembershipNormalResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectMembershipNormalResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectMembershipNormalResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectMembershipNormalResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def parent(self): - """Gets the parent of this ProjectMembershipNormalResponse. # noqa: E501 - - - :return: The parent of this ProjectMembershipNormalResponse. # noqa: E501 - :rtype: JobBaseNewProject - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this ProjectMembershipNormalResponse. - - - :param parent: The parent of this ProjectMembershipNormalResponse. # noqa: E501 - :type: JobBaseNewProject - """ - - self._parent = parent - - @property - def member(self): - """Gets the member of this ProjectMembershipNormalResponse. # noqa: E501 - - - :return: The member of this ProjectMembershipNormalResponse. # noqa: E501 - :rtype: MembershipCompactMember - """ - return self._member - - @member.setter - def member(self, member): - """Sets the member of this ProjectMembershipNormalResponse. - - - :param member: The member of this ProjectMembershipNormalResponse. # noqa: E501 - :type: MembershipCompactMember - """ - - self._member = member - - @property - def access_level(self): - """Gets the access_level of this ProjectMembershipNormalResponse. # noqa: E501 - - Whether the member has admin, editor, commenter, or viewer access to the project. # noqa: E501 - - :return: The access_level of this ProjectMembershipNormalResponse. # noqa: E501 - :rtype: str - """ - return self._access_level - - @access_level.setter - def access_level(self, access_level): - """Sets the access_level of this ProjectMembershipNormalResponse. - - Whether the member has admin, editor, commenter, or viewer access to the project. # noqa: E501 - - :param access_level: The access_level of this ProjectMembershipNormalResponse. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor", "commenter", "viewer"] # noqa: E501 - if access_level not in allowed_values: - raise ValueError( - "Invalid value for `access_level` ({0}), must be one of {1}" # noqa: E501 - .format(access_level, allowed_values) - ) - - self._access_level = access_level - - @property - def user(self): - """Gets the user of this ProjectMembershipNormalResponse. # noqa: E501 - - - :return: The user of this ProjectMembershipNormalResponse. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this ProjectMembershipNormalResponse. - - - :param user: The user of this ProjectMembershipNormalResponse. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - @property - def project(self): - """Gets the project of this ProjectMembershipNormalResponse. # noqa: E501 - - - :return: The project of this ProjectMembershipNormalResponse. # noqa: E501 - :rtype: JobBaseNewProject - """ - return self._project - - @project.setter - def project(self, project): - """Sets the project of this ProjectMembershipNormalResponse. - - - :param project: The project of this ProjectMembershipNormalResponse. # noqa: E501 - :type: JobBaseNewProject - """ - - self._project = project - - @property - def write_access(self): - """Gets the write_access of this ProjectMembershipNormalResponse. # noqa: E501 - - Whether the member has full access or comment-only access to the project. # noqa: E501 - - :return: The write_access of this ProjectMembershipNormalResponse. # noqa: E501 - :rtype: str - """ - return self._write_access - - @write_access.setter - def write_access(self, write_access): - """Sets the write_access of this ProjectMembershipNormalResponse. - - Whether the member has full access or comment-only access to the project. # noqa: E501 - - :param write_access: The write_access of this ProjectMembershipNormalResponse. # noqa: E501 - :type: str - """ - allowed_values = ["full_write", "comment_only"] # noqa: E501 - if write_access not in allowed_values: - raise ValueError( - "Invalid value for `write_access` ({0}), must be one of {1}" # noqa: E501 - .format(write_access, allowed_values) - ) - - self._write_access = write_access - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectMembershipNormalResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectMembershipNormalResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_membership_normal_response_data.py b/asana/models/project_membership_normal_response_data.py deleted file mode 100644 index 646a66e3..00000000 --- a/asana/models/project_membership_normal_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectMembershipNormalResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectMembershipNormalResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectMembershipNormalResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this ProjectMembershipNormalResponseData. # noqa: E501 - - - :return: The data of this ProjectMembershipNormalResponseData. # noqa: E501 - :rtype: ProjectMembershipNormalResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectMembershipNormalResponseData. - - - :param data: The data of this ProjectMembershipNormalResponseData. # noqa: E501 - :type: ProjectMembershipNormalResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectMembershipNormalResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectMembershipNormalResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_membership_response.py b/asana/models/project_membership_response.py deleted file mode 100644 index 59bfb6d1..00000000 --- a/asana/models/project_membership_response.py +++ /dev/null @@ -1,286 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectMembershipResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'user': 'CustomFieldResponsePeopleValue', - 'project': 'JobBaseNewProject', - 'member': 'ProjectMembershipResponseMember', - 'write_access': 'str', - 'access_level': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'user': 'user', - 'project': 'project', - 'member': 'member', - 'write_access': 'write_access', - 'access_level': 'access_level' - } - - def __init__(self, gid=None, resource_type=None, user=None, project=None, member=None, write_access=None, access_level=None): # noqa: E501 - """ProjectMembershipResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._user = None - self._project = None - self._member = None - self._write_access = None - self._access_level = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if user is not None: - self.user = user - if project is not None: - self.project = project - if member is not None: - self.member = member - if write_access is not None: - self.write_access = write_access - if access_level is not None: - self.access_level = access_level - - @property - def gid(self): - """Gets the gid of this ProjectMembershipResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectMembershipResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectMembershipResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectMembershipResponse. # noqa: E501 - - Type of the membership. # noqa: E501 - - :return: The resource_type of this ProjectMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectMembershipResponse. - - Type of the membership. # noqa: E501 - - :param resource_type: The resource_type of this ProjectMembershipResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def user(self): - """Gets the user of this ProjectMembershipResponse. # noqa: E501 - - - :return: The user of this ProjectMembershipResponse. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this ProjectMembershipResponse. - - - :param user: The user of this ProjectMembershipResponse. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - @property - def project(self): - """Gets the project of this ProjectMembershipResponse. # noqa: E501 - - - :return: The project of this ProjectMembershipResponse. # noqa: E501 - :rtype: JobBaseNewProject - """ - return self._project - - @project.setter - def project(self, project): - """Sets the project of this ProjectMembershipResponse. - - - :param project: The project of this ProjectMembershipResponse. # noqa: E501 - :type: JobBaseNewProject - """ - - self._project = project - - @property - def member(self): - """Gets the member of this ProjectMembershipResponse. # noqa: E501 - - - :return: The member of this ProjectMembershipResponse. # noqa: E501 - :rtype: ProjectMembershipResponseMember - """ - return self._member - - @member.setter - def member(self, member): - """Sets the member of this ProjectMembershipResponse. - - - :param member: The member of this ProjectMembershipResponse. # noqa: E501 - :type: ProjectMembershipResponseMember - """ - - self._member = member - - @property - def write_access(self): - """Gets the write_access of this ProjectMembershipResponse. # noqa: E501 - - Whether the member has full access or comment-only access to the project. # noqa: E501 - - :return: The write_access of this ProjectMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._write_access - - @write_access.setter - def write_access(self, write_access): - """Sets the write_access of this ProjectMembershipResponse. - - Whether the member has full access or comment-only access to the project. # noqa: E501 - - :param write_access: The write_access of this ProjectMembershipResponse. # noqa: E501 - :type: str - """ - allowed_values = ["full_write", "comment_only"] # noqa: E501 - if write_access not in allowed_values: - raise ValueError( - "Invalid value for `write_access` ({0}), must be one of {1}" # noqa: E501 - .format(write_access, allowed_values) - ) - - self._write_access = write_access - - @property - def access_level(self): - """Gets the access_level of this ProjectMembershipResponse. # noqa: E501 - - Whether the member has admin, editor, commenter, or viewer access to the project. # noqa: E501 - - :return: The access_level of this ProjectMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._access_level - - @access_level.setter - def access_level(self, access_level): - """Sets the access_level of this ProjectMembershipResponse. - - Whether the member has admin, editor, commenter, or viewer access to the project. # noqa: E501 - - :param access_level: The access_level of this ProjectMembershipResponse. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor", "commenter", "viewer"] # noqa: E501 - if access_level not in allowed_values: - raise ValueError( - "Invalid value for `access_level` ({0}), must be one of {1}" # noqa: E501 - .format(access_level, allowed_values) - ) - - self._access_level = access_level - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectMembershipResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectMembershipResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_membership_response_array.py b/asana/models/project_membership_response_array.py deleted file mode 100644 index 7a27d892..00000000 --- a/asana/models/project_membership_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectMembershipResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[ProjectMembershipResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """ProjectMembershipResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this ProjectMembershipResponseArray. # noqa: E501 - - - :return: The data of this ProjectMembershipResponseArray. # noqa: E501 - :rtype: list[ProjectMembershipResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectMembershipResponseArray. - - - :param data: The data of this ProjectMembershipResponseArray. # noqa: E501 - :type: list[ProjectMembershipResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this ProjectMembershipResponseArray. # noqa: E501 - - - :return: The next_page of this ProjectMembershipResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this ProjectMembershipResponseArray. - - - :param next_page: The next_page of this ProjectMembershipResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectMembershipResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectMembershipResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_membership_response_data.py b/asana/models/project_membership_response_data.py deleted file mode 100644 index 0848c8f7..00000000 --- a/asana/models/project_membership_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectMembershipResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectMembershipResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectMembershipResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this ProjectMembershipResponseData. # noqa: E501 - - - :return: The data of this ProjectMembershipResponseData. # noqa: E501 - :rtype: ProjectMembershipResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectMembershipResponseData. - - - :param data: The data of this ProjectMembershipResponseData. # noqa: E501 - :type: ProjectMembershipResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectMembershipResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectMembershipResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_membership_response_member.py b/asana/models/project_membership_response_member.py deleted file mode 100644 index 31048fb3..00000000 --- a/asana/models/project_membership_response_member.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectMembershipResponseMember(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """ProjectMembershipResponseMember - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this ProjectMembershipResponseMember. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectMembershipResponseMember. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectMembershipResponseMember. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectMembershipResponseMember. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectMembershipResponseMember. # noqa: E501 - - The type of the member (team or user) # noqa: E501 - - :return: The resource_type of this ProjectMembershipResponseMember. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectMembershipResponseMember. - - The type of the member (team or user) # noqa: E501 - - :param resource_type: The resource_type of this ProjectMembershipResponseMember. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectMembershipResponseMember. # noqa: E501 - - The name of the member # noqa: E501 - - :return: The name of this ProjectMembershipResponseMember. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectMembershipResponseMember. - - The name of the member # noqa: E501 - - :param name: The name of this ProjectMembershipResponseMember. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectMembershipResponseMember, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectMembershipResponseMember): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_request.py b/asana/models/project_request.py deleted file mode 100644 index 27bf7d89..00000000 --- a/asana/models/project_request.py +++ /dev/null @@ -1,838 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'archived': 'bool', - 'color': 'str', - 'created_at': 'datetime', - 'current_status': 'ProjectBaseCurrentStatus', - 'current_status_update': 'ProjectBaseCurrentStatusUpdate', - 'custom_field_settings': 'list[PortfolioResponseCustomFieldSettings]', - 'default_view': 'str', - 'due_date': 'date', - 'due_on': 'date', - 'html_notes': 'str', - 'members': 'list[CustomFieldResponsePeopleValue]', - 'modified_at': 'datetime', - 'notes': 'str', - 'public': 'bool', - 'start_on': 'date', - 'default_access_level': 'str', - 'minimum_access_level_for_customization': 'str', - 'minimum_access_level_for_sharing': 'str', - 'custom_fields': 'dict(str, str)', - 'followers': 'str', - 'owner': 'str', - 'team': 'str', - 'workspace': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'archived': 'archived', - 'color': 'color', - 'created_at': 'created_at', - 'current_status': 'current_status', - 'current_status_update': 'current_status_update', - 'custom_field_settings': 'custom_field_settings', - 'default_view': 'default_view', - 'due_date': 'due_date', - 'due_on': 'due_on', - 'html_notes': 'html_notes', - 'members': 'members', - 'modified_at': 'modified_at', - 'notes': 'notes', - 'public': 'public', - 'start_on': 'start_on', - 'default_access_level': 'default_access_level', - 'minimum_access_level_for_customization': 'minimum_access_level_for_customization', - 'minimum_access_level_for_sharing': 'minimum_access_level_for_sharing', - 'custom_fields': 'custom_fields', - 'followers': 'followers', - 'owner': 'owner', - 'team': 'team', - 'workspace': 'workspace' - } - - def __init__(self, gid=None, resource_type=None, name=None, archived=None, color=None, created_at=None, current_status=None, current_status_update=None, custom_field_settings=None, default_view=None, due_date=None, due_on=None, html_notes=None, members=None, modified_at=None, notes=None, public=None, start_on=None, default_access_level=None, minimum_access_level_for_customization=None, minimum_access_level_for_sharing=None, custom_fields=None, followers=None, owner=None, team=None, workspace=None): # noqa: E501 - """ProjectRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._archived = None - self._color = None - self._created_at = None - self._current_status = None - self._current_status_update = None - self._custom_field_settings = None - self._default_view = None - self._due_date = None - self._due_on = None - self._html_notes = None - self._members = None - self._modified_at = None - self._notes = None - self._public = None - self._start_on = None - self._default_access_level = None - self._minimum_access_level_for_customization = None - self._minimum_access_level_for_sharing = None - self._custom_fields = None - self._followers = None - self._owner = None - self._team = None - self._workspace = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if archived is not None: - self.archived = archived - if color is not None: - self.color = color - if created_at is not None: - self.created_at = created_at - if current_status is not None: - self.current_status = current_status - if current_status_update is not None: - self.current_status_update = current_status_update - if custom_field_settings is not None: - self.custom_field_settings = custom_field_settings - if default_view is not None: - self.default_view = default_view - if due_date is not None: - self.due_date = due_date - if due_on is not None: - self.due_on = due_on - if html_notes is not None: - self.html_notes = html_notes - if members is not None: - self.members = members - if modified_at is not None: - self.modified_at = modified_at - if notes is not None: - self.notes = notes - if public is not None: - self.public = public - if start_on is not None: - self.start_on = start_on - if default_access_level is not None: - self.default_access_level = default_access_level - if minimum_access_level_for_customization is not None: - self.minimum_access_level_for_customization = minimum_access_level_for_customization - if minimum_access_level_for_sharing is not None: - self.minimum_access_level_for_sharing = minimum_access_level_for_sharing - if custom_fields is not None: - self.custom_fields = custom_fields - if followers is not None: - self.followers = followers - if owner is not None: - self.owner = owner - if team is not None: - self.team = team - if workspace is not None: - self.workspace = workspace - - @property - def gid(self): - """Gets the gid of this ProjectRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectRequest. # noqa: E501 - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectRequest. - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this ProjectRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def archived(self): - """Gets the archived of this ProjectRequest. # noqa: E501 - - True if the project is archived, false if not. Archived projects do not show in the UI by default and may be treated differently for queries. # noqa: E501 - - :return: The archived of this ProjectRequest. # noqa: E501 - :rtype: bool - """ - return self._archived - - @archived.setter - def archived(self, archived): - """Sets the archived of this ProjectRequest. - - True if the project is archived, false if not. Archived projects do not show in the UI by default and may be treated differently for queries. # noqa: E501 - - :param archived: The archived of this ProjectRequest. # noqa: E501 - :type: bool - """ - - self._archived = archived - - @property - def color(self): - """Gets the color of this ProjectRequest. # noqa: E501 - - Color of the project. # noqa: E501 - - :return: The color of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this ProjectRequest. - - Color of the project. # noqa: E501 - - :param color: The color of this ProjectRequest. # noqa: E501 - :type: str - """ - allowed_values = ["dark-pink", "dark-green", "dark-blue", "dark-red", "dark-teal", "dark-brown", "dark-orange", "dark-purple", "dark-warm-gray", "light-pink", "light-green", "light-blue", "light-red", "light-teal", "light-brown", "light-orange", "light-purple", "light-warm-gray", "none", ""] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def created_at(self): - """Gets the created_at of this ProjectRequest. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this ProjectRequest. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this ProjectRequest. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this ProjectRequest. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def current_status(self): - """Gets the current_status of this ProjectRequest. # noqa: E501 - - - :return: The current_status of this ProjectRequest. # noqa: E501 - :rtype: ProjectBaseCurrentStatus - """ - return self._current_status - - @current_status.setter - def current_status(self, current_status): - """Sets the current_status of this ProjectRequest. - - - :param current_status: The current_status of this ProjectRequest. # noqa: E501 - :type: ProjectBaseCurrentStatus - """ - - self._current_status = current_status - - @property - def current_status_update(self): - """Gets the current_status_update of this ProjectRequest. # noqa: E501 - - - :return: The current_status_update of this ProjectRequest. # noqa: E501 - :rtype: ProjectBaseCurrentStatusUpdate - """ - return self._current_status_update - - @current_status_update.setter - def current_status_update(self, current_status_update): - """Sets the current_status_update of this ProjectRequest. - - - :param current_status_update: The current_status_update of this ProjectRequest. # noqa: E501 - :type: ProjectBaseCurrentStatusUpdate - """ - - self._current_status_update = current_status_update - - @property - def custom_field_settings(self): - """Gets the custom_field_settings of this ProjectRequest. # noqa: E501 - - Array of Custom Field Settings (in compact form). # noqa: E501 - - :return: The custom_field_settings of this ProjectRequest. # noqa: E501 - :rtype: list[PortfolioResponseCustomFieldSettings] - """ - return self._custom_field_settings - - @custom_field_settings.setter - def custom_field_settings(self, custom_field_settings): - """Sets the custom_field_settings of this ProjectRequest. - - Array of Custom Field Settings (in compact form). # noqa: E501 - - :param custom_field_settings: The custom_field_settings of this ProjectRequest. # noqa: E501 - :type: list[PortfolioResponseCustomFieldSettings] - """ - - self._custom_field_settings = custom_field_settings - - @property - def default_view(self): - """Gets the default_view of this ProjectRequest. # noqa: E501 - - The default view (list, board, calendar, or timeline) of a project. # noqa: E501 - - :return: The default_view of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._default_view - - @default_view.setter - def default_view(self, default_view): - """Sets the default_view of this ProjectRequest. - - The default view (list, board, calendar, or timeline) of a project. # noqa: E501 - - :param default_view: The default_view of this ProjectRequest. # noqa: E501 - :type: str - """ - allowed_values = ["list", "board", "calendar", "timeline"] # noqa: E501 - if default_view not in allowed_values: - raise ValueError( - "Invalid value for `default_view` ({0}), must be one of {1}" # noqa: E501 - .format(default_view, allowed_values) - ) - - self._default_view = default_view - - @property - def due_date(self): - """Gets the due_date of this ProjectRequest. # noqa: E501 - - *Deprecated: new integrations should prefer the `due_on` field.* # noqa: E501 - - :return: The due_date of this ProjectRequest. # noqa: E501 - :rtype: date - """ - return self._due_date - - @due_date.setter - def due_date(self, due_date): - """Sets the due_date of this ProjectRequest. - - *Deprecated: new integrations should prefer the `due_on` field.* # noqa: E501 - - :param due_date: The due_date of this ProjectRequest. # noqa: E501 - :type: date - """ - - self._due_date = due_date - - @property - def due_on(self): - """Gets the due_on of this ProjectRequest. # noqa: E501 - - The day on which this project is due. This takes a date with format YYYY-MM-DD. # noqa: E501 - - :return: The due_on of this ProjectRequest. # noqa: E501 - :rtype: date - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this ProjectRequest. - - The day on which this project is due. This takes a date with format YYYY-MM-DD. # noqa: E501 - - :param due_on: The due_on of this ProjectRequest. # noqa: E501 - :type: date - """ - - self._due_on = due_on - - @property - def html_notes(self): - """Gets the html_notes of this ProjectRequest. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The notes of the project with formatting as HTML. # noqa: E501 - - :return: The html_notes of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._html_notes - - @html_notes.setter - def html_notes(self, html_notes): - """Sets the html_notes of this ProjectRequest. - - [Opt In](/docs/inputoutput-options). The notes of the project with formatting as HTML. # noqa: E501 - - :param html_notes: The html_notes of this ProjectRequest. # noqa: E501 - :type: str - """ - - self._html_notes = html_notes - - @property - def members(self): - """Gets the members of this ProjectRequest. # noqa: E501 - - Array of users who are members of this project. # noqa: E501 - - :return: The members of this ProjectRequest. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._members - - @members.setter - def members(self, members): - """Sets the members of this ProjectRequest. - - Array of users who are members of this project. # noqa: E501 - - :param members: The members of this ProjectRequest. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._members = members - - @property - def modified_at(self): - """Gets the modified_at of this ProjectRequest. # noqa: E501 - - The time at which this project was last modified. *Note: This does not currently reflect any changes in associations such as tasks or comments that may have been added or removed from the project.* # noqa: E501 - - :return: The modified_at of this ProjectRequest. # noqa: E501 - :rtype: datetime - """ - return self._modified_at - - @modified_at.setter - def modified_at(self, modified_at): - """Sets the modified_at of this ProjectRequest. - - The time at which this project was last modified. *Note: This does not currently reflect any changes in associations such as tasks or comments that may have been added or removed from the project.* # noqa: E501 - - :param modified_at: The modified_at of this ProjectRequest. # noqa: E501 - :type: datetime - """ - - self._modified_at = modified_at - - @property - def notes(self): - """Gets the notes of this ProjectRequest. # noqa: E501 - - Free-form textual information associated with the project (ie., its description). # noqa: E501 - - :return: The notes of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this ProjectRequest. - - Free-form textual information associated with the project (ie., its description). # noqa: E501 - - :param notes: The notes of this ProjectRequest. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def public(self): - """Gets the public of this ProjectRequest. # noqa: E501 - - True if the project is public to its team. # noqa: E501 - - :return: The public of this ProjectRequest. # noqa: E501 - :rtype: bool - """ - return self._public - - @public.setter - def public(self, public): - """Sets the public of this ProjectRequest. - - True if the project is public to its team. # noqa: E501 - - :param public: The public of this ProjectRequest. # noqa: E501 - :type: bool - """ - - self._public = public - - @property - def start_on(self): - """Gets the start_on of this ProjectRequest. # noqa: E501 - - The day on which work for this project begins, or null if the project has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* # noqa: E501 - - :return: The start_on of this ProjectRequest. # noqa: E501 - :rtype: date - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this ProjectRequest. - - The day on which work for this project begins, or null if the project has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* # noqa: E501 - - :param start_on: The start_on of this ProjectRequest. # noqa: E501 - :type: date - """ - - self._start_on = start_on - - @property - def default_access_level(self): - """Gets the default_access_level of this ProjectRequest. # noqa: E501 - - The default access for users or teams who join or are added as members to the project. # noqa: E501 - - :return: The default_access_level of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._default_access_level - - @default_access_level.setter - def default_access_level(self, default_access_level): - """Sets the default_access_level of this ProjectRequest. - - The default access for users or teams who join or are added as members to the project. # noqa: E501 - - :param default_access_level: The default_access_level of this ProjectRequest. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor", "commenter", "viewer"] # noqa: E501 - if default_access_level not in allowed_values: - raise ValueError( - "Invalid value for `default_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(default_access_level, allowed_values) - ) - - self._default_access_level = default_access_level - - @property - def minimum_access_level_for_customization(self): - """Gets the minimum_access_level_for_customization of this ProjectRequest. # noqa: E501 - - The minimum access level needed for project members to modify this project's workflow and appearance. # noqa: E501 - - :return: The minimum_access_level_for_customization of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._minimum_access_level_for_customization - - @minimum_access_level_for_customization.setter - def minimum_access_level_for_customization(self, minimum_access_level_for_customization): - """Sets the minimum_access_level_for_customization of this ProjectRequest. - - The minimum access level needed for project members to modify this project's workflow and appearance. # noqa: E501 - - :param minimum_access_level_for_customization: The minimum_access_level_for_customization of this ProjectRequest. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor"] # noqa: E501 - if minimum_access_level_for_customization not in allowed_values: - raise ValueError( - "Invalid value for `minimum_access_level_for_customization` ({0}), must be one of {1}" # noqa: E501 - .format(minimum_access_level_for_customization, allowed_values) - ) - - self._minimum_access_level_for_customization = minimum_access_level_for_customization - - @property - def minimum_access_level_for_sharing(self): - """Gets the minimum_access_level_for_sharing of this ProjectRequest. # noqa: E501 - - The minimum access level needed for project members to share the project and manage project memberships. # noqa: E501 - - :return: The minimum_access_level_for_sharing of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._minimum_access_level_for_sharing - - @minimum_access_level_for_sharing.setter - def minimum_access_level_for_sharing(self, minimum_access_level_for_sharing): - """Sets the minimum_access_level_for_sharing of this ProjectRequest. - - The minimum access level needed for project members to share the project and manage project memberships. # noqa: E501 - - :param minimum_access_level_for_sharing: The minimum_access_level_for_sharing of this ProjectRequest. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor"] # noqa: E501 - if minimum_access_level_for_sharing not in allowed_values: - raise ValueError( - "Invalid value for `minimum_access_level_for_sharing` ({0}), must be one of {1}" # noqa: E501 - .format(minimum_access_level_for_sharing, allowed_values) - ) - - self._minimum_access_level_for_sharing = minimum_access_level_for_sharing - - @property - def custom_fields(self): - """Gets the custom_fields of this ProjectRequest. # noqa: E501 - - An object where each key is the GID of a custom field and its corresponding value is either an enum GID, string, number, or object (depending on the custom field type). See the [custom fields guide](/docs/custom-fields-guide) for details on creating and updating custom field values. # noqa: E501 - - :return: The custom_fields of this ProjectRequest. # noqa: E501 - :rtype: dict(str, str) - """ - return self._custom_fields - - @custom_fields.setter - def custom_fields(self, custom_fields): - """Sets the custom_fields of this ProjectRequest. - - An object where each key is the GID of a custom field and its corresponding value is either an enum GID, string, number, or object (depending on the custom field type). See the [custom fields guide](/docs/custom-fields-guide) for details on creating and updating custom field values. # noqa: E501 - - :param custom_fields: The custom_fields of this ProjectRequest. # noqa: E501 - :type: dict(str, str) - """ - - self._custom_fields = custom_fields - - @property - def followers(self): - """Gets the followers of this ProjectRequest. # noqa: E501 - - *Create-only*. Comma separated string of users. Followers are a subset of members who have opted in to receive \"tasks added\" notifications for a project. # noqa: E501 - - :return: The followers of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this ProjectRequest. - - *Create-only*. Comma separated string of users. Followers are a subset of members who have opted in to receive \"tasks added\" notifications for a project. # noqa: E501 - - :param followers: The followers of this ProjectRequest. # noqa: E501 - :type: str - """ - - self._followers = followers - - @property - def owner(self): - """Gets the owner of this ProjectRequest. # noqa: E501 - - The current owner of the project, may be null. # noqa: E501 - - :return: The owner of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this ProjectRequest. - - The current owner of the project, may be null. # noqa: E501 - - :param owner: The owner of this ProjectRequest. # noqa: E501 - :type: str - """ - - self._owner = owner - - @property - def team(self): - """Gets the team of this ProjectRequest. # noqa: E501 - - The team that this project is shared with. # noqa: E501 - - :return: The team of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this ProjectRequest. - - The team that this project is shared with. # noqa: E501 - - :param team: The team of this ProjectRequest. # noqa: E501 - :type: str - """ - - self._team = team - - @property - def workspace(self): - """Gets the workspace of this ProjectRequest. # noqa: E501 - - The `gid` of a workspace. # noqa: E501 - - :return: The workspace of this ProjectRequest. # noqa: E501 - :rtype: str - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this ProjectRequest. - - The `gid` of a workspace. # noqa: E501 - - :param workspace: The workspace of this ProjectRequest. # noqa: E501 - :type: str - """ - - self._workspace = workspace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_response.py b/asana/models/project_response.py deleted file mode 100644 index dfa733bc..00000000 --- a/asana/models/project_response.py +++ /dev/null @@ -1,1030 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'archived': 'bool', - 'color': 'str', - 'created_at': 'datetime', - 'current_status': 'ProjectBaseCurrentStatus', - 'current_status_update': 'ProjectBaseCurrentStatusUpdate', - 'custom_field_settings': 'list[PortfolioResponseCustomFieldSettings]', - 'default_view': 'str', - 'due_date': 'date', - 'due_on': 'date', - 'html_notes': 'str', - 'members': 'list[CustomFieldResponsePeopleValue]', - 'modified_at': 'datetime', - 'notes': 'str', - 'public': 'bool', - 'start_on': 'date', - 'default_access_level': 'str', - 'minimum_access_level_for_customization': 'str', - 'minimum_access_level_for_sharing': 'str', - 'custom_fields': 'list[PortfolioResponseCustomFields]', - 'completed': 'bool', - 'completed_at': 'datetime', - 'completed_by': 'ProjectResponseCompletedBy', - 'followers': 'list[CustomFieldResponsePeopleValue]', - 'owner': 'AllOfProjectResponseOwner', - 'team': 'ProjectResponseTeam', - 'icon': 'str', - 'permalink_url': 'str', - 'project_brief': 'ProjectResponseProjectBrief', - 'created_from_template': 'ProjectResponseCreatedFromTemplate', - 'workspace': 'ProjectResponseWorkspace' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'archived': 'archived', - 'color': 'color', - 'created_at': 'created_at', - 'current_status': 'current_status', - 'current_status_update': 'current_status_update', - 'custom_field_settings': 'custom_field_settings', - 'default_view': 'default_view', - 'due_date': 'due_date', - 'due_on': 'due_on', - 'html_notes': 'html_notes', - 'members': 'members', - 'modified_at': 'modified_at', - 'notes': 'notes', - 'public': 'public', - 'start_on': 'start_on', - 'default_access_level': 'default_access_level', - 'minimum_access_level_for_customization': 'minimum_access_level_for_customization', - 'minimum_access_level_for_sharing': 'minimum_access_level_for_sharing', - 'custom_fields': 'custom_fields', - 'completed': 'completed', - 'completed_at': 'completed_at', - 'completed_by': 'completed_by', - 'followers': 'followers', - 'owner': 'owner', - 'team': 'team', - 'icon': 'icon', - 'permalink_url': 'permalink_url', - 'project_brief': 'project_brief', - 'created_from_template': 'created_from_template', - 'workspace': 'workspace' - } - - def __init__(self, gid=None, resource_type=None, name=None, archived=None, color=None, created_at=None, current_status=None, current_status_update=None, custom_field_settings=None, default_view=None, due_date=None, due_on=None, html_notes=None, members=None, modified_at=None, notes=None, public=None, start_on=None, default_access_level=None, minimum_access_level_for_customization=None, minimum_access_level_for_sharing=None, custom_fields=None, completed=None, completed_at=None, completed_by=None, followers=None, owner=None, team=None, icon=None, permalink_url=None, project_brief=None, created_from_template=None, workspace=None): # noqa: E501 - """ProjectResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._archived = None - self._color = None - self._created_at = None - self._current_status = None - self._current_status_update = None - self._custom_field_settings = None - self._default_view = None - self._due_date = None - self._due_on = None - self._html_notes = None - self._members = None - self._modified_at = None - self._notes = None - self._public = None - self._start_on = None - self._default_access_level = None - self._minimum_access_level_for_customization = None - self._minimum_access_level_for_sharing = None - self._custom_fields = None - self._completed = None - self._completed_at = None - self._completed_by = None - self._followers = None - self._owner = None - self._team = None - self._icon = None - self._permalink_url = None - self._project_brief = None - self._created_from_template = None - self._workspace = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if archived is not None: - self.archived = archived - if color is not None: - self.color = color - if created_at is not None: - self.created_at = created_at - if current_status is not None: - self.current_status = current_status - if current_status_update is not None: - self.current_status_update = current_status_update - if custom_field_settings is not None: - self.custom_field_settings = custom_field_settings - if default_view is not None: - self.default_view = default_view - if due_date is not None: - self.due_date = due_date - if due_on is not None: - self.due_on = due_on - if html_notes is not None: - self.html_notes = html_notes - if members is not None: - self.members = members - if modified_at is not None: - self.modified_at = modified_at - if notes is not None: - self.notes = notes - if public is not None: - self.public = public - if start_on is not None: - self.start_on = start_on - if default_access_level is not None: - self.default_access_level = default_access_level - if minimum_access_level_for_customization is not None: - self.minimum_access_level_for_customization = minimum_access_level_for_customization - if minimum_access_level_for_sharing is not None: - self.minimum_access_level_for_sharing = minimum_access_level_for_sharing - if custom_fields is not None: - self.custom_fields = custom_fields - if completed is not None: - self.completed = completed - if completed_at is not None: - self.completed_at = completed_at - if completed_by is not None: - self.completed_by = completed_by - if followers is not None: - self.followers = followers - if owner is not None: - self.owner = owner - if team is not None: - self.team = team - if icon is not None: - self.icon = icon - if permalink_url is not None: - self.permalink_url = permalink_url - if project_brief is not None: - self.project_brief = project_brief - if created_from_template is not None: - self.created_from_template = created_from_template - if workspace is not None: - self.workspace = workspace - - @property - def gid(self): - """Gets the gid of this ProjectResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectResponse. # noqa: E501 - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this ProjectResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectResponse. - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this ProjectResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def archived(self): - """Gets the archived of this ProjectResponse. # noqa: E501 - - True if the project is archived, false if not. Archived projects do not show in the UI by default and may be treated differently for queries. # noqa: E501 - - :return: The archived of this ProjectResponse. # noqa: E501 - :rtype: bool - """ - return self._archived - - @archived.setter - def archived(self, archived): - """Sets the archived of this ProjectResponse. - - True if the project is archived, false if not. Archived projects do not show in the UI by default and may be treated differently for queries. # noqa: E501 - - :param archived: The archived of this ProjectResponse. # noqa: E501 - :type: bool - """ - - self._archived = archived - - @property - def color(self): - """Gets the color of this ProjectResponse. # noqa: E501 - - Color of the project. # noqa: E501 - - :return: The color of this ProjectResponse. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this ProjectResponse. - - Color of the project. # noqa: E501 - - :param color: The color of this ProjectResponse. # noqa: E501 - :type: str - """ - allowed_values = ["dark-pink", "dark-green", "dark-blue", "dark-red", "dark-teal", "dark-brown", "dark-orange", "dark-purple", "dark-warm-gray", "light-pink", "light-green", "light-blue", "light-red", "light-teal", "light-brown", "light-orange", "light-purple", "light-warm-gray", "none", ""] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def created_at(self): - """Gets the created_at of this ProjectResponse. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this ProjectResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this ProjectResponse. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this ProjectResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def current_status(self): - """Gets the current_status of this ProjectResponse. # noqa: E501 - - - :return: The current_status of this ProjectResponse. # noqa: E501 - :rtype: ProjectBaseCurrentStatus - """ - return self._current_status - - @current_status.setter - def current_status(self, current_status): - """Sets the current_status of this ProjectResponse. - - - :param current_status: The current_status of this ProjectResponse. # noqa: E501 - :type: ProjectBaseCurrentStatus - """ - - self._current_status = current_status - - @property - def current_status_update(self): - """Gets the current_status_update of this ProjectResponse. # noqa: E501 - - - :return: The current_status_update of this ProjectResponse. # noqa: E501 - :rtype: ProjectBaseCurrentStatusUpdate - """ - return self._current_status_update - - @current_status_update.setter - def current_status_update(self, current_status_update): - """Sets the current_status_update of this ProjectResponse. - - - :param current_status_update: The current_status_update of this ProjectResponse. # noqa: E501 - :type: ProjectBaseCurrentStatusUpdate - """ - - self._current_status_update = current_status_update - - @property - def custom_field_settings(self): - """Gets the custom_field_settings of this ProjectResponse. # noqa: E501 - - Array of Custom Field Settings (in compact form). # noqa: E501 - - :return: The custom_field_settings of this ProjectResponse. # noqa: E501 - :rtype: list[PortfolioResponseCustomFieldSettings] - """ - return self._custom_field_settings - - @custom_field_settings.setter - def custom_field_settings(self, custom_field_settings): - """Sets the custom_field_settings of this ProjectResponse. - - Array of Custom Field Settings (in compact form). # noqa: E501 - - :param custom_field_settings: The custom_field_settings of this ProjectResponse. # noqa: E501 - :type: list[PortfolioResponseCustomFieldSettings] - """ - - self._custom_field_settings = custom_field_settings - - @property - def default_view(self): - """Gets the default_view of this ProjectResponse. # noqa: E501 - - The default view (list, board, calendar, or timeline) of a project. # noqa: E501 - - :return: The default_view of this ProjectResponse. # noqa: E501 - :rtype: str - """ - return self._default_view - - @default_view.setter - def default_view(self, default_view): - """Sets the default_view of this ProjectResponse. - - The default view (list, board, calendar, or timeline) of a project. # noqa: E501 - - :param default_view: The default_view of this ProjectResponse. # noqa: E501 - :type: str - """ - allowed_values = ["list", "board", "calendar", "timeline"] # noqa: E501 - if default_view not in allowed_values: - raise ValueError( - "Invalid value for `default_view` ({0}), must be one of {1}" # noqa: E501 - .format(default_view, allowed_values) - ) - - self._default_view = default_view - - @property - def due_date(self): - """Gets the due_date of this ProjectResponse. # noqa: E501 - - *Deprecated: new integrations should prefer the `due_on` field.* # noqa: E501 - - :return: The due_date of this ProjectResponse. # noqa: E501 - :rtype: date - """ - return self._due_date - - @due_date.setter - def due_date(self, due_date): - """Sets the due_date of this ProjectResponse. - - *Deprecated: new integrations should prefer the `due_on` field.* # noqa: E501 - - :param due_date: The due_date of this ProjectResponse. # noqa: E501 - :type: date - """ - - self._due_date = due_date - - @property - def due_on(self): - """Gets the due_on of this ProjectResponse. # noqa: E501 - - The day on which this project is due. This takes a date with format YYYY-MM-DD. # noqa: E501 - - :return: The due_on of this ProjectResponse. # noqa: E501 - :rtype: date - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this ProjectResponse. - - The day on which this project is due. This takes a date with format YYYY-MM-DD. # noqa: E501 - - :param due_on: The due_on of this ProjectResponse. # noqa: E501 - :type: date - """ - - self._due_on = due_on - - @property - def html_notes(self): - """Gets the html_notes of this ProjectResponse. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The notes of the project with formatting as HTML. # noqa: E501 - - :return: The html_notes of this ProjectResponse. # noqa: E501 - :rtype: str - """ - return self._html_notes - - @html_notes.setter - def html_notes(self, html_notes): - """Sets the html_notes of this ProjectResponse. - - [Opt In](/docs/inputoutput-options). The notes of the project with formatting as HTML. # noqa: E501 - - :param html_notes: The html_notes of this ProjectResponse. # noqa: E501 - :type: str - """ - - self._html_notes = html_notes - - @property - def members(self): - """Gets the members of this ProjectResponse. # noqa: E501 - - Array of users who are members of this project. # noqa: E501 - - :return: The members of this ProjectResponse. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._members - - @members.setter - def members(self, members): - """Sets the members of this ProjectResponse. - - Array of users who are members of this project. # noqa: E501 - - :param members: The members of this ProjectResponse. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._members = members - - @property - def modified_at(self): - """Gets the modified_at of this ProjectResponse. # noqa: E501 - - The time at which this project was last modified. *Note: This does not currently reflect any changes in associations such as tasks or comments that may have been added or removed from the project.* # noqa: E501 - - :return: The modified_at of this ProjectResponse. # noqa: E501 - :rtype: datetime - """ - return self._modified_at - - @modified_at.setter - def modified_at(self, modified_at): - """Sets the modified_at of this ProjectResponse. - - The time at which this project was last modified. *Note: This does not currently reflect any changes in associations such as tasks or comments that may have been added or removed from the project.* # noqa: E501 - - :param modified_at: The modified_at of this ProjectResponse. # noqa: E501 - :type: datetime - """ - - self._modified_at = modified_at - - @property - def notes(self): - """Gets the notes of this ProjectResponse. # noqa: E501 - - Free-form textual information associated with the project (ie., its description). # noqa: E501 - - :return: The notes of this ProjectResponse. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this ProjectResponse. - - Free-form textual information associated with the project (ie., its description). # noqa: E501 - - :param notes: The notes of this ProjectResponse. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def public(self): - """Gets the public of this ProjectResponse. # noqa: E501 - - True if the project is public to its team. # noqa: E501 - - :return: The public of this ProjectResponse. # noqa: E501 - :rtype: bool - """ - return self._public - - @public.setter - def public(self, public): - """Sets the public of this ProjectResponse. - - True if the project is public to its team. # noqa: E501 - - :param public: The public of this ProjectResponse. # noqa: E501 - :type: bool - """ - - self._public = public - - @property - def start_on(self): - """Gets the start_on of this ProjectResponse. # noqa: E501 - - The day on which work for this project begins, or null if the project has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* # noqa: E501 - - :return: The start_on of this ProjectResponse. # noqa: E501 - :rtype: date - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this ProjectResponse. - - The day on which work for this project begins, or null if the project has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* # noqa: E501 - - :param start_on: The start_on of this ProjectResponse. # noqa: E501 - :type: date - """ - - self._start_on = start_on - - @property - def default_access_level(self): - """Gets the default_access_level of this ProjectResponse. # noqa: E501 - - The default access for users or teams who join or are added as members to the project. # noqa: E501 - - :return: The default_access_level of this ProjectResponse. # noqa: E501 - :rtype: str - """ - return self._default_access_level - - @default_access_level.setter - def default_access_level(self, default_access_level): - """Sets the default_access_level of this ProjectResponse. - - The default access for users or teams who join or are added as members to the project. # noqa: E501 - - :param default_access_level: The default_access_level of this ProjectResponse. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor", "commenter", "viewer"] # noqa: E501 - if default_access_level not in allowed_values: - raise ValueError( - "Invalid value for `default_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(default_access_level, allowed_values) - ) - - self._default_access_level = default_access_level - - @property - def minimum_access_level_for_customization(self): - """Gets the minimum_access_level_for_customization of this ProjectResponse. # noqa: E501 - - The minimum access level needed for project members to modify this project's workflow and appearance. # noqa: E501 - - :return: The minimum_access_level_for_customization of this ProjectResponse. # noqa: E501 - :rtype: str - """ - return self._minimum_access_level_for_customization - - @minimum_access_level_for_customization.setter - def minimum_access_level_for_customization(self, minimum_access_level_for_customization): - """Sets the minimum_access_level_for_customization of this ProjectResponse. - - The minimum access level needed for project members to modify this project's workflow and appearance. # noqa: E501 - - :param minimum_access_level_for_customization: The minimum_access_level_for_customization of this ProjectResponse. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor"] # noqa: E501 - if minimum_access_level_for_customization not in allowed_values: - raise ValueError( - "Invalid value for `minimum_access_level_for_customization` ({0}), must be one of {1}" # noqa: E501 - .format(minimum_access_level_for_customization, allowed_values) - ) - - self._minimum_access_level_for_customization = minimum_access_level_for_customization - - @property - def minimum_access_level_for_sharing(self): - """Gets the minimum_access_level_for_sharing of this ProjectResponse. # noqa: E501 - - The minimum access level needed for project members to share the project and manage project memberships. # noqa: E501 - - :return: The minimum_access_level_for_sharing of this ProjectResponse. # noqa: E501 - :rtype: str - """ - return self._minimum_access_level_for_sharing - - @minimum_access_level_for_sharing.setter - def minimum_access_level_for_sharing(self, minimum_access_level_for_sharing): - """Sets the minimum_access_level_for_sharing of this ProjectResponse. - - The minimum access level needed for project members to share the project and manage project memberships. # noqa: E501 - - :param minimum_access_level_for_sharing: The minimum_access_level_for_sharing of this ProjectResponse. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor"] # noqa: E501 - if minimum_access_level_for_sharing not in allowed_values: - raise ValueError( - "Invalid value for `minimum_access_level_for_sharing` ({0}), must be one of {1}" # noqa: E501 - .format(minimum_access_level_for_sharing, allowed_values) - ) - - self._minimum_access_level_for_sharing = minimum_access_level_for_sharing - - @property - def custom_fields(self): - """Gets the custom_fields of this ProjectResponse. # noqa: E501 - - Array of Custom Fields. # noqa: E501 - - :return: The custom_fields of this ProjectResponse. # noqa: E501 - :rtype: list[PortfolioResponseCustomFields] - """ - return self._custom_fields - - @custom_fields.setter - def custom_fields(self, custom_fields): - """Sets the custom_fields of this ProjectResponse. - - Array of Custom Fields. # noqa: E501 - - :param custom_fields: The custom_fields of this ProjectResponse. # noqa: E501 - :type: list[PortfolioResponseCustomFields] - """ - - self._custom_fields = custom_fields - - @property - def completed(self): - """Gets the completed of this ProjectResponse. # noqa: E501 - - True if the project is currently marked complete, false if not. # noqa: E501 - - :return: The completed of this ProjectResponse. # noqa: E501 - :rtype: bool - """ - return self._completed - - @completed.setter - def completed(self, completed): - """Sets the completed of this ProjectResponse. - - True if the project is currently marked complete, false if not. # noqa: E501 - - :param completed: The completed of this ProjectResponse. # noqa: E501 - :type: bool - """ - - self._completed = completed - - @property - def completed_at(self): - """Gets the completed_at of this ProjectResponse. # noqa: E501 - - The time at which this project was completed, or null if the project is not completed. # noqa: E501 - - :return: The completed_at of this ProjectResponse. # noqa: E501 - :rtype: datetime - """ - return self._completed_at - - @completed_at.setter - def completed_at(self, completed_at): - """Sets the completed_at of this ProjectResponse. - - The time at which this project was completed, or null if the project is not completed. # noqa: E501 - - :param completed_at: The completed_at of this ProjectResponse. # noqa: E501 - :type: datetime - """ - - self._completed_at = completed_at - - @property - def completed_by(self): - """Gets the completed_by of this ProjectResponse. # noqa: E501 - - - :return: The completed_by of this ProjectResponse. # noqa: E501 - :rtype: ProjectResponseCompletedBy - """ - return self._completed_by - - @completed_by.setter - def completed_by(self, completed_by): - """Sets the completed_by of this ProjectResponse. - - - :param completed_by: The completed_by of this ProjectResponse. # noqa: E501 - :type: ProjectResponseCompletedBy - """ - - self._completed_by = completed_by - - @property - def followers(self): - """Gets the followers of this ProjectResponse. # noqa: E501 - - Array of users following this project. Followers are a subset of members who have opted in to receive \"tasks added\" notifications for a project. # noqa: E501 - - :return: The followers of this ProjectResponse. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this ProjectResponse. - - Array of users following this project. Followers are a subset of members who have opted in to receive \"tasks added\" notifications for a project. # noqa: E501 - - :param followers: The followers of this ProjectResponse. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._followers = followers - - @property - def owner(self): - """Gets the owner of this ProjectResponse. # noqa: E501 - - The current owner of the project, may be null. # noqa: E501 - - :return: The owner of this ProjectResponse. # noqa: E501 - :rtype: AllOfProjectResponseOwner - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this ProjectResponse. - - The current owner of the project, may be null. # noqa: E501 - - :param owner: The owner of this ProjectResponse. # noqa: E501 - :type: AllOfProjectResponseOwner - """ - - self._owner = owner - - @property - def team(self): - """Gets the team of this ProjectResponse. # noqa: E501 - - - :return: The team of this ProjectResponse. # noqa: E501 - :rtype: ProjectResponseTeam - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this ProjectResponse. - - - :param team: The team of this ProjectResponse. # noqa: E501 - :type: ProjectResponseTeam - """ - - self._team = team - - @property - def icon(self): - """Gets the icon of this ProjectResponse. # noqa: E501 - - The icon for a project. # noqa: E501 - - :return: The icon of this ProjectResponse. # noqa: E501 - :rtype: str - """ - return self._icon - - @icon.setter - def icon(self, icon): - """Sets the icon of this ProjectResponse. - - The icon for a project. # noqa: E501 - - :param icon: The icon of this ProjectResponse. # noqa: E501 - :type: str - """ - allowed_values = ["list", "board", "timeline", "calendar", "rocket", "people", "graph", "star", "bug", "light_bulb", "globe", "gear", "notebook", "computer", "check", "target", "html", "megaphone", "chat_bubbles", "briefcase", "page_layout", "mountain_flag", "puzzle", "presentation", "line_and_symbols", "speed_dial", "ribbon", "shoe", "shopping_basket", "map", "ticket", "coins"] # noqa: E501 - if icon not in allowed_values: - raise ValueError( - "Invalid value for `icon` ({0}), must be one of {1}" # noqa: E501 - .format(icon, allowed_values) - ) - - self._icon = icon - - @property - def permalink_url(self): - """Gets the permalink_url of this ProjectResponse. # noqa: E501 - - A url that points directly to the object within Asana. # noqa: E501 - - :return: The permalink_url of this ProjectResponse. # noqa: E501 - :rtype: str - """ - return self._permalink_url - - @permalink_url.setter - def permalink_url(self, permalink_url): - """Sets the permalink_url of this ProjectResponse. - - A url that points directly to the object within Asana. # noqa: E501 - - :param permalink_url: The permalink_url of this ProjectResponse. # noqa: E501 - :type: str - """ - - self._permalink_url = permalink_url - - @property - def project_brief(self): - """Gets the project_brief of this ProjectResponse. # noqa: E501 - - - :return: The project_brief of this ProjectResponse. # noqa: E501 - :rtype: ProjectResponseProjectBrief - """ - return self._project_brief - - @project_brief.setter - def project_brief(self, project_brief): - """Sets the project_brief of this ProjectResponse. - - - :param project_brief: The project_brief of this ProjectResponse. # noqa: E501 - :type: ProjectResponseProjectBrief - """ - - self._project_brief = project_brief - - @property - def created_from_template(self): - """Gets the created_from_template of this ProjectResponse. # noqa: E501 - - - :return: The created_from_template of this ProjectResponse. # noqa: E501 - :rtype: ProjectResponseCreatedFromTemplate - """ - return self._created_from_template - - @created_from_template.setter - def created_from_template(self, created_from_template): - """Sets the created_from_template of this ProjectResponse. - - - :param created_from_template: The created_from_template of this ProjectResponse. # noqa: E501 - :type: ProjectResponseCreatedFromTemplate - """ - - self._created_from_template = created_from_template - - @property - def workspace(self): - """Gets the workspace of this ProjectResponse. # noqa: E501 - - - :return: The workspace of this ProjectResponse. # noqa: E501 - :rtype: ProjectResponseWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this ProjectResponse. - - - :param workspace: The workspace of this ProjectResponse. # noqa: E501 - :type: ProjectResponseWorkspace - """ - - self._workspace = workspace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_response_array.py b/asana/models/project_response_array.py deleted file mode 100644 index 3feeeee4..00000000 --- a/asana/models/project_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[ProjectResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """ProjectResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this ProjectResponseArray. # noqa: E501 - - - :return: The data of this ProjectResponseArray. # noqa: E501 - :rtype: list[ProjectResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectResponseArray. - - - :param data: The data of this ProjectResponseArray. # noqa: E501 - :type: list[ProjectResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this ProjectResponseArray. # noqa: E501 - - - :return: The next_page of this ProjectResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this ProjectResponseArray. - - - :param next_page: The next_page of this ProjectResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_response_completed_by.py b/asana/models/project_response_completed_by.py deleted file mode 100644 index 966647e3..00000000 --- a/asana/models/project_response_completed_by.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectResponseCompletedBy(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """ProjectResponseCompletedBy - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this ProjectResponseCompletedBy. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectResponseCompletedBy. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectResponseCompletedBy. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectResponseCompletedBy. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectResponseCompletedBy. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectResponseCompletedBy. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectResponseCompletedBy. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectResponseCompletedBy. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectResponseCompletedBy. # noqa: E501 - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :return: The name of this ProjectResponseCompletedBy. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectResponseCompletedBy. - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :param name: The name of this ProjectResponseCompletedBy. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectResponseCompletedBy, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectResponseCompletedBy): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_response_created_from_template.py b/asana/models/project_response_created_from_template.py deleted file mode 100644 index 963e2bf3..00000000 --- a/asana/models/project_response_created_from_template.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectResponseCreatedFromTemplate(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """ProjectResponseCreatedFromTemplate - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this ProjectResponseCreatedFromTemplate. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectResponseCreatedFromTemplate. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectResponseCreatedFromTemplate. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectResponseCreatedFromTemplate. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectResponseCreatedFromTemplate. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectResponseCreatedFromTemplate. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectResponseCreatedFromTemplate. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectResponseCreatedFromTemplate. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectResponseCreatedFromTemplate. # noqa: E501 - - Name of the project template. # noqa: E501 - - :return: The name of this ProjectResponseCreatedFromTemplate. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectResponseCreatedFromTemplate. - - Name of the project template. # noqa: E501 - - :param name: The name of this ProjectResponseCreatedFromTemplate. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectResponseCreatedFromTemplate, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectResponseCreatedFromTemplate): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_response_data.py b/asana/models/project_response_data.py deleted file mode 100644 index dd5aa692..00000000 --- a/asana/models/project_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this ProjectResponseData. # noqa: E501 - - - :return: The data of this ProjectResponseData. # noqa: E501 - :rtype: ProjectResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectResponseData. - - - :param data: The data of this ProjectResponseData. # noqa: E501 - :type: ProjectResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_response_project_brief.py b/asana/models/project_response_project_brief.py deleted file mode 100644 index e26be30c..00000000 --- a/asana/models/project_response_project_brief.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectResponseProjectBrief(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type' - } - - def __init__(self, gid=None, resource_type=None): # noqa: E501 - """ProjectResponseProjectBrief - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - - @property - def gid(self): - """Gets the gid of this ProjectResponseProjectBrief. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectResponseProjectBrief. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectResponseProjectBrief. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectResponseProjectBrief. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectResponseProjectBrief. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectResponseProjectBrief. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectResponseProjectBrief. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectResponseProjectBrief. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectResponseProjectBrief, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectResponseProjectBrief): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_response_team.py b/asana/models/project_response_team.py deleted file mode 100644 index a700dfb4..00000000 --- a/asana/models/project_response_team.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectResponseTeam(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """ProjectResponseTeam - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this ProjectResponseTeam. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectResponseTeam. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectResponseTeam. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectResponseTeam. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectResponseTeam. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectResponseTeam. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectResponseTeam. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectResponseTeam. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectResponseTeam. # noqa: E501 - - The name of the team. # noqa: E501 - - :return: The name of this ProjectResponseTeam. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectResponseTeam. - - The name of the team. # noqa: E501 - - :param name: The name of this ProjectResponseTeam. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectResponseTeam, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectResponseTeam): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_response_workspace.py b/asana/models/project_response_workspace.py deleted file mode 100644 index febc09bf..00000000 --- a/asana/models/project_response_workspace.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectResponseWorkspace(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """ProjectResponseWorkspace - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this ProjectResponseWorkspace. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectResponseWorkspace. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectResponseWorkspace. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectResponseWorkspace. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectResponseWorkspace. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectResponseWorkspace. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectResponseWorkspace. # noqa: E501 - - The name of the workspace. # noqa: E501 - - :return: The name of this ProjectResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectResponseWorkspace. - - The name of the workspace. # noqa: E501 - - :param name: The name of this ProjectResponseWorkspace. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectResponseWorkspace, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectResponseWorkspace): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_save_as_template_request.py b/asana/models/project_save_as_template_request.py deleted file mode 100644 index 9be59012..00000000 --- a/asana/models/project_save_as_template_request.py +++ /dev/null @@ -1,198 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectSaveAsTemplateRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'name': 'str', - 'team': 'str', - 'workspace': 'str', - 'public': 'bool' - } - - attribute_map = { - 'name': 'name', - 'team': 'team', - 'workspace': 'workspace', - 'public': 'public' - } - - def __init__(self, name=None, team=None, workspace=None, public=None): # noqa: E501 - """ProjectSaveAsTemplateRequest - a model defined in Swagger""" # noqa: E501 - self._name = None - self._team = None - self._workspace = None - self._public = None - self.discriminator = None - self.name = name - if team is not None: - self.team = team - if workspace is not None: - self.workspace = workspace - self.public = public - - @property - def name(self): - """Gets the name of this ProjectSaveAsTemplateRequest. # noqa: E501 - - The name of the new project template. # noqa: E501 - - :return: The name of this ProjectSaveAsTemplateRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectSaveAsTemplateRequest. - - The name of the new project template. # noqa: E501 - - :param name: The name of this ProjectSaveAsTemplateRequest. # noqa: E501 - :type: str - """ - if name is None: - raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 - - self._name = name - - @property - def team(self): - """Gets the team of this ProjectSaveAsTemplateRequest. # noqa: E501 - - Sets the team of the new project template. If the project exists in an organization, specify team and not workspace. # noqa: E501 - - :return: The team of this ProjectSaveAsTemplateRequest. # noqa: E501 - :rtype: str - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this ProjectSaveAsTemplateRequest. - - Sets the team of the new project template. If the project exists in an organization, specify team and not workspace. # noqa: E501 - - :param team: The team of this ProjectSaveAsTemplateRequest. # noqa: E501 - :type: str - """ - - self._team = team - - @property - def workspace(self): - """Gets the workspace of this ProjectSaveAsTemplateRequest. # noqa: E501 - - Sets the workspace of the new project template. Only specify workspace if the project exists in a workspace. # noqa: E501 - - :return: The workspace of this ProjectSaveAsTemplateRequest. # noqa: E501 - :rtype: str - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this ProjectSaveAsTemplateRequest. - - Sets the workspace of the new project template. Only specify workspace if the project exists in a workspace. # noqa: E501 - - :param workspace: The workspace of this ProjectSaveAsTemplateRequest. # noqa: E501 - :type: str - """ - - self._workspace = workspace - - @property - def public(self): - """Gets the public of this ProjectSaveAsTemplateRequest. # noqa: E501 - - Sets the project template to public to its team. # noqa: E501 - - :return: The public of this ProjectSaveAsTemplateRequest. # noqa: E501 - :rtype: bool - """ - return self._public - - @public.setter - def public(self, public): - """Sets the public of this ProjectSaveAsTemplateRequest. - - Sets the project template to public to its team. # noqa: E501 - - :param public: The public of this ProjectSaveAsTemplateRequest. # noqa: E501 - :type: bool - """ - if public is None: - raise ValueError("Invalid value for `public`, must not be `None`") # noqa: E501 - - self._public = public - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectSaveAsTemplateRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectSaveAsTemplateRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_section_insert_request.py b/asana/models/project_section_insert_request.py deleted file mode 100644 index 2fd3e563..00000000 --- a/asana/models/project_section_insert_request.py +++ /dev/null @@ -1,169 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectSectionInsertRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'section': 'str', - 'before_section': 'str', - 'after_section': 'str' - } - - attribute_map = { - 'section': 'section', - 'before_section': 'before_section', - 'after_section': 'after_section' - } - - def __init__(self, section=None, before_section=None, after_section=None): # noqa: E501 - """ProjectSectionInsertRequest - a model defined in Swagger""" # noqa: E501 - self._section = None - self._before_section = None - self._after_section = None - self.discriminator = None - self.section = section - if before_section is not None: - self.before_section = before_section - if after_section is not None: - self.after_section = after_section - - @property - def section(self): - """Gets the section of this ProjectSectionInsertRequest. # noqa: E501 - - The section to reorder. # noqa: E501 - - :return: The section of this ProjectSectionInsertRequest. # noqa: E501 - :rtype: str - """ - return self._section - - @section.setter - def section(self, section): - """Sets the section of this ProjectSectionInsertRequest. - - The section to reorder. # noqa: E501 - - :param section: The section of this ProjectSectionInsertRequest. # noqa: E501 - :type: str - """ - if section is None: - raise ValueError("Invalid value for `section`, must not be `None`") # noqa: E501 - - self._section = section - - @property - def before_section(self): - """Gets the before_section of this ProjectSectionInsertRequest. # noqa: E501 - - Insert the given section immediately before the section specified by this parameter. # noqa: E501 - - :return: The before_section of this ProjectSectionInsertRequest. # noqa: E501 - :rtype: str - """ - return self._before_section - - @before_section.setter - def before_section(self, before_section): - """Sets the before_section of this ProjectSectionInsertRequest. - - Insert the given section immediately before the section specified by this parameter. # noqa: E501 - - :param before_section: The before_section of this ProjectSectionInsertRequest. # noqa: E501 - :type: str - """ - - self._before_section = before_section - - @property - def after_section(self): - """Gets the after_section of this ProjectSectionInsertRequest. # noqa: E501 - - Insert the given section immediately after the section specified by this parameter. # noqa: E501 - - :return: The after_section of this ProjectSectionInsertRequest. # noqa: E501 - :rtype: str - """ - return self._after_section - - @after_section.setter - def after_section(self, after_section): - """Sets the after_section of this ProjectSectionInsertRequest. - - Insert the given section immediately after the section specified by this parameter. # noqa: E501 - - :param after_section: The after_section of this ProjectSectionInsertRequest. # noqa: E501 - :type: str - """ - - self._after_section = after_section - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectSectionInsertRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectSectionInsertRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_status_base.py b/asana/models/project_status_base.py deleted file mode 100644 index 0e58fb35..00000000 --- a/asana/models/project_status_base.py +++ /dev/null @@ -1,258 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectStatusBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'text': 'str', - 'html_text': 'str', - 'color': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'text': 'text', - 'html_text': 'html_text', - 'color': 'color' - } - - def __init__(self, gid=None, resource_type=None, title=None, text=None, html_text=None, color=None): # noqa: E501 - """ProjectStatusBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._text = None - self._html_text = None - self._color = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if text is not None: - self.text = text - if html_text is not None: - self.html_text = html_text - if color is not None: - self.color = color - - @property - def gid(self): - """Gets the gid of this ProjectStatusBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectStatusBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectStatusBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectStatusBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectStatusBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectStatusBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectStatusBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectStatusBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this ProjectStatusBase. # noqa: E501 - - The title of the project status update. # noqa: E501 - - :return: The title of this ProjectStatusBase. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this ProjectStatusBase. - - The title of the project status update. # noqa: E501 - - :param title: The title of this ProjectStatusBase. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def text(self): - """Gets the text of this ProjectStatusBase. # noqa: E501 - - The text content of the status update. # noqa: E501 - - :return: The text of this ProjectStatusBase. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this ProjectStatusBase. - - The text content of the status update. # noqa: E501 - - :param text: The text of this ProjectStatusBase. # noqa: E501 - :type: str - """ - - self._text = text - - @property - def html_text(self): - """Gets the html_text of this ProjectStatusBase. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :return: The html_text of this ProjectStatusBase. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this ProjectStatusBase. - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :param html_text: The html_text of this ProjectStatusBase. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def color(self): - """Gets the color of this ProjectStatusBase. # noqa: E501 - - The color associated with the status update. # noqa: E501 - - :return: The color of this ProjectStatusBase. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this ProjectStatusBase. - - The color associated with the status update. # noqa: E501 - - :param color: The color of this ProjectStatusBase. # noqa: E501 - :type: str - """ - allowed_values = ["green", "yellow", "red", "blue", "complete"] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectStatusBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectStatusBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_status_compact.py b/asana/models/project_status_compact.py deleted file mode 100644 index 9765a384..00000000 --- a/asana/models/project_status_compact.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectStatusCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title' - } - - def __init__(self, gid=None, resource_type=None, title=None): # noqa: E501 - """ProjectStatusCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - - @property - def gid(self): - """Gets the gid of this ProjectStatusCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectStatusCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectStatusCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectStatusCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectStatusCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectStatusCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectStatusCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectStatusCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this ProjectStatusCompact. # noqa: E501 - - The title of the project status update. # noqa: E501 - - :return: The title of this ProjectStatusCompact. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this ProjectStatusCompact. - - The title of the project status update. # noqa: E501 - - :param title: The title of this ProjectStatusCompact. # noqa: E501 - :type: str - """ - - self._title = title - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectStatusCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectStatusCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_status_request.py b/asana/models/project_status_request.py deleted file mode 100644 index fec5f214..00000000 --- a/asana/models/project_status_request.py +++ /dev/null @@ -1,258 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectStatusRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'text': 'str', - 'html_text': 'str', - 'color': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'text': 'text', - 'html_text': 'html_text', - 'color': 'color' - } - - def __init__(self, gid=None, resource_type=None, title=None, text=None, html_text=None, color=None): # noqa: E501 - """ProjectStatusRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._text = None - self._html_text = None - self._color = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if text is not None: - self.text = text - if html_text is not None: - self.html_text = html_text - if color is not None: - self.color = color - - @property - def gid(self): - """Gets the gid of this ProjectStatusRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectStatusRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectStatusRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectStatusRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectStatusRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectStatusRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectStatusRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectStatusRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this ProjectStatusRequest. # noqa: E501 - - The title of the project status update. # noqa: E501 - - :return: The title of this ProjectStatusRequest. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this ProjectStatusRequest. - - The title of the project status update. # noqa: E501 - - :param title: The title of this ProjectStatusRequest. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def text(self): - """Gets the text of this ProjectStatusRequest. # noqa: E501 - - The text content of the status update. # noqa: E501 - - :return: The text of this ProjectStatusRequest. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this ProjectStatusRequest. - - The text content of the status update. # noqa: E501 - - :param text: The text of this ProjectStatusRequest. # noqa: E501 - :type: str - """ - - self._text = text - - @property - def html_text(self): - """Gets the html_text of this ProjectStatusRequest. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :return: The html_text of this ProjectStatusRequest. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this ProjectStatusRequest. - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :param html_text: The html_text of this ProjectStatusRequest. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def color(self): - """Gets the color of this ProjectStatusRequest. # noqa: E501 - - The color associated with the status update. # noqa: E501 - - :return: The color of this ProjectStatusRequest. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this ProjectStatusRequest. - - The color associated with the status update. # noqa: E501 - - :param color: The color of this ProjectStatusRequest. # noqa: E501 - :type: str - """ - allowed_values = ["green", "yellow", "red", "blue", "complete"] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectStatusRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectStatusRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_status_response.py b/asana/models/project_status_response.py deleted file mode 100644 index 1da46cb6..00000000 --- a/asana/models/project_status_response.py +++ /dev/null @@ -1,366 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectStatusResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'text': 'str', - 'html_text': 'str', - 'color': 'str', - 'author': 'CustomFieldResponsePeopleValue', - 'created_at': 'datetime', - 'created_by': 'CustomFieldResponsePeopleValue', - 'modified_at': 'datetime' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'text': 'text', - 'html_text': 'html_text', - 'color': 'color', - 'author': 'author', - 'created_at': 'created_at', - 'created_by': 'created_by', - 'modified_at': 'modified_at' - } - - def __init__(self, gid=None, resource_type=None, title=None, text=None, html_text=None, color=None, author=None, created_at=None, created_by=None, modified_at=None): # noqa: E501 - """ProjectStatusResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._text = None - self._html_text = None - self._color = None - self._author = None - self._created_at = None - self._created_by = None - self._modified_at = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if text is not None: - self.text = text - if html_text is not None: - self.html_text = html_text - if color is not None: - self.color = color - if author is not None: - self.author = author - if created_at is not None: - self.created_at = created_at - if created_by is not None: - self.created_by = created_by - if modified_at is not None: - self.modified_at = modified_at - - @property - def gid(self): - """Gets the gid of this ProjectStatusResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectStatusResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectStatusResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectStatusResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectStatusResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectStatusResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectStatusResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectStatusResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this ProjectStatusResponse. # noqa: E501 - - The title of the project status update. # noqa: E501 - - :return: The title of this ProjectStatusResponse. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this ProjectStatusResponse. - - The title of the project status update. # noqa: E501 - - :param title: The title of this ProjectStatusResponse. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def text(self): - """Gets the text of this ProjectStatusResponse. # noqa: E501 - - The text content of the status update. # noqa: E501 - - :return: The text of this ProjectStatusResponse. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this ProjectStatusResponse. - - The text content of the status update. # noqa: E501 - - :param text: The text of this ProjectStatusResponse. # noqa: E501 - :type: str - """ - - self._text = text - - @property - def html_text(self): - """Gets the html_text of this ProjectStatusResponse. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :return: The html_text of this ProjectStatusResponse. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this ProjectStatusResponse. - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :param html_text: The html_text of this ProjectStatusResponse. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def color(self): - """Gets the color of this ProjectStatusResponse. # noqa: E501 - - The color associated with the status update. # noqa: E501 - - :return: The color of this ProjectStatusResponse. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this ProjectStatusResponse. - - The color associated with the status update. # noqa: E501 - - :param color: The color of this ProjectStatusResponse. # noqa: E501 - :type: str - """ - allowed_values = ["green", "yellow", "red", "blue", "complete"] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def author(self): - """Gets the author of this ProjectStatusResponse. # noqa: E501 - - - :return: The author of this ProjectStatusResponse. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._author - - @author.setter - def author(self, author): - """Sets the author of this ProjectStatusResponse. - - - :param author: The author of this ProjectStatusResponse. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._author = author - - @property - def created_at(self): - """Gets the created_at of this ProjectStatusResponse. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this ProjectStatusResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this ProjectStatusResponse. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this ProjectStatusResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def created_by(self): - """Gets the created_by of this ProjectStatusResponse. # noqa: E501 - - - :return: The created_by of this ProjectStatusResponse. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this ProjectStatusResponse. - - - :param created_by: The created_by of this ProjectStatusResponse. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._created_by = created_by - - @property - def modified_at(self): - """Gets the modified_at of this ProjectStatusResponse. # noqa: E501 - - The time at which this project status was last modified. *Note: This does not currently reflect any changes in associations such as comments that may have been added or removed from the project status.* # noqa: E501 - - :return: The modified_at of this ProjectStatusResponse. # noqa: E501 - :rtype: datetime - """ - return self._modified_at - - @modified_at.setter - def modified_at(self, modified_at): - """Sets the modified_at of this ProjectStatusResponse. - - The time at which this project status was last modified. *Note: This does not currently reflect any changes in associations such as comments that may have been added or removed from the project status.* # noqa: E501 - - :param modified_at: The modified_at of this ProjectStatusResponse. # noqa: E501 - :type: datetime - """ - - self._modified_at = modified_at - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectStatusResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectStatusResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_status_response_array.py b/asana/models/project_status_response_array.py deleted file mode 100644 index 0b06d84b..00000000 --- a/asana/models/project_status_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectStatusResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[ProjectStatusResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """ProjectStatusResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this ProjectStatusResponseArray. # noqa: E501 - - - :return: The data of this ProjectStatusResponseArray. # noqa: E501 - :rtype: list[ProjectStatusResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectStatusResponseArray. - - - :param data: The data of this ProjectStatusResponseArray. # noqa: E501 - :type: list[ProjectStatusResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this ProjectStatusResponseArray. # noqa: E501 - - - :return: The next_page of this ProjectStatusResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this ProjectStatusResponseArray. - - - :param next_page: The next_page of this ProjectStatusResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectStatusResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectStatusResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_status_response_data.py b/asana/models/project_status_response_data.py deleted file mode 100644 index 8ed083cf..00000000 --- a/asana/models/project_status_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectStatusResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectStatusResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectStatusResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this ProjectStatusResponseData. # noqa: E501 - - - :return: The data of this ProjectStatusResponseData. # noqa: E501 - :rtype: ProjectStatusResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectStatusResponseData. - - - :param data: The data of this ProjectStatusResponseData. # noqa: E501 - :type: ProjectStatusResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectStatusResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectStatusResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_template_base.py b/asana/models/project_template_base.py deleted file mode 100644 index c7d186b6..00000000 --- a/asana/models/project_template_base.py +++ /dev/null @@ -1,396 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectTemplateBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'description': 'str', - 'html_description': 'str', - 'public': 'bool', - 'owner': 'AllOfProjectTemplateBaseOwner', - 'team': 'ProjectTemplateBaseTeam', - 'requested_dates': 'list[ProjectTemplateBaseRequestedDates]', - 'color': 'str', - 'requested_roles': 'list[ProjectTemplateBaseRequestedRoles]' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'description': 'description', - 'html_description': 'html_description', - 'public': 'public', - 'owner': 'owner', - 'team': 'team', - 'requested_dates': 'requested_dates', - 'color': 'color', - 'requested_roles': 'requested_roles' - } - - def __init__(self, gid=None, resource_type=None, name=None, description=None, html_description=None, public=None, owner=None, team=None, requested_dates=None, color=None, requested_roles=None): # noqa: E501 - """ProjectTemplateBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._description = None - self._html_description = None - self._public = None - self._owner = None - self._team = None - self._requested_dates = None - self._color = None - self._requested_roles = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if description is not None: - self.description = description - if html_description is not None: - self.html_description = html_description - if public is not None: - self.public = public - if owner is not None: - self.owner = owner - if team is not None: - self.team = team - if requested_dates is not None: - self.requested_dates = requested_dates - if color is not None: - self.color = color - if requested_roles is not None: - self.requested_roles = requested_roles - - @property - def gid(self): - """Gets the gid of this ProjectTemplateBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectTemplateBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectTemplateBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectTemplateBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectTemplateBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectTemplateBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectTemplateBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectTemplateBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectTemplateBase. # noqa: E501 - - Name of the project template. # noqa: E501 - - :return: The name of this ProjectTemplateBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectTemplateBase. - - Name of the project template. # noqa: E501 - - :param name: The name of this ProjectTemplateBase. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def description(self): - """Gets the description of this ProjectTemplateBase. # noqa: E501 - - Free-form textual information associated with the project template # noqa: E501 - - :return: The description of this ProjectTemplateBase. # noqa: E501 - :rtype: str - """ - return self._description - - @description.setter - def description(self, description): - """Sets the description of this ProjectTemplateBase. - - Free-form textual information associated with the project template # noqa: E501 - - :param description: The description of this ProjectTemplateBase. # noqa: E501 - :type: str - """ - - self._description = description - - @property - def html_description(self): - """Gets the html_description of this ProjectTemplateBase. # noqa: E501 - - The description of the project template with formatting as HTML. # noqa: E501 - - :return: The html_description of this ProjectTemplateBase. # noqa: E501 - :rtype: str - """ - return self._html_description - - @html_description.setter - def html_description(self, html_description): - """Sets the html_description of this ProjectTemplateBase. - - The description of the project template with formatting as HTML. # noqa: E501 - - :param html_description: The html_description of this ProjectTemplateBase. # noqa: E501 - :type: str - """ - - self._html_description = html_description - - @property - def public(self): - """Gets the public of this ProjectTemplateBase. # noqa: E501 - - True if the project template is public to its team. # noqa: E501 - - :return: The public of this ProjectTemplateBase. # noqa: E501 - :rtype: bool - """ - return self._public - - @public.setter - def public(self, public): - """Sets the public of this ProjectTemplateBase. - - True if the project template is public to its team. # noqa: E501 - - :param public: The public of this ProjectTemplateBase. # noqa: E501 - :type: bool - """ - - self._public = public - - @property - def owner(self): - """Gets the owner of this ProjectTemplateBase. # noqa: E501 - - The current owner of the project template, may be null. # noqa: E501 - - :return: The owner of this ProjectTemplateBase. # noqa: E501 - :rtype: AllOfProjectTemplateBaseOwner - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this ProjectTemplateBase. - - The current owner of the project template, may be null. # noqa: E501 - - :param owner: The owner of this ProjectTemplateBase. # noqa: E501 - :type: AllOfProjectTemplateBaseOwner - """ - - self._owner = owner - - @property - def team(self): - """Gets the team of this ProjectTemplateBase. # noqa: E501 - - - :return: The team of this ProjectTemplateBase. # noqa: E501 - :rtype: ProjectTemplateBaseTeam - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this ProjectTemplateBase. - - - :param team: The team of this ProjectTemplateBase. # noqa: E501 - :type: ProjectTemplateBaseTeam - """ - - self._team = team - - @property - def requested_dates(self): - """Gets the requested_dates of this ProjectTemplateBase. # noqa: E501 - - Array of date variables in this project template. Calendar dates must be provided for these variables when instantiating a project. # noqa: E501 - - :return: The requested_dates of this ProjectTemplateBase. # noqa: E501 - :rtype: list[ProjectTemplateBaseRequestedDates] - """ - return self._requested_dates - - @requested_dates.setter - def requested_dates(self, requested_dates): - """Sets the requested_dates of this ProjectTemplateBase. - - Array of date variables in this project template. Calendar dates must be provided for these variables when instantiating a project. # noqa: E501 - - :param requested_dates: The requested_dates of this ProjectTemplateBase. # noqa: E501 - :type: list[ProjectTemplateBaseRequestedDates] - """ - - self._requested_dates = requested_dates - - @property - def color(self): - """Gets the color of this ProjectTemplateBase. # noqa: E501 - - Color of the project template. # noqa: E501 - - :return: The color of this ProjectTemplateBase. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this ProjectTemplateBase. - - Color of the project template. # noqa: E501 - - :param color: The color of this ProjectTemplateBase. # noqa: E501 - :type: str - """ - allowed_values = ["dark-pink", "dark-green", "dark-blue", "dark-red", "dark-teal", "dark-brown", "dark-orange", "dark-purple", "dark-warm-gray", "light-pink", "light-green", "light-blue", "light-red", "light-teal", "light-brown", "light-orange", "light-purple", "light-warm-gray", ""] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def requested_roles(self): - """Gets the requested_roles of this ProjectTemplateBase. # noqa: E501 - - Array of template roles in this project template. User Ids can be provided for these variables when instantiating a project to assign template tasks to the user. # noqa: E501 - - :return: The requested_roles of this ProjectTemplateBase. # noqa: E501 - :rtype: list[ProjectTemplateBaseRequestedRoles] - """ - return self._requested_roles - - @requested_roles.setter - def requested_roles(self, requested_roles): - """Sets the requested_roles of this ProjectTemplateBase. - - Array of template roles in this project template. User Ids can be provided for these variables when instantiating a project to assign template tasks to the user. # noqa: E501 - - :param requested_roles: The requested_roles of this ProjectTemplateBase. # noqa: E501 - :type: list[ProjectTemplateBaseRequestedRoles] - """ - - self._requested_roles = requested_roles - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectTemplateBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectTemplateBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_template_base_requested_dates.py b/asana/models/project_template_base_requested_dates.py deleted file mode 100644 index 5075146d..00000000 --- a/asana/models/project_template_base_requested_dates.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectTemplateBaseRequestedDates(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'name': 'str', - 'description': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'name': 'name', - 'description': 'description' - } - - def __init__(self, gid=None, name=None, description=None): # noqa: E501 - """ProjectTemplateBaseRequestedDates - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._name = None - self._description = None - self.discriminator = None - if gid is not None: - self.gid = gid - if name is not None: - self.name = name - if description is not None: - self.description = description - - @property - def gid(self): - """Gets the gid of this ProjectTemplateBaseRequestedDates. # noqa: E501 - - Globally unique identifier of the date field in the project template. A value of `1` refers to the project start date, while `2` refers to the project due date. # noqa: E501 - - :return: The gid of this ProjectTemplateBaseRequestedDates. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectTemplateBaseRequestedDates. - - Globally unique identifier of the date field in the project template. A value of `1` refers to the project start date, while `2` refers to the project due date. # noqa: E501 - - :param gid: The gid of this ProjectTemplateBaseRequestedDates. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def name(self): - """Gets the name of this ProjectTemplateBaseRequestedDates. # noqa: E501 - - The name of the date variable. # noqa: E501 - - :return: The name of this ProjectTemplateBaseRequestedDates. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectTemplateBaseRequestedDates. - - The name of the date variable. # noqa: E501 - - :param name: The name of this ProjectTemplateBaseRequestedDates. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def description(self): - """Gets the description of this ProjectTemplateBaseRequestedDates. # noqa: E501 - - The description of what the date variable is used for when instantiating a project. # noqa: E501 - - :return: The description of this ProjectTemplateBaseRequestedDates. # noqa: E501 - :rtype: str - """ - return self._description - - @description.setter - def description(self, description): - """Sets the description of this ProjectTemplateBaseRequestedDates. - - The description of what the date variable is used for when instantiating a project. # noqa: E501 - - :param description: The description of this ProjectTemplateBaseRequestedDates. # noqa: E501 - :type: str - """ - - self._description = description - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectTemplateBaseRequestedDates, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectTemplateBaseRequestedDates): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_template_base_requested_roles.py b/asana/models/project_template_base_requested_roles.py deleted file mode 100644 index 441139ab..00000000 --- a/asana/models/project_template_base_requested_roles.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectTemplateBaseRequestedRoles(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """ProjectTemplateBaseRequestedRoles - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this ProjectTemplateBaseRequestedRoles. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectTemplateBaseRequestedRoles. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectTemplateBaseRequestedRoles. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectTemplateBaseRequestedRoles. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectTemplateBaseRequestedRoles. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectTemplateBaseRequestedRoles. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectTemplateBaseRequestedRoles. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectTemplateBaseRequestedRoles. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectTemplateBaseRequestedRoles. # noqa: E501 - - Name of the template role. # noqa: E501 - - :return: The name of this ProjectTemplateBaseRequestedRoles. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectTemplateBaseRequestedRoles. - - Name of the template role. # noqa: E501 - - :param name: The name of this ProjectTemplateBaseRequestedRoles. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectTemplateBaseRequestedRoles, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectTemplateBaseRequestedRoles): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_template_base_team.py b/asana/models/project_template_base_team.py deleted file mode 100644 index 6196f1e9..00000000 --- a/asana/models/project_template_base_team.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectTemplateBaseTeam(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """ProjectTemplateBaseTeam - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this ProjectTemplateBaseTeam. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectTemplateBaseTeam. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectTemplateBaseTeam. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectTemplateBaseTeam. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectTemplateBaseTeam. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectTemplateBaseTeam. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectTemplateBaseTeam. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectTemplateBaseTeam. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectTemplateBaseTeam. # noqa: E501 - - The name of the team. # noqa: E501 - - :return: The name of this ProjectTemplateBaseTeam. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectTemplateBaseTeam. - - The name of the team. # noqa: E501 - - :param name: The name of this ProjectTemplateBaseTeam. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectTemplateBaseTeam, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectTemplateBaseTeam): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_template_compact.py b/asana/models/project_template_compact.py deleted file mode 100644 index baa340e8..00000000 --- a/asana/models/project_template_compact.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectTemplateCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """ProjectTemplateCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this ProjectTemplateCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectTemplateCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectTemplateCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectTemplateCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectTemplateCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectTemplateCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectTemplateCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectTemplateCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectTemplateCompact. # noqa: E501 - - Name of the project template. # noqa: E501 - - :return: The name of this ProjectTemplateCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectTemplateCompact. - - Name of the project template. # noqa: E501 - - :param name: The name of this ProjectTemplateCompact. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectTemplateCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectTemplateCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_template_gid_instantiate_project_body.py b/asana/models/project_template_gid_instantiate_project_body.py deleted file mode 100644 index 08a592a7..00000000 --- a/asana/models/project_template_gid_instantiate_project_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectTemplateGidInstantiateProjectBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectTemplateInstantiateProjectRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectTemplateGidInstantiateProjectBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectTemplateGidInstantiateProjectBody. # noqa: E501 - - - :return: The data of this ProjectTemplateGidInstantiateProjectBody. # noqa: E501 - :rtype: ProjectTemplateInstantiateProjectRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectTemplateGidInstantiateProjectBody. - - - :param data: The data of this ProjectTemplateGidInstantiateProjectBody. # noqa: E501 - :type: ProjectTemplateInstantiateProjectRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectTemplateGidInstantiateProjectBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectTemplateGidInstantiateProjectBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_template_instantiate_project_request.py b/asana/models/project_template_instantiate_project_request.py deleted file mode 100644 index 1b92aa4f..00000000 --- a/asana/models/project_template_instantiate_project_request.py +++ /dev/null @@ -1,253 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectTemplateInstantiateProjectRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'name': 'str', - 'team': 'str', - 'public': 'bool', - 'is_strict': 'bool', - 'requested_dates': 'list[ProjectTemplateInstantiateProjectRequestRequestedDates]', - 'requested_roles': 'list[ProjectTemplateInstantiateProjectRequestRequestedRoles]' - } - - attribute_map = { - 'name': 'name', - 'team': 'team', - 'public': 'public', - 'is_strict': 'is_strict', - 'requested_dates': 'requested_dates', - 'requested_roles': 'requested_roles' - } - - def __init__(self, name=None, team=None, public=None, is_strict=None, requested_dates=None, requested_roles=None): # noqa: E501 - """ProjectTemplateInstantiateProjectRequest - a model defined in Swagger""" # noqa: E501 - self._name = None - self._team = None - self._public = None - self._is_strict = None - self._requested_dates = None - self._requested_roles = None - self.discriminator = None - self.name = name - if team is not None: - self.team = team - if public is not None: - self.public = public - if is_strict is not None: - self.is_strict = is_strict - if requested_dates is not None: - self.requested_dates = requested_dates - if requested_roles is not None: - self.requested_roles = requested_roles - - @property - def name(self): - """Gets the name of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - - The name of the new project. # noqa: E501 - - :return: The name of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectTemplateInstantiateProjectRequest. - - The name of the new project. # noqa: E501 - - :param name: The name of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - :type: str - """ - if name is None: - raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 - - self._name = name - - @property - def team(self): - """Gets the team of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - - *Optional*. Sets the team of the new project. If the project template exists in an _organization_, you may specify a value for `team`. If no value is provided then it defaults to the same team as the project template. # noqa: E501 - - :return: The team of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - :rtype: str - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this ProjectTemplateInstantiateProjectRequest. - - *Optional*. Sets the team of the new project. If the project template exists in an _organization_, you may specify a value for `team`. If no value is provided then it defaults to the same team as the project template. # noqa: E501 - - :param team: The team of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - :type: str - """ - - self._team = team - - @property - def public(self): - """Gets the public of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - - Sets the project to public to its team. # noqa: E501 - - :return: The public of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - :rtype: bool - """ - return self._public - - @public.setter - def public(self, public): - """Sets the public of this ProjectTemplateInstantiateProjectRequest. - - Sets the project to public to its team. # noqa: E501 - - :param public: The public of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - :type: bool - """ - - self._public = public - - @property - def is_strict(self): - """Gets the is_strict of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - - *Optional*. If set to `true`, the endpoint returns an \"Unprocessable Entity\" error if you fail to provide a calendar date value for any date variable. If set to `false`, a default date is used for each unfulfilled date variable (e.g., the current date is used as the Start Date of a project). # noqa: E501 - - :return: The is_strict of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - :rtype: bool - """ - return self._is_strict - - @is_strict.setter - def is_strict(self, is_strict): - """Sets the is_strict of this ProjectTemplateInstantiateProjectRequest. - - *Optional*. If set to `true`, the endpoint returns an \"Unprocessable Entity\" error if you fail to provide a calendar date value for any date variable. If set to `false`, a default date is used for each unfulfilled date variable (e.g., the current date is used as the Start Date of a project). # noqa: E501 - - :param is_strict: The is_strict of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - :type: bool - """ - - self._is_strict = is_strict - - @property - def requested_dates(self): - """Gets the requested_dates of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - - Array of mappings of date variables to calendar dates. # noqa: E501 - - :return: The requested_dates of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - :rtype: list[ProjectTemplateInstantiateProjectRequestRequestedDates] - """ - return self._requested_dates - - @requested_dates.setter - def requested_dates(self, requested_dates): - """Sets the requested_dates of this ProjectTemplateInstantiateProjectRequest. - - Array of mappings of date variables to calendar dates. # noqa: E501 - - :param requested_dates: The requested_dates of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - :type: list[ProjectTemplateInstantiateProjectRequestRequestedDates] - """ - - self._requested_dates = requested_dates - - @property - def requested_roles(self): - """Gets the requested_roles of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - - Array of mappings of template roles to user ids # noqa: E501 - - :return: The requested_roles of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - :rtype: list[ProjectTemplateInstantiateProjectRequestRequestedRoles] - """ - return self._requested_roles - - @requested_roles.setter - def requested_roles(self, requested_roles): - """Sets the requested_roles of this ProjectTemplateInstantiateProjectRequest. - - Array of mappings of template roles to user ids # noqa: E501 - - :param requested_roles: The requested_roles of this ProjectTemplateInstantiateProjectRequest. # noqa: E501 - :type: list[ProjectTemplateInstantiateProjectRequestRequestedRoles] - """ - - self._requested_roles = requested_roles - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectTemplateInstantiateProjectRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectTemplateInstantiateProjectRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_template_instantiate_project_request_requested_dates.py b/asana/models/project_template_instantiate_project_request_requested_dates.py deleted file mode 100644 index 9ebefa5d..00000000 --- a/asana/models/project_template_instantiate_project_request_requested_dates.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectTemplateInstantiateProjectRequestRequestedDates(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'value': 'datetime' - } - - attribute_map = { - 'gid': 'gid', - 'value': 'value' - } - - def __init__(self, gid=None, value=None): # noqa: E501 - """ProjectTemplateInstantiateProjectRequestRequestedDates - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._value = None - self.discriminator = None - if gid is not None: - self.gid = gid - if value is not None: - self.value = value - - @property - def gid(self): - """Gets the gid of this ProjectTemplateInstantiateProjectRequestRequestedDates. # noqa: E501 - - Globally unique identifier of the date field in the project template. A value of `1` refers to the project start date, while `2` refers to the project due date. # noqa: E501 - - :return: The gid of this ProjectTemplateInstantiateProjectRequestRequestedDates. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectTemplateInstantiateProjectRequestRequestedDates. - - Globally unique identifier of the date field in the project template. A value of `1` refers to the project start date, while `2` refers to the project due date. # noqa: E501 - - :param gid: The gid of this ProjectTemplateInstantiateProjectRequestRequestedDates. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def value(self): - """Gets the value of this ProjectTemplateInstantiateProjectRequestRequestedDates. # noqa: E501 - - The date with which the date variable should be replaced when instantiating a project. This takes a date with `YYYY-MM-DD` format. # noqa: E501 - - :return: The value of this ProjectTemplateInstantiateProjectRequestRequestedDates. # noqa: E501 - :rtype: datetime - """ - return self._value - - @value.setter - def value(self, value): - """Sets the value of this ProjectTemplateInstantiateProjectRequestRequestedDates. - - The date with which the date variable should be replaced when instantiating a project. This takes a date with `YYYY-MM-DD` format. # noqa: E501 - - :param value: The value of this ProjectTemplateInstantiateProjectRequestRequestedDates. # noqa: E501 - :type: datetime - """ - - self._value = value - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectTemplateInstantiateProjectRequestRequestedDates, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectTemplateInstantiateProjectRequestRequestedDates): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_template_instantiate_project_request_requested_roles.py b/asana/models/project_template_instantiate_project_request_requested_roles.py deleted file mode 100644 index cb847e8d..00000000 --- a/asana/models/project_template_instantiate_project_request_requested_roles.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectTemplateInstantiateProjectRequestRequestedRoles(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'value': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'value': 'value' - } - - def __init__(self, gid=None, value=None): # noqa: E501 - """ProjectTemplateInstantiateProjectRequestRequestedRoles - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._value = None - self.discriminator = None - if gid is not None: - self.gid = gid - if value is not None: - self.value = value - - @property - def gid(self): - """Gets the gid of this ProjectTemplateInstantiateProjectRequestRequestedRoles. # noqa: E501 - - Globally unique identifier of the template role in the project template. # noqa: E501 - - :return: The gid of this ProjectTemplateInstantiateProjectRequestRequestedRoles. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectTemplateInstantiateProjectRequestRequestedRoles. - - Globally unique identifier of the template role in the project template. # noqa: E501 - - :param gid: The gid of this ProjectTemplateInstantiateProjectRequestRequestedRoles. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def value(self): - """Gets the value of this ProjectTemplateInstantiateProjectRequestRequestedRoles. # noqa: E501 - - The user id that should be assigned to the template role. # noqa: E501 - - :return: The value of this ProjectTemplateInstantiateProjectRequestRequestedRoles. # noqa: E501 - :rtype: str - """ - return self._value - - @value.setter - def value(self, value): - """Sets the value of this ProjectTemplateInstantiateProjectRequestRequestedRoles. - - The user id that should be assigned to the template role. # noqa: E501 - - :param value: The value of this ProjectTemplateInstantiateProjectRequestRequestedRoles. # noqa: E501 - :type: str - """ - - self._value = value - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectTemplateInstantiateProjectRequestRequestedRoles, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectTemplateInstantiateProjectRequestRequestedRoles): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_template_response.py b/asana/models/project_template_response.py deleted file mode 100644 index 57a32771..00000000 --- a/asana/models/project_template_response.py +++ /dev/null @@ -1,396 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectTemplateResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'description': 'str', - 'html_description': 'str', - 'public': 'bool', - 'owner': 'AllOfProjectTemplateResponseOwner', - 'team': 'ProjectTemplateBaseTeam', - 'requested_dates': 'list[ProjectTemplateBaseRequestedDates]', - 'color': 'str', - 'requested_roles': 'list[ProjectTemplateBaseRequestedRoles]' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'description': 'description', - 'html_description': 'html_description', - 'public': 'public', - 'owner': 'owner', - 'team': 'team', - 'requested_dates': 'requested_dates', - 'color': 'color', - 'requested_roles': 'requested_roles' - } - - def __init__(self, gid=None, resource_type=None, name=None, description=None, html_description=None, public=None, owner=None, team=None, requested_dates=None, color=None, requested_roles=None): # noqa: E501 - """ProjectTemplateResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._description = None - self._html_description = None - self._public = None - self._owner = None - self._team = None - self._requested_dates = None - self._color = None - self._requested_roles = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if description is not None: - self.description = description - if html_description is not None: - self.html_description = html_description - if public is not None: - self.public = public - if owner is not None: - self.owner = owner - if team is not None: - self.team = team - if requested_dates is not None: - self.requested_dates = requested_dates - if color is not None: - self.color = color - if requested_roles is not None: - self.requested_roles = requested_roles - - @property - def gid(self): - """Gets the gid of this ProjectTemplateResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectTemplateResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectTemplateResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectTemplateResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectTemplateResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectTemplateResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectTemplateResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectTemplateResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectTemplateResponse. # noqa: E501 - - Name of the project template. # noqa: E501 - - :return: The name of this ProjectTemplateResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectTemplateResponse. - - Name of the project template. # noqa: E501 - - :param name: The name of this ProjectTemplateResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def description(self): - """Gets the description of this ProjectTemplateResponse. # noqa: E501 - - Free-form textual information associated with the project template # noqa: E501 - - :return: The description of this ProjectTemplateResponse. # noqa: E501 - :rtype: str - """ - return self._description - - @description.setter - def description(self, description): - """Sets the description of this ProjectTemplateResponse. - - Free-form textual information associated with the project template # noqa: E501 - - :param description: The description of this ProjectTemplateResponse. # noqa: E501 - :type: str - """ - - self._description = description - - @property - def html_description(self): - """Gets the html_description of this ProjectTemplateResponse. # noqa: E501 - - The description of the project template with formatting as HTML. # noqa: E501 - - :return: The html_description of this ProjectTemplateResponse. # noqa: E501 - :rtype: str - """ - return self._html_description - - @html_description.setter - def html_description(self, html_description): - """Sets the html_description of this ProjectTemplateResponse. - - The description of the project template with formatting as HTML. # noqa: E501 - - :param html_description: The html_description of this ProjectTemplateResponse. # noqa: E501 - :type: str - """ - - self._html_description = html_description - - @property - def public(self): - """Gets the public of this ProjectTemplateResponse. # noqa: E501 - - True if the project template is public to its team. # noqa: E501 - - :return: The public of this ProjectTemplateResponse. # noqa: E501 - :rtype: bool - """ - return self._public - - @public.setter - def public(self, public): - """Sets the public of this ProjectTemplateResponse. - - True if the project template is public to its team. # noqa: E501 - - :param public: The public of this ProjectTemplateResponse. # noqa: E501 - :type: bool - """ - - self._public = public - - @property - def owner(self): - """Gets the owner of this ProjectTemplateResponse. # noqa: E501 - - The current owner of the project template, may be null. # noqa: E501 - - :return: The owner of this ProjectTemplateResponse. # noqa: E501 - :rtype: AllOfProjectTemplateResponseOwner - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this ProjectTemplateResponse. - - The current owner of the project template, may be null. # noqa: E501 - - :param owner: The owner of this ProjectTemplateResponse. # noqa: E501 - :type: AllOfProjectTemplateResponseOwner - """ - - self._owner = owner - - @property - def team(self): - """Gets the team of this ProjectTemplateResponse. # noqa: E501 - - - :return: The team of this ProjectTemplateResponse. # noqa: E501 - :rtype: ProjectTemplateBaseTeam - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this ProjectTemplateResponse. - - - :param team: The team of this ProjectTemplateResponse. # noqa: E501 - :type: ProjectTemplateBaseTeam - """ - - self._team = team - - @property - def requested_dates(self): - """Gets the requested_dates of this ProjectTemplateResponse. # noqa: E501 - - Array of date variables in this project template. Calendar dates must be provided for these variables when instantiating a project. # noqa: E501 - - :return: The requested_dates of this ProjectTemplateResponse. # noqa: E501 - :rtype: list[ProjectTemplateBaseRequestedDates] - """ - return self._requested_dates - - @requested_dates.setter - def requested_dates(self, requested_dates): - """Sets the requested_dates of this ProjectTemplateResponse. - - Array of date variables in this project template. Calendar dates must be provided for these variables when instantiating a project. # noqa: E501 - - :param requested_dates: The requested_dates of this ProjectTemplateResponse. # noqa: E501 - :type: list[ProjectTemplateBaseRequestedDates] - """ - - self._requested_dates = requested_dates - - @property - def color(self): - """Gets the color of this ProjectTemplateResponse. # noqa: E501 - - Color of the project template. # noqa: E501 - - :return: The color of this ProjectTemplateResponse. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this ProjectTemplateResponse. - - Color of the project template. # noqa: E501 - - :param color: The color of this ProjectTemplateResponse. # noqa: E501 - :type: str - """ - allowed_values = ["dark-pink", "dark-green", "dark-blue", "dark-red", "dark-teal", "dark-brown", "dark-orange", "dark-purple", "dark-warm-gray", "light-pink", "light-green", "light-blue", "light-red", "light-teal", "light-brown", "light-orange", "light-purple", "light-warm-gray", ""] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def requested_roles(self): - """Gets the requested_roles of this ProjectTemplateResponse. # noqa: E501 - - Array of template roles in this project template. User Ids can be provided for these variables when instantiating a project to assign template tasks to the user. # noqa: E501 - - :return: The requested_roles of this ProjectTemplateResponse. # noqa: E501 - :rtype: list[ProjectTemplateBaseRequestedRoles] - """ - return self._requested_roles - - @requested_roles.setter - def requested_roles(self, requested_roles): - """Sets the requested_roles of this ProjectTemplateResponse. - - Array of template roles in this project template. User Ids can be provided for these variables when instantiating a project to assign template tasks to the user. # noqa: E501 - - :param requested_roles: The requested_roles of this ProjectTemplateResponse. # noqa: E501 - :type: list[ProjectTemplateBaseRequestedRoles] - """ - - self._requested_roles = requested_roles - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectTemplateResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectTemplateResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_template_response_array.py b/asana/models/project_template_response_array.py deleted file mode 100644 index 034cb87b..00000000 --- a/asana/models/project_template_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectTemplateResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[ProjectTemplateResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """ProjectTemplateResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this ProjectTemplateResponseArray. # noqa: E501 - - - :return: The data of this ProjectTemplateResponseArray. # noqa: E501 - :rtype: list[ProjectTemplateResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectTemplateResponseArray. - - - :param data: The data of this ProjectTemplateResponseArray. # noqa: E501 - :type: list[ProjectTemplateResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this ProjectTemplateResponseArray. # noqa: E501 - - - :return: The next_page of this ProjectTemplateResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this ProjectTemplateResponseArray. - - - :param next_page: The next_page of this ProjectTemplateResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectTemplateResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectTemplateResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_template_response_data.py b/asana/models/project_template_response_data.py deleted file mode 100644 index f84c90ce..00000000 --- a/asana/models/project_template_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectTemplateResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectTemplateResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectTemplateResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this ProjectTemplateResponseData. # noqa: E501 - - - :return: The data of this ProjectTemplateResponseData. # noqa: E501 - :rtype: ProjectTemplateResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectTemplateResponseData. - - - :param data: The data of this ProjectTemplateResponseData. # noqa: E501 - :type: ProjectTemplateResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectTemplateResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectTemplateResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/project_update_request.py b/asana/models/project_update_request.py deleted file mode 100644 index 515bfd55..00000000 --- a/asana/models/project_update_request.py +++ /dev/null @@ -1,810 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectUpdateRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'archived': 'bool', - 'color': 'str', - 'created_at': 'datetime', - 'current_status': 'ProjectBaseCurrentStatus', - 'current_status_update': 'ProjectBaseCurrentStatusUpdate', - 'custom_field_settings': 'list[PortfolioResponseCustomFieldSettings]', - 'default_view': 'str', - 'due_date': 'date', - 'due_on': 'date', - 'html_notes': 'str', - 'members': 'list[CustomFieldResponsePeopleValue]', - 'modified_at': 'datetime', - 'notes': 'str', - 'public': 'bool', - 'start_on': 'date', - 'default_access_level': 'str', - 'minimum_access_level_for_customization': 'str', - 'minimum_access_level_for_sharing': 'str', - 'custom_fields': 'dict(str, str)', - 'followers': 'str', - 'owner': 'str', - 'team': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'archived': 'archived', - 'color': 'color', - 'created_at': 'created_at', - 'current_status': 'current_status', - 'current_status_update': 'current_status_update', - 'custom_field_settings': 'custom_field_settings', - 'default_view': 'default_view', - 'due_date': 'due_date', - 'due_on': 'due_on', - 'html_notes': 'html_notes', - 'members': 'members', - 'modified_at': 'modified_at', - 'notes': 'notes', - 'public': 'public', - 'start_on': 'start_on', - 'default_access_level': 'default_access_level', - 'minimum_access_level_for_customization': 'minimum_access_level_for_customization', - 'minimum_access_level_for_sharing': 'minimum_access_level_for_sharing', - 'custom_fields': 'custom_fields', - 'followers': 'followers', - 'owner': 'owner', - 'team': 'team' - } - - def __init__(self, gid=None, resource_type=None, name=None, archived=None, color=None, created_at=None, current_status=None, current_status_update=None, custom_field_settings=None, default_view=None, due_date=None, due_on=None, html_notes=None, members=None, modified_at=None, notes=None, public=None, start_on=None, default_access_level=None, minimum_access_level_for_customization=None, minimum_access_level_for_sharing=None, custom_fields=None, followers=None, owner=None, team=None): # noqa: E501 - """ProjectUpdateRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._archived = None - self._color = None - self._created_at = None - self._current_status = None - self._current_status_update = None - self._custom_field_settings = None - self._default_view = None - self._due_date = None - self._due_on = None - self._html_notes = None - self._members = None - self._modified_at = None - self._notes = None - self._public = None - self._start_on = None - self._default_access_level = None - self._minimum_access_level_for_customization = None - self._minimum_access_level_for_sharing = None - self._custom_fields = None - self._followers = None - self._owner = None - self._team = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if archived is not None: - self.archived = archived - if color is not None: - self.color = color - if created_at is not None: - self.created_at = created_at - if current_status is not None: - self.current_status = current_status - if current_status_update is not None: - self.current_status_update = current_status_update - if custom_field_settings is not None: - self.custom_field_settings = custom_field_settings - if default_view is not None: - self.default_view = default_view - if due_date is not None: - self.due_date = due_date - if due_on is not None: - self.due_on = due_on - if html_notes is not None: - self.html_notes = html_notes - if members is not None: - self.members = members - if modified_at is not None: - self.modified_at = modified_at - if notes is not None: - self.notes = notes - if public is not None: - self.public = public - if start_on is not None: - self.start_on = start_on - if default_access_level is not None: - self.default_access_level = default_access_level - if minimum_access_level_for_customization is not None: - self.minimum_access_level_for_customization = minimum_access_level_for_customization - if minimum_access_level_for_sharing is not None: - self.minimum_access_level_for_sharing = minimum_access_level_for_sharing - if custom_fields is not None: - self.custom_fields = custom_fields - if followers is not None: - self.followers = followers - if owner is not None: - self.owner = owner - if team is not None: - self.team = team - - @property - def gid(self): - """Gets the gid of this ProjectUpdateRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this ProjectUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this ProjectUpdateRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this ProjectUpdateRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this ProjectUpdateRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this ProjectUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this ProjectUpdateRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this ProjectUpdateRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this ProjectUpdateRequest. # noqa: E501 - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this ProjectUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this ProjectUpdateRequest. - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this ProjectUpdateRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def archived(self): - """Gets the archived of this ProjectUpdateRequest. # noqa: E501 - - True if the project is archived, false if not. Archived projects do not show in the UI by default and may be treated differently for queries. # noqa: E501 - - :return: The archived of this ProjectUpdateRequest. # noqa: E501 - :rtype: bool - """ - return self._archived - - @archived.setter - def archived(self, archived): - """Sets the archived of this ProjectUpdateRequest. - - True if the project is archived, false if not. Archived projects do not show in the UI by default and may be treated differently for queries. # noqa: E501 - - :param archived: The archived of this ProjectUpdateRequest. # noqa: E501 - :type: bool - """ - - self._archived = archived - - @property - def color(self): - """Gets the color of this ProjectUpdateRequest. # noqa: E501 - - Color of the project. # noqa: E501 - - :return: The color of this ProjectUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this ProjectUpdateRequest. - - Color of the project. # noqa: E501 - - :param color: The color of this ProjectUpdateRequest. # noqa: E501 - :type: str - """ - allowed_values = ["dark-pink", "dark-green", "dark-blue", "dark-red", "dark-teal", "dark-brown", "dark-orange", "dark-purple", "dark-warm-gray", "light-pink", "light-green", "light-blue", "light-red", "light-teal", "light-brown", "light-orange", "light-purple", "light-warm-gray", "none", ""] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def created_at(self): - """Gets the created_at of this ProjectUpdateRequest. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this ProjectUpdateRequest. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this ProjectUpdateRequest. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this ProjectUpdateRequest. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def current_status(self): - """Gets the current_status of this ProjectUpdateRequest. # noqa: E501 - - - :return: The current_status of this ProjectUpdateRequest. # noqa: E501 - :rtype: ProjectBaseCurrentStatus - """ - return self._current_status - - @current_status.setter - def current_status(self, current_status): - """Sets the current_status of this ProjectUpdateRequest. - - - :param current_status: The current_status of this ProjectUpdateRequest. # noqa: E501 - :type: ProjectBaseCurrentStatus - """ - - self._current_status = current_status - - @property - def current_status_update(self): - """Gets the current_status_update of this ProjectUpdateRequest. # noqa: E501 - - - :return: The current_status_update of this ProjectUpdateRequest. # noqa: E501 - :rtype: ProjectBaseCurrentStatusUpdate - """ - return self._current_status_update - - @current_status_update.setter - def current_status_update(self, current_status_update): - """Sets the current_status_update of this ProjectUpdateRequest. - - - :param current_status_update: The current_status_update of this ProjectUpdateRequest. # noqa: E501 - :type: ProjectBaseCurrentStatusUpdate - """ - - self._current_status_update = current_status_update - - @property - def custom_field_settings(self): - """Gets the custom_field_settings of this ProjectUpdateRequest. # noqa: E501 - - Array of Custom Field Settings (in compact form). # noqa: E501 - - :return: The custom_field_settings of this ProjectUpdateRequest. # noqa: E501 - :rtype: list[PortfolioResponseCustomFieldSettings] - """ - return self._custom_field_settings - - @custom_field_settings.setter - def custom_field_settings(self, custom_field_settings): - """Sets the custom_field_settings of this ProjectUpdateRequest. - - Array of Custom Field Settings (in compact form). # noqa: E501 - - :param custom_field_settings: The custom_field_settings of this ProjectUpdateRequest. # noqa: E501 - :type: list[PortfolioResponseCustomFieldSettings] - """ - - self._custom_field_settings = custom_field_settings - - @property - def default_view(self): - """Gets the default_view of this ProjectUpdateRequest. # noqa: E501 - - The default view (list, board, calendar, or timeline) of a project. # noqa: E501 - - :return: The default_view of this ProjectUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._default_view - - @default_view.setter - def default_view(self, default_view): - """Sets the default_view of this ProjectUpdateRequest. - - The default view (list, board, calendar, or timeline) of a project. # noqa: E501 - - :param default_view: The default_view of this ProjectUpdateRequest. # noqa: E501 - :type: str - """ - allowed_values = ["list", "board", "calendar", "timeline"] # noqa: E501 - if default_view not in allowed_values: - raise ValueError( - "Invalid value for `default_view` ({0}), must be one of {1}" # noqa: E501 - .format(default_view, allowed_values) - ) - - self._default_view = default_view - - @property - def due_date(self): - """Gets the due_date of this ProjectUpdateRequest. # noqa: E501 - - *Deprecated: new integrations should prefer the `due_on` field.* # noqa: E501 - - :return: The due_date of this ProjectUpdateRequest. # noqa: E501 - :rtype: date - """ - return self._due_date - - @due_date.setter - def due_date(self, due_date): - """Sets the due_date of this ProjectUpdateRequest. - - *Deprecated: new integrations should prefer the `due_on` field.* # noqa: E501 - - :param due_date: The due_date of this ProjectUpdateRequest. # noqa: E501 - :type: date - """ - - self._due_date = due_date - - @property - def due_on(self): - """Gets the due_on of this ProjectUpdateRequest. # noqa: E501 - - The day on which this project is due. This takes a date with format YYYY-MM-DD. # noqa: E501 - - :return: The due_on of this ProjectUpdateRequest. # noqa: E501 - :rtype: date - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this ProjectUpdateRequest. - - The day on which this project is due. This takes a date with format YYYY-MM-DD. # noqa: E501 - - :param due_on: The due_on of this ProjectUpdateRequest. # noqa: E501 - :type: date - """ - - self._due_on = due_on - - @property - def html_notes(self): - """Gets the html_notes of this ProjectUpdateRequest. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The notes of the project with formatting as HTML. # noqa: E501 - - :return: The html_notes of this ProjectUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._html_notes - - @html_notes.setter - def html_notes(self, html_notes): - """Sets the html_notes of this ProjectUpdateRequest. - - [Opt In](/docs/inputoutput-options). The notes of the project with formatting as HTML. # noqa: E501 - - :param html_notes: The html_notes of this ProjectUpdateRequest. # noqa: E501 - :type: str - """ - - self._html_notes = html_notes - - @property - def members(self): - """Gets the members of this ProjectUpdateRequest. # noqa: E501 - - Array of users who are members of this project. # noqa: E501 - - :return: The members of this ProjectUpdateRequest. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._members - - @members.setter - def members(self, members): - """Sets the members of this ProjectUpdateRequest. - - Array of users who are members of this project. # noqa: E501 - - :param members: The members of this ProjectUpdateRequest. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._members = members - - @property - def modified_at(self): - """Gets the modified_at of this ProjectUpdateRequest. # noqa: E501 - - The time at which this project was last modified. *Note: This does not currently reflect any changes in associations such as tasks or comments that may have been added or removed from the project.* # noqa: E501 - - :return: The modified_at of this ProjectUpdateRequest. # noqa: E501 - :rtype: datetime - """ - return self._modified_at - - @modified_at.setter - def modified_at(self, modified_at): - """Sets the modified_at of this ProjectUpdateRequest. - - The time at which this project was last modified. *Note: This does not currently reflect any changes in associations such as tasks or comments that may have been added or removed from the project.* # noqa: E501 - - :param modified_at: The modified_at of this ProjectUpdateRequest. # noqa: E501 - :type: datetime - """ - - self._modified_at = modified_at - - @property - def notes(self): - """Gets the notes of this ProjectUpdateRequest. # noqa: E501 - - Free-form textual information associated with the project (ie., its description). # noqa: E501 - - :return: The notes of this ProjectUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this ProjectUpdateRequest. - - Free-form textual information associated with the project (ie., its description). # noqa: E501 - - :param notes: The notes of this ProjectUpdateRequest. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def public(self): - """Gets the public of this ProjectUpdateRequest. # noqa: E501 - - True if the project is public to its team. # noqa: E501 - - :return: The public of this ProjectUpdateRequest. # noqa: E501 - :rtype: bool - """ - return self._public - - @public.setter - def public(self, public): - """Sets the public of this ProjectUpdateRequest. - - True if the project is public to its team. # noqa: E501 - - :param public: The public of this ProjectUpdateRequest. # noqa: E501 - :type: bool - """ - - self._public = public - - @property - def start_on(self): - """Gets the start_on of this ProjectUpdateRequest. # noqa: E501 - - The day on which work for this project begins, or null if the project has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* # noqa: E501 - - :return: The start_on of this ProjectUpdateRequest. # noqa: E501 - :rtype: date - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this ProjectUpdateRequest. - - The day on which work for this project begins, or null if the project has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* # noqa: E501 - - :param start_on: The start_on of this ProjectUpdateRequest. # noqa: E501 - :type: date - """ - - self._start_on = start_on - - @property - def default_access_level(self): - """Gets the default_access_level of this ProjectUpdateRequest. # noqa: E501 - - The default access for users or teams who join or are added as members to the project. # noqa: E501 - - :return: The default_access_level of this ProjectUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._default_access_level - - @default_access_level.setter - def default_access_level(self, default_access_level): - """Sets the default_access_level of this ProjectUpdateRequest. - - The default access for users or teams who join or are added as members to the project. # noqa: E501 - - :param default_access_level: The default_access_level of this ProjectUpdateRequest. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor", "commenter", "viewer"] # noqa: E501 - if default_access_level not in allowed_values: - raise ValueError( - "Invalid value for `default_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(default_access_level, allowed_values) - ) - - self._default_access_level = default_access_level - - @property - def minimum_access_level_for_customization(self): - """Gets the minimum_access_level_for_customization of this ProjectUpdateRequest. # noqa: E501 - - The minimum access level needed for project members to modify this project's workflow and appearance. # noqa: E501 - - :return: The minimum_access_level_for_customization of this ProjectUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._minimum_access_level_for_customization - - @minimum_access_level_for_customization.setter - def minimum_access_level_for_customization(self, minimum_access_level_for_customization): - """Sets the minimum_access_level_for_customization of this ProjectUpdateRequest. - - The minimum access level needed for project members to modify this project's workflow and appearance. # noqa: E501 - - :param minimum_access_level_for_customization: The minimum_access_level_for_customization of this ProjectUpdateRequest. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor"] # noqa: E501 - if minimum_access_level_for_customization not in allowed_values: - raise ValueError( - "Invalid value for `minimum_access_level_for_customization` ({0}), must be one of {1}" # noqa: E501 - .format(minimum_access_level_for_customization, allowed_values) - ) - - self._minimum_access_level_for_customization = minimum_access_level_for_customization - - @property - def minimum_access_level_for_sharing(self): - """Gets the minimum_access_level_for_sharing of this ProjectUpdateRequest. # noqa: E501 - - The minimum access level needed for project members to share the project and manage project memberships. # noqa: E501 - - :return: The minimum_access_level_for_sharing of this ProjectUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._minimum_access_level_for_sharing - - @minimum_access_level_for_sharing.setter - def minimum_access_level_for_sharing(self, minimum_access_level_for_sharing): - """Sets the minimum_access_level_for_sharing of this ProjectUpdateRequest. - - The minimum access level needed for project members to share the project and manage project memberships. # noqa: E501 - - :param minimum_access_level_for_sharing: The minimum_access_level_for_sharing of this ProjectUpdateRequest. # noqa: E501 - :type: str - """ - allowed_values = ["admin", "editor"] # noqa: E501 - if minimum_access_level_for_sharing not in allowed_values: - raise ValueError( - "Invalid value for `minimum_access_level_for_sharing` ({0}), must be one of {1}" # noqa: E501 - .format(minimum_access_level_for_sharing, allowed_values) - ) - - self._minimum_access_level_for_sharing = minimum_access_level_for_sharing - - @property - def custom_fields(self): - """Gets the custom_fields of this ProjectUpdateRequest. # noqa: E501 - - An object where each key is the GID of a custom field and its corresponding value is either an enum GID, string, number, or object (depending on the custom field type). See the [custom fields guide](/docs/custom-fields-guide) for details on creating and updating custom field values. # noqa: E501 - - :return: The custom_fields of this ProjectUpdateRequest. # noqa: E501 - :rtype: dict(str, str) - """ - return self._custom_fields - - @custom_fields.setter - def custom_fields(self, custom_fields): - """Sets the custom_fields of this ProjectUpdateRequest. - - An object where each key is the GID of a custom field and its corresponding value is either an enum GID, string, number, or object (depending on the custom field type). See the [custom fields guide](/docs/custom-fields-guide) for details on creating and updating custom field values. # noqa: E501 - - :param custom_fields: The custom_fields of this ProjectUpdateRequest. # noqa: E501 - :type: dict(str, str) - """ - - self._custom_fields = custom_fields - - @property - def followers(self): - """Gets the followers of this ProjectUpdateRequest. # noqa: E501 - - *Create-only*. Comma separated string of users. Followers are a subset of members who have opted in to receive \"tasks added\" notifications for a project. # noqa: E501 - - :return: The followers of this ProjectUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this ProjectUpdateRequest. - - *Create-only*. Comma separated string of users. Followers are a subset of members who have opted in to receive \"tasks added\" notifications for a project. # noqa: E501 - - :param followers: The followers of this ProjectUpdateRequest. # noqa: E501 - :type: str - """ - - self._followers = followers - - @property - def owner(self): - """Gets the owner of this ProjectUpdateRequest. # noqa: E501 - - The current owner of the project, may be null. # noqa: E501 - - :return: The owner of this ProjectUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this ProjectUpdateRequest. - - The current owner of the project, may be null. # noqa: E501 - - :param owner: The owner of this ProjectUpdateRequest. # noqa: E501 - :type: str - """ - - self._owner = owner - - @property - def team(self): - """Gets the team of this ProjectUpdateRequest. # noqa: E501 - - The team that this project is shared with. # noqa: E501 - - :return: The team of this ProjectUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this ProjectUpdateRequest. - - The team that this project is shared with. # noqa: E501 - - :param team: The team of this ProjectUpdateRequest. # noqa: E501 - :type: str - """ - - self._team = team - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectUpdateRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectUpdateRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/projects_body.py b/asana/models/projects_body.py deleted file mode 100644 index b78187f8..00000000 --- a/asana/models/projects_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectsBody. # noqa: E501 - - - :return: The data of this ProjectsBody. # noqa: E501 - :rtype: ProjectRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectsBody. - - - :param data: The data of this ProjectsBody. # noqa: E501 - :type: ProjectRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/projects_project_gid_body.py b/asana/models/projects_project_gid_body.py deleted file mode 100644 index a40adaa1..00000000 --- a/asana/models/projects_project_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class ProjectsProjectGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectUpdateRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """ProjectsProjectGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this ProjectsProjectGidBody. # noqa: E501 - - - :return: The data of this ProjectsProjectGidBody. # noqa: E501 - :rtype: ProjectUpdateRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this ProjectsProjectGidBody. - - - :param data: The data of this ProjectsProjectGidBody. # noqa: E501 - :type: ProjectUpdateRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(ProjectsProjectGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, ProjectsProjectGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/remove_custom_field_setting_request.py b/asana/models/remove_custom_field_setting_request.py deleted file mode 100644 index b1007e2e..00000000 --- a/asana/models/remove_custom_field_setting_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class RemoveCustomFieldSettingRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'custom_field': 'str' - } - - attribute_map = { - 'custom_field': 'custom_field' - } - - def __init__(self, custom_field=None): # noqa: E501 - """RemoveCustomFieldSettingRequest - a model defined in Swagger""" # noqa: E501 - self._custom_field = None - self.discriminator = None - self.custom_field = custom_field - - @property - def custom_field(self): - """Gets the custom_field of this RemoveCustomFieldSettingRequest. # noqa: E501 - - The custom field to remove from this portfolio. # noqa: E501 - - :return: The custom_field of this RemoveCustomFieldSettingRequest. # noqa: E501 - :rtype: str - """ - return self._custom_field - - @custom_field.setter - def custom_field(self, custom_field): - """Sets the custom_field of this RemoveCustomFieldSettingRequest. - - The custom field to remove from this portfolio. # noqa: E501 - - :param custom_field: The custom_field of this RemoveCustomFieldSettingRequest. # noqa: E501 - :type: str - """ - if custom_field is None: - raise ValueError("Invalid value for `custom_field`, must not be `None`") # noqa: E501 - - self._custom_field = custom_field - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(RemoveCustomFieldSettingRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, RemoveCustomFieldSettingRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/remove_followers_request.py b/asana/models/remove_followers_request.py deleted file mode 100644 index 70e9eb9b..00000000 --- a/asana/models/remove_followers_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class RemoveFollowersRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'followers': 'str' - } - - attribute_map = { - 'followers': 'followers' - } - - def __init__(self, followers=None): # noqa: E501 - """RemoveFollowersRequest - a model defined in Swagger""" # noqa: E501 - self._followers = None - self.discriminator = None - self.followers = followers - - @property - def followers(self): - """Gets the followers of this RemoveFollowersRequest. # noqa: E501 - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :return: The followers of this RemoveFollowersRequest. # noqa: E501 - :rtype: str - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this RemoveFollowersRequest. - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :param followers: The followers of this RemoveFollowersRequest. # noqa: E501 - :type: str - """ - if followers is None: - raise ValueError("Invalid value for `followers`, must not be `None`") # noqa: E501 - - self._followers = followers - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(RemoveFollowersRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, RemoveFollowersRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/remove_members_request.py b/asana/models/remove_members_request.py deleted file mode 100644 index 7a74f3bb..00000000 --- a/asana/models/remove_members_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class RemoveMembersRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'members': 'str' - } - - attribute_map = { - 'members': 'members' - } - - def __init__(self, members=None): # noqa: E501 - """RemoveMembersRequest - a model defined in Swagger""" # noqa: E501 - self._members = None - self.discriminator = None - self.members = members - - @property - def members(self): - """Gets the members of this RemoveMembersRequest. # noqa: E501 - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :return: The members of this RemoveMembersRequest. # noqa: E501 - :rtype: str - """ - return self._members - - @members.setter - def members(self, members): - """Sets the members of this RemoveMembersRequest. - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :param members: The members of this RemoveMembersRequest. # noqa: E501 - :type: str - """ - if members is None: - raise ValueError("Invalid value for `members`, must not be `None`") # noqa: E501 - - self._members = members - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(RemoveMembersRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, RemoveMembersRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/requested_role_request.py b/asana/models/requested_role_request.py deleted file mode 100644 index a45b1c2f..00000000 --- a/asana/models/requested_role_request.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class RequestedRoleRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'value': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'value': 'value' - } - - def __init__(self, gid=None, value=None): # noqa: E501 - """RequestedRoleRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._value = None - self.discriminator = None - if gid is not None: - self.gid = gid - if value is not None: - self.value = value - - @property - def gid(self): - """Gets the gid of this RequestedRoleRequest. # noqa: E501 - - Globally unique identifier of the template role in the project template. # noqa: E501 - - :return: The gid of this RequestedRoleRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this RequestedRoleRequest. - - Globally unique identifier of the template role in the project template. # noqa: E501 - - :param gid: The gid of this RequestedRoleRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def value(self): - """Gets the value of this RequestedRoleRequest. # noqa: E501 - - The user id that should be assigned to the template role. # noqa: E501 - - :return: The value of this RequestedRoleRequest. # noqa: E501 - :rtype: str - """ - return self._value - - @value.setter - def value(self, value): - """Sets the value of this RequestedRoleRequest. - - The user id that should be assigned to the template role. # noqa: E501 - - :param value: The value of this RequestedRoleRequest. # noqa: E501 - :type: str - """ - - self._value = value - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(RequestedRoleRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, RequestedRoleRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/rule_trigger_gid_run_body.py b/asana/models/rule_trigger_gid_run_body.py deleted file mode 100644 index 52bc874f..00000000 --- a/asana/models/rule_trigger_gid_run_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class RuleTriggerGidRunBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'RuleTriggerRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """RuleTriggerGidRunBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this RuleTriggerGidRunBody. # noqa: E501 - - - :return: The data of this RuleTriggerGidRunBody. # noqa: E501 - :rtype: RuleTriggerRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this RuleTriggerGidRunBody. - - - :param data: The data of this RuleTriggerGidRunBody. # noqa: E501 - :type: RuleTriggerRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(RuleTriggerGidRunBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, RuleTriggerGidRunBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/rule_trigger_request.py b/asana/models/rule_trigger_request.py deleted file mode 100644 index d2206316..00000000 --- a/asana/models/rule_trigger_request.py +++ /dev/null @@ -1,142 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class RuleTriggerRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'resource': 'str', - 'action_data': 'dict(str, object)' - } - - attribute_map = { - 'resource': 'resource', - 'action_data': 'action_data' - } - - def __init__(self, resource=None, action_data=None): # noqa: E501 - """RuleTriggerRequest - a model defined in Swagger""" # noqa: E501 - self._resource = None - self._action_data = None - self.discriminator = None - self.resource = resource - self.action_data = action_data - - @property - def resource(self): - """Gets the resource of this RuleTriggerRequest. # noqa: E501 - - The ID of the resource. For the duration of the beta, this resource is always a task, and this task must exist in the project in which the rule is created. # noqa: E501 - - :return: The resource of this RuleTriggerRequest. # noqa: E501 - :rtype: str - """ - return self._resource - - @resource.setter - def resource(self, resource): - """Sets the resource of this RuleTriggerRequest. - - The ID of the resource. For the duration of the beta, this resource is always a task, and this task must exist in the project in which the rule is created. # noqa: E501 - - :param resource: The resource of this RuleTriggerRequest. # noqa: E501 - :type: str - """ - if resource is None: - raise ValueError("Invalid value for `resource`, must not be `None`") # noqa: E501 - - self._resource = resource - - @property - def action_data(self): - """Gets the action_data of this RuleTriggerRequest. # noqa: E501 - - The dynamic keys and values of the request. These fields are intended to be used in the action for the rule associated with this trigger. # noqa: E501 - - :return: The action_data of this RuleTriggerRequest. # noqa: E501 - :rtype: dict(str, object) - """ - return self._action_data - - @action_data.setter - def action_data(self, action_data): - """Sets the action_data of this RuleTriggerRequest. - - The dynamic keys and values of the request. These fields are intended to be used in the action for the rule associated with this trigger. # noqa: E501 - - :param action_data: The action_data of this RuleTriggerRequest. # noqa: E501 - :type: dict(str, object) - """ - if action_data is None: - raise ValueError("Invalid value for `action_data`, must not be `None`") # noqa: E501 - - self._action_data = action_data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(RuleTriggerRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, RuleTriggerRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/rule_trigger_response.py b/asana/models/rule_trigger_response.py deleted file mode 100644 index 7b417409..00000000 --- a/asana/models/rule_trigger_response.py +++ /dev/null @@ -1,112 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class RuleTriggerResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'message': 'str' - } - - attribute_map = { - 'message': 'message' - } - - def __init__(self, message=None): # noqa: E501 - """RuleTriggerResponse - a model defined in Swagger""" # noqa: E501 - self._message = None - self.discriminator = None - if message is not None: - self.message = message - - @property - def message(self): - """Gets the message of this RuleTriggerResponse. # noqa: E501 - - Message providing more detail about the result # noqa: E501 - - :return: The message of this RuleTriggerResponse. # noqa: E501 - :rtype: str - """ - return self._message - - @message.setter - def message(self, message): - """Sets the message of this RuleTriggerResponse. - - Message providing more detail about the result # noqa: E501 - - :param message: The message of this RuleTriggerResponse. # noqa: E501 - :type: str - """ - - self._message = message - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(RuleTriggerResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, RuleTriggerResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/rule_trigger_response_data.py b/asana/models/rule_trigger_response_data.py deleted file mode 100644 index e2c1a3a0..00000000 --- a/asana/models/rule_trigger_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class RuleTriggerResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'RuleTriggerResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """RuleTriggerResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this RuleTriggerResponseData. # noqa: E501 - - - :return: The data of this RuleTriggerResponseData. # noqa: E501 - :rtype: RuleTriggerResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this RuleTriggerResponseData. - - - :param data: The data of this RuleTriggerResponseData. # noqa: E501 - :type: RuleTriggerResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(RuleTriggerResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, RuleTriggerResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/section_base.py b/asana/models/section_base.py deleted file mode 100644 index e6b57738..00000000 --- a/asana/models/section_base.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class SectionBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """SectionBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this SectionBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this SectionBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this SectionBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this SectionBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this SectionBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this SectionBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this SectionBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this SectionBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this SectionBase. # noqa: E501 - - The name of the section (i.e. the text displayed as the section header). # noqa: E501 - - :return: The name of this SectionBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this SectionBase. - - The name of the section (i.e. the text displayed as the section header). # noqa: E501 - - :param name: The name of this SectionBase. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(SectionBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, SectionBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/section_compact.py b/asana/models/section_compact.py deleted file mode 100644 index d7dfd255..00000000 --- a/asana/models/section_compact.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class SectionCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """SectionCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this SectionCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this SectionCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this SectionCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this SectionCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this SectionCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this SectionCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this SectionCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this SectionCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this SectionCompact. # noqa: E501 - - The name of the section (i.e. the text displayed as the section header). # noqa: E501 - - :return: The name of this SectionCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this SectionCompact. - - The name of the section (i.e. the text displayed as the section header). # noqa: E501 - - :param name: The name of this SectionCompact. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(SectionCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, SectionCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/section_gid_add_task_body.py b/asana/models/section_gid_add_task_body.py deleted file mode 100644 index eed1015c..00000000 --- a/asana/models/section_gid_add_task_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class SectionGidAddTaskBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'SectionTaskInsertRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """SectionGidAddTaskBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this SectionGidAddTaskBody. # noqa: E501 - - - :return: The data of this SectionGidAddTaskBody. # noqa: E501 - :rtype: SectionTaskInsertRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this SectionGidAddTaskBody. - - - :param data: The data of this SectionGidAddTaskBody. # noqa: E501 - :type: SectionTaskInsertRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(SectionGidAddTaskBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, SectionGidAddTaskBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/section_request.py b/asana/models/section_request.py deleted file mode 100644 index eba513d4..00000000 --- a/asana/models/section_request.py +++ /dev/null @@ -1,169 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class SectionRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'name': 'str', - 'insert_before': 'str', - 'insert_after': 'str' - } - - attribute_map = { - 'name': 'name', - 'insert_before': 'insert_before', - 'insert_after': 'insert_after' - } - - def __init__(self, name=None, insert_before=None, insert_after=None): # noqa: E501 - """SectionRequest - a model defined in Swagger""" # noqa: E501 - self._name = None - self._insert_before = None - self._insert_after = None - self.discriminator = None - self.name = name - if insert_before is not None: - self.insert_before = insert_before - if insert_after is not None: - self.insert_after = insert_after - - @property - def name(self): - """Gets the name of this SectionRequest. # noqa: E501 - - The text to be displayed as the section name. This cannot be an empty string. # noqa: E501 - - :return: The name of this SectionRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this SectionRequest. - - The text to be displayed as the section name. This cannot be an empty string. # noqa: E501 - - :param name: The name of this SectionRequest. # noqa: E501 - :type: str - """ - if name is None: - raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 - - self._name = name - - @property - def insert_before(self): - """Gets the insert_before of this SectionRequest. # noqa: E501 - - An existing section within this project before which the added section should be inserted. Cannot be provided together with insert_after. # noqa: E501 - - :return: The insert_before of this SectionRequest. # noqa: E501 - :rtype: str - """ - return self._insert_before - - @insert_before.setter - def insert_before(self, insert_before): - """Sets the insert_before of this SectionRequest. - - An existing section within this project before which the added section should be inserted. Cannot be provided together with insert_after. # noqa: E501 - - :param insert_before: The insert_before of this SectionRequest. # noqa: E501 - :type: str - """ - - self._insert_before = insert_before - - @property - def insert_after(self): - """Gets the insert_after of this SectionRequest. # noqa: E501 - - An existing section within this project after which the added section should be inserted. Cannot be provided together with insert_before. # noqa: E501 - - :return: The insert_after of this SectionRequest. # noqa: E501 - :rtype: str - """ - return self._insert_after - - @insert_after.setter - def insert_after(self, insert_after): - """Sets the insert_after of this SectionRequest. - - An existing section within this project after which the added section should be inserted. Cannot be provided together with insert_before. # noqa: E501 - - :param insert_after: The insert_after of this SectionRequest. # noqa: E501 - :type: str - """ - - self._insert_after = insert_after - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(SectionRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, SectionRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/section_response.py b/asana/models/section_response.py deleted file mode 100644 index 42dbf1f9..00000000 --- a/asana/models/section_response.py +++ /dev/null @@ -1,250 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class SectionResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'created_at': 'datetime', - 'project': 'JobBaseNewProject', - 'projects': 'list[JobBaseNewProject]' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'created_at': 'created_at', - 'project': 'project', - 'projects': 'projects' - } - - def __init__(self, gid=None, resource_type=None, name=None, created_at=None, project=None, projects=None): # noqa: E501 - """SectionResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._created_at = None - self._project = None - self._projects = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if created_at is not None: - self.created_at = created_at - if project is not None: - self.project = project - if projects is not None: - self.projects = projects - - @property - def gid(self): - """Gets the gid of this SectionResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this SectionResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this SectionResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this SectionResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this SectionResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this SectionResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this SectionResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this SectionResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this SectionResponse. # noqa: E501 - - The name of the section (i.e. the text displayed as the section header). # noqa: E501 - - :return: The name of this SectionResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this SectionResponse. - - The name of the section (i.e. the text displayed as the section header). # noqa: E501 - - :param name: The name of this SectionResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def created_at(self): - """Gets the created_at of this SectionResponse. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this SectionResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this SectionResponse. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this SectionResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def project(self): - """Gets the project of this SectionResponse. # noqa: E501 - - - :return: The project of this SectionResponse. # noqa: E501 - :rtype: JobBaseNewProject - """ - return self._project - - @project.setter - def project(self, project): - """Sets the project of this SectionResponse. - - - :param project: The project of this SectionResponse. # noqa: E501 - :type: JobBaseNewProject - """ - - self._project = project - - @property - def projects(self): - """Gets the projects of this SectionResponse. # noqa: E501 - - *Deprecated - please use project instead* # noqa: E501 - - :return: The projects of this SectionResponse. # noqa: E501 - :rtype: list[JobBaseNewProject] - """ - return self._projects - - @projects.setter - def projects(self, projects): - """Sets the projects of this SectionResponse. - - *Deprecated - please use project instead* # noqa: E501 - - :param projects: The projects of this SectionResponse. # noqa: E501 - :type: list[JobBaseNewProject] - """ - - self._projects = projects - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(SectionResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, SectionResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/section_response_array.py b/asana/models/section_response_array.py deleted file mode 100644 index 54a59f39..00000000 --- a/asana/models/section_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class SectionResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[SectionResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """SectionResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this SectionResponseArray. # noqa: E501 - - - :return: The data of this SectionResponseArray. # noqa: E501 - :rtype: list[SectionResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this SectionResponseArray. - - - :param data: The data of this SectionResponseArray. # noqa: E501 - :type: list[SectionResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this SectionResponseArray. # noqa: E501 - - - :return: The next_page of this SectionResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this SectionResponseArray. - - - :param next_page: The next_page of this SectionResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(SectionResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, SectionResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/section_response_data.py b/asana/models/section_response_data.py deleted file mode 100644 index cf9b782c..00000000 --- a/asana/models/section_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class SectionResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'SectionResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """SectionResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this SectionResponseData. # noqa: E501 - - - :return: The data of this SectionResponseData. # noqa: E501 - :rtype: SectionResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this SectionResponseData. - - - :param data: The data of this SectionResponseData. # noqa: E501 - :type: SectionResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(SectionResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, SectionResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/section_task_insert_request.py b/asana/models/section_task_insert_request.py deleted file mode 100644 index 59b2fe36..00000000 --- a/asana/models/section_task_insert_request.py +++ /dev/null @@ -1,169 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class SectionTaskInsertRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'task': 'str', - 'insert_before': 'str', - 'insert_after': 'str' - } - - attribute_map = { - 'task': 'task', - 'insert_before': 'insert_before', - 'insert_after': 'insert_after' - } - - def __init__(self, task=None, insert_before=None, insert_after=None): # noqa: E501 - """SectionTaskInsertRequest - a model defined in Swagger""" # noqa: E501 - self._task = None - self._insert_before = None - self._insert_after = None - self.discriminator = None - self.task = task - if insert_before is not None: - self.insert_before = insert_before - if insert_after is not None: - self.insert_after = insert_after - - @property - def task(self): - """Gets the task of this SectionTaskInsertRequest. # noqa: E501 - - The task to add to this section. # noqa: E501 - - :return: The task of this SectionTaskInsertRequest. # noqa: E501 - :rtype: str - """ - return self._task - - @task.setter - def task(self, task): - """Sets the task of this SectionTaskInsertRequest. - - The task to add to this section. # noqa: E501 - - :param task: The task of this SectionTaskInsertRequest. # noqa: E501 - :type: str - """ - if task is None: - raise ValueError("Invalid value for `task`, must not be `None`") # noqa: E501 - - self._task = task - - @property - def insert_before(self): - """Gets the insert_before of this SectionTaskInsertRequest. # noqa: E501 - - An existing task within this section before which the added task should be inserted. Cannot be provided together with insert_after. # noqa: E501 - - :return: The insert_before of this SectionTaskInsertRequest. # noqa: E501 - :rtype: str - """ - return self._insert_before - - @insert_before.setter - def insert_before(self, insert_before): - """Sets the insert_before of this SectionTaskInsertRequest. - - An existing task within this section before which the added task should be inserted. Cannot be provided together with insert_after. # noqa: E501 - - :param insert_before: The insert_before of this SectionTaskInsertRequest. # noqa: E501 - :type: str - """ - - self._insert_before = insert_before - - @property - def insert_after(self): - """Gets the insert_after of this SectionTaskInsertRequest. # noqa: E501 - - An existing task within this section after which the added task should be inserted. Cannot be provided together with insert_before. # noqa: E501 - - :return: The insert_after of this SectionTaskInsertRequest. # noqa: E501 - :rtype: str - """ - return self._insert_after - - @insert_after.setter - def insert_after(self, insert_after): - """Sets the insert_after of this SectionTaskInsertRequest. - - An existing task within this section after which the added task should be inserted. Cannot be provided together with insert_before. # noqa: E501 - - :param insert_after: The insert_after of this SectionTaskInsertRequest. # noqa: E501 - :type: str - """ - - self._insert_after = insert_after - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(SectionTaskInsertRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, SectionTaskInsertRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/sections_insert_body.py b/asana/models/sections_insert_body.py deleted file mode 100644 index 97430558..00000000 --- a/asana/models/sections_insert_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class SectionsInsertBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectSectionInsertRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """SectionsInsertBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this SectionsInsertBody. # noqa: E501 - - - :return: The data of this SectionsInsertBody. # noqa: E501 - :rtype: ProjectSectionInsertRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this SectionsInsertBody. - - - :param data: The data of this SectionsInsertBody. # noqa: E501 - :type: ProjectSectionInsertRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(SectionsInsertBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, SectionsInsertBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/sections_section_gid_body.py b/asana/models/sections_section_gid_body.py deleted file mode 100644 index 1dfaa021..00000000 --- a/asana/models/sections_section_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class SectionsSectionGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'SectionRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """SectionsSectionGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this SectionsSectionGidBody. # noqa: E501 - - - :return: The data of this SectionsSectionGidBody. # noqa: E501 - :rtype: SectionRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this SectionsSectionGidBody. - - - :param data: The data of this SectionsSectionGidBody. # noqa: E501 - :type: SectionRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(SectionsSectionGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, SectionsSectionGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/status_update_base.py b/asana/models/status_update_base.py deleted file mode 100644 index 178f7acf..00000000 --- a/asana/models/status_update_base.py +++ /dev/null @@ -1,294 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StatusUpdateBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'resource_subtype': 'str', - 'text': 'str', - 'html_text': 'str', - 'status_type': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'resource_subtype': 'resource_subtype', - 'text': 'text', - 'html_text': 'html_text', - 'status_type': 'status_type' - } - - def __init__(self, gid=None, resource_type=None, title=None, resource_subtype=None, text=None, html_text=None, status_type=None): # noqa: E501 - """StatusUpdateBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._resource_subtype = None - self._text = None - self._html_text = None - self._status_type = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if resource_subtype is not None: - self.resource_subtype = resource_subtype - self.text = text - if html_text is not None: - self.html_text = html_text - self.status_type = status_type - - @property - def gid(self): - """Gets the gid of this StatusUpdateBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StatusUpdateBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StatusUpdateBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StatusUpdateBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StatusUpdateBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StatusUpdateBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StatusUpdateBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StatusUpdateBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this StatusUpdateBase. # noqa: E501 - - The title of the status update. # noqa: E501 - - :return: The title of this StatusUpdateBase. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this StatusUpdateBase. - - The title of the status update. # noqa: E501 - - :param title: The title of this StatusUpdateBase. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def resource_subtype(self): - """Gets the resource_subtype of this StatusUpdateBase. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :return: The resource_subtype of this StatusUpdateBase. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this StatusUpdateBase. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :param resource_subtype: The resource_subtype of this StatusUpdateBase. # noqa: E501 - :type: str - """ - allowed_values = ["project_status_update", "portfolio_status_update", "goal_status_update"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def text(self): - """Gets the text of this StatusUpdateBase. # noqa: E501 - - The text content of the status update. # noqa: E501 - - :return: The text of this StatusUpdateBase. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this StatusUpdateBase. - - The text content of the status update. # noqa: E501 - - :param text: The text of this StatusUpdateBase. # noqa: E501 - :type: str - """ - if text is None: - raise ValueError("Invalid value for `text`, must not be `None`") # noqa: E501 - - self._text = text - - @property - def html_text(self): - """Gets the html_text of this StatusUpdateBase. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :return: The html_text of this StatusUpdateBase. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this StatusUpdateBase. - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :param html_text: The html_text of this StatusUpdateBase. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def status_type(self): - """Gets the status_type of this StatusUpdateBase. # noqa: E501 - - The type associated with the status update. This represents the current state of the object this object is on. # noqa: E501 - - :return: The status_type of this StatusUpdateBase. # noqa: E501 - :rtype: str - """ - return self._status_type - - @status_type.setter - def status_type(self, status_type): - """Sets the status_type of this StatusUpdateBase. - - The type associated with the status update. This represents the current state of the object this object is on. # noqa: E501 - - :param status_type: The status_type of this StatusUpdateBase. # noqa: E501 - :type: str - """ - if status_type is None: - raise ValueError("Invalid value for `status_type`, must not be `None`") # noqa: E501 - allowed_values = ["on_track", "at_risk", "off_track", "on_hold", "complete", "achieved", "partial", "missed", "dropped"] # noqa: E501 - if status_type not in allowed_values: - raise ValueError( - "Invalid value for `status_type` ({0}), must be one of {1}" # noqa: E501 - .format(status_type, allowed_values) - ) - - self._status_type = status_type - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StatusUpdateBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StatusUpdateBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/status_update_compact.py b/asana/models/status_update_compact.py deleted file mode 100644 index 82cde53b..00000000 --- a/asana/models/status_update_compact.py +++ /dev/null @@ -1,202 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StatusUpdateCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'resource_subtype': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'resource_subtype': 'resource_subtype' - } - - def __init__(self, gid=None, resource_type=None, title=None, resource_subtype=None): # noqa: E501 - """StatusUpdateCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._resource_subtype = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if resource_subtype is not None: - self.resource_subtype = resource_subtype - - @property - def gid(self): - """Gets the gid of this StatusUpdateCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StatusUpdateCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StatusUpdateCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StatusUpdateCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StatusUpdateCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StatusUpdateCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StatusUpdateCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StatusUpdateCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this StatusUpdateCompact. # noqa: E501 - - The title of the status update. # noqa: E501 - - :return: The title of this StatusUpdateCompact. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this StatusUpdateCompact. - - The title of the status update. # noqa: E501 - - :param title: The title of this StatusUpdateCompact. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def resource_subtype(self): - """Gets the resource_subtype of this StatusUpdateCompact. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :return: The resource_subtype of this StatusUpdateCompact. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this StatusUpdateCompact. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :param resource_subtype: The resource_subtype of this StatusUpdateCompact. # noqa: E501 - :type: str - """ - allowed_values = ["project_status_update", "portfolio_status_update", "goal_status_update"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StatusUpdateCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StatusUpdateCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/status_update_request.py b/asana/models/status_update_request.py deleted file mode 100644 index 9ddb8108..00000000 --- a/asana/models/status_update_request.py +++ /dev/null @@ -1,323 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StatusUpdateRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'resource_subtype': 'str', - 'text': 'str', - 'html_text': 'str', - 'status_type': 'str', - 'parent': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'resource_subtype': 'resource_subtype', - 'text': 'text', - 'html_text': 'html_text', - 'status_type': 'status_type', - 'parent': 'parent' - } - - def __init__(self, gid=None, resource_type=None, title=None, resource_subtype=None, text=None, html_text=None, status_type=None, parent=None): # noqa: E501 - """StatusUpdateRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._resource_subtype = None - self._text = None - self._html_text = None - self._status_type = None - self._parent = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if resource_subtype is not None: - self.resource_subtype = resource_subtype - self.text = text - if html_text is not None: - self.html_text = html_text - self.status_type = status_type - self.parent = parent - - @property - def gid(self): - """Gets the gid of this StatusUpdateRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StatusUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StatusUpdateRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StatusUpdateRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StatusUpdateRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StatusUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StatusUpdateRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StatusUpdateRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this StatusUpdateRequest. # noqa: E501 - - The title of the status update. # noqa: E501 - - :return: The title of this StatusUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this StatusUpdateRequest. - - The title of the status update. # noqa: E501 - - :param title: The title of this StatusUpdateRequest. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def resource_subtype(self): - """Gets the resource_subtype of this StatusUpdateRequest. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :return: The resource_subtype of this StatusUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this StatusUpdateRequest. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :param resource_subtype: The resource_subtype of this StatusUpdateRequest. # noqa: E501 - :type: str - """ - allowed_values = ["project_status_update", "portfolio_status_update", "goal_status_update"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def text(self): - """Gets the text of this StatusUpdateRequest. # noqa: E501 - - The text content of the status update. # noqa: E501 - - :return: The text of this StatusUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this StatusUpdateRequest. - - The text content of the status update. # noqa: E501 - - :param text: The text of this StatusUpdateRequest. # noqa: E501 - :type: str - """ - if text is None: - raise ValueError("Invalid value for `text`, must not be `None`") # noqa: E501 - - self._text = text - - @property - def html_text(self): - """Gets the html_text of this StatusUpdateRequest. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :return: The html_text of this StatusUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this StatusUpdateRequest. - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :param html_text: The html_text of this StatusUpdateRequest. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def status_type(self): - """Gets the status_type of this StatusUpdateRequest. # noqa: E501 - - The type associated with the status update. This represents the current state of the object this object is on. # noqa: E501 - - :return: The status_type of this StatusUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._status_type - - @status_type.setter - def status_type(self, status_type): - """Sets the status_type of this StatusUpdateRequest. - - The type associated with the status update. This represents the current state of the object this object is on. # noqa: E501 - - :param status_type: The status_type of this StatusUpdateRequest. # noqa: E501 - :type: str - """ - if status_type is None: - raise ValueError("Invalid value for `status_type`, must not be `None`") # noqa: E501 - allowed_values = ["on_track", "at_risk", "off_track", "on_hold", "complete", "achieved", "partial", "missed", "dropped"] # noqa: E501 - if status_type not in allowed_values: - raise ValueError( - "Invalid value for `status_type` ({0}), must be one of {1}" # noqa: E501 - .format(status_type, allowed_values) - ) - - self._status_type = status_type - - @property - def parent(self): - """Gets the parent of this StatusUpdateRequest. # noqa: E501 - - The id of parent to send this status update to. This can be a project, goal or portfolio. # noqa: E501 - - :return: The parent of this StatusUpdateRequest. # noqa: E501 - :rtype: str - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this StatusUpdateRequest. - - The id of parent to send this status update to. This can be a project, goal or portfolio. # noqa: E501 - - :param parent: The parent of this StatusUpdateRequest. # noqa: E501 - :type: str - """ - if parent is None: - raise ValueError("Invalid value for `parent`, must not be `None`") # noqa: E501 - - self._parent = parent - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StatusUpdateRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StatusUpdateRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/status_update_response.py b/asana/models/status_update_response.py deleted file mode 100644 index cb0d0838..00000000 --- a/asana/models/status_update_response.py +++ /dev/null @@ -1,596 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StatusUpdateResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'title': 'str', - 'resource_subtype': 'str', - 'text': 'str', - 'html_text': 'str', - 'status_type': 'str', - 'author': 'CustomFieldResponsePeopleValue', - 'created_at': 'datetime', - 'created_by': 'CustomFieldResponsePeopleValue', - 'hearted': 'bool', - 'hearts': 'list[GoalResponseLikes]', - 'liked': 'bool', - 'likes': 'list[GoalResponseLikes]', - 'modified_at': 'datetime', - 'num_hearts': 'int', - 'num_likes': 'int', - 'parent': 'StatusUpdateResponseParent' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'title': 'title', - 'resource_subtype': 'resource_subtype', - 'text': 'text', - 'html_text': 'html_text', - 'status_type': 'status_type', - 'author': 'author', - 'created_at': 'created_at', - 'created_by': 'created_by', - 'hearted': 'hearted', - 'hearts': 'hearts', - 'liked': 'liked', - 'likes': 'likes', - 'modified_at': 'modified_at', - 'num_hearts': 'num_hearts', - 'num_likes': 'num_likes', - 'parent': 'parent' - } - - def __init__(self, gid=None, resource_type=None, title=None, resource_subtype=None, text=None, html_text=None, status_type=None, author=None, created_at=None, created_by=None, hearted=None, hearts=None, liked=None, likes=None, modified_at=None, num_hearts=None, num_likes=None, parent=None): # noqa: E501 - """StatusUpdateResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._title = None - self._resource_subtype = None - self._text = None - self._html_text = None - self._status_type = None - self._author = None - self._created_at = None - self._created_by = None - self._hearted = None - self._hearts = None - self._liked = None - self._likes = None - self._modified_at = None - self._num_hearts = None - self._num_likes = None - self._parent = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if title is not None: - self.title = title - if resource_subtype is not None: - self.resource_subtype = resource_subtype - self.text = text - if html_text is not None: - self.html_text = html_text - self.status_type = status_type - if author is not None: - self.author = author - if created_at is not None: - self.created_at = created_at - if created_by is not None: - self.created_by = created_by - if hearted is not None: - self.hearted = hearted - if hearts is not None: - self.hearts = hearts - if liked is not None: - self.liked = liked - if likes is not None: - self.likes = likes - if modified_at is not None: - self.modified_at = modified_at - if num_hearts is not None: - self.num_hearts = num_hearts - if num_likes is not None: - self.num_likes = num_likes - if parent is not None: - self.parent = parent - - @property - def gid(self): - """Gets the gid of this StatusUpdateResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StatusUpdateResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StatusUpdateResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StatusUpdateResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StatusUpdateResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StatusUpdateResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StatusUpdateResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StatusUpdateResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def title(self): - """Gets the title of this StatusUpdateResponse. # noqa: E501 - - The title of the status update. # noqa: E501 - - :return: The title of this StatusUpdateResponse. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this StatusUpdateResponse. - - The title of the status update. # noqa: E501 - - :param title: The title of this StatusUpdateResponse. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def resource_subtype(self): - """Gets the resource_subtype of this StatusUpdateResponse. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :return: The resource_subtype of this StatusUpdateResponse. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this StatusUpdateResponse. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. # noqa: E501 - - :param resource_subtype: The resource_subtype of this StatusUpdateResponse. # noqa: E501 - :type: str - """ - allowed_values = ["project_status_update", "portfolio_status_update", "goal_status_update"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def text(self): - """Gets the text of this StatusUpdateResponse. # noqa: E501 - - The text content of the status update. # noqa: E501 - - :return: The text of this StatusUpdateResponse. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this StatusUpdateResponse. - - The text content of the status update. # noqa: E501 - - :param text: The text of this StatusUpdateResponse. # noqa: E501 - :type: str - """ - if text is None: - raise ValueError("Invalid value for `text`, must not be `None`") # noqa: E501 - - self._text = text - - @property - def html_text(self): - """Gets the html_text of this StatusUpdateResponse. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :return: The html_text of this StatusUpdateResponse. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this StatusUpdateResponse. - - [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. # noqa: E501 - - :param html_text: The html_text of this StatusUpdateResponse. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def status_type(self): - """Gets the status_type of this StatusUpdateResponse. # noqa: E501 - - The type associated with the status update. This represents the current state of the object this object is on. # noqa: E501 - - :return: The status_type of this StatusUpdateResponse. # noqa: E501 - :rtype: str - """ - return self._status_type - - @status_type.setter - def status_type(self, status_type): - """Sets the status_type of this StatusUpdateResponse. - - The type associated with the status update. This represents the current state of the object this object is on. # noqa: E501 - - :param status_type: The status_type of this StatusUpdateResponse. # noqa: E501 - :type: str - """ - if status_type is None: - raise ValueError("Invalid value for `status_type`, must not be `None`") # noqa: E501 - allowed_values = ["on_track", "at_risk", "off_track", "on_hold", "complete", "achieved", "partial", "missed", "dropped"] # noqa: E501 - if status_type not in allowed_values: - raise ValueError( - "Invalid value for `status_type` ({0}), must be one of {1}" # noqa: E501 - .format(status_type, allowed_values) - ) - - self._status_type = status_type - - @property - def author(self): - """Gets the author of this StatusUpdateResponse. # noqa: E501 - - - :return: The author of this StatusUpdateResponse. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._author - - @author.setter - def author(self, author): - """Sets the author of this StatusUpdateResponse. - - - :param author: The author of this StatusUpdateResponse. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._author = author - - @property - def created_at(self): - """Gets the created_at of this StatusUpdateResponse. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this StatusUpdateResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this StatusUpdateResponse. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this StatusUpdateResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def created_by(self): - """Gets the created_by of this StatusUpdateResponse. # noqa: E501 - - - :return: The created_by of this StatusUpdateResponse. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this StatusUpdateResponse. - - - :param created_by: The created_by of this StatusUpdateResponse. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._created_by = created_by - - @property - def hearted(self): - """Gets the hearted of this StatusUpdateResponse. # noqa: E501 - - *Deprecated - please use liked instead* True if the status is hearted by the authorized user, false if not. # noqa: E501 - - :return: The hearted of this StatusUpdateResponse. # noqa: E501 - :rtype: bool - """ - return self._hearted - - @hearted.setter - def hearted(self, hearted): - """Sets the hearted of this StatusUpdateResponse. - - *Deprecated - please use liked instead* True if the status is hearted by the authorized user, false if not. # noqa: E501 - - :param hearted: The hearted of this StatusUpdateResponse. # noqa: E501 - :type: bool - """ - - self._hearted = hearted - - @property - def hearts(self): - """Gets the hearts of this StatusUpdateResponse. # noqa: E501 - - *Deprecated - please use likes instead* Array of likes for users who have hearted this status. # noqa: E501 - - :return: The hearts of this StatusUpdateResponse. # noqa: E501 - :rtype: list[GoalResponseLikes] - """ - return self._hearts - - @hearts.setter - def hearts(self, hearts): - """Sets the hearts of this StatusUpdateResponse. - - *Deprecated - please use likes instead* Array of likes for users who have hearted this status. # noqa: E501 - - :param hearts: The hearts of this StatusUpdateResponse. # noqa: E501 - :type: list[GoalResponseLikes] - """ - - self._hearts = hearts - - @property - def liked(self): - """Gets the liked of this StatusUpdateResponse. # noqa: E501 - - True if the status is liked by the authorized user, false if not. # noqa: E501 - - :return: The liked of this StatusUpdateResponse. # noqa: E501 - :rtype: bool - """ - return self._liked - - @liked.setter - def liked(self, liked): - """Sets the liked of this StatusUpdateResponse. - - True if the status is liked by the authorized user, false if not. # noqa: E501 - - :param liked: The liked of this StatusUpdateResponse. # noqa: E501 - :type: bool - """ - - self._liked = liked - - @property - def likes(self): - """Gets the likes of this StatusUpdateResponse. # noqa: E501 - - Array of likes for users who have liked this status. # noqa: E501 - - :return: The likes of this StatusUpdateResponse. # noqa: E501 - :rtype: list[GoalResponseLikes] - """ - return self._likes - - @likes.setter - def likes(self, likes): - """Sets the likes of this StatusUpdateResponse. - - Array of likes for users who have liked this status. # noqa: E501 - - :param likes: The likes of this StatusUpdateResponse. # noqa: E501 - :type: list[GoalResponseLikes] - """ - - self._likes = likes - - @property - def modified_at(self): - """Gets the modified_at of this StatusUpdateResponse. # noqa: E501 - - The time at which this project status was last modified. *Note: This does not currently reflect any changes in associations such as comments that may have been added or removed from the status.* # noqa: E501 - - :return: The modified_at of this StatusUpdateResponse. # noqa: E501 - :rtype: datetime - """ - return self._modified_at - - @modified_at.setter - def modified_at(self, modified_at): - """Sets the modified_at of this StatusUpdateResponse. - - The time at which this project status was last modified. *Note: This does not currently reflect any changes in associations such as comments that may have been added or removed from the status.* # noqa: E501 - - :param modified_at: The modified_at of this StatusUpdateResponse. # noqa: E501 - :type: datetime - """ - - self._modified_at = modified_at - - @property - def num_hearts(self): - """Gets the num_hearts of this StatusUpdateResponse. # noqa: E501 - - *Deprecated - please use likes instead* The number of users who have hearted this status. # noqa: E501 - - :return: The num_hearts of this StatusUpdateResponse. # noqa: E501 - :rtype: int - """ - return self._num_hearts - - @num_hearts.setter - def num_hearts(self, num_hearts): - """Sets the num_hearts of this StatusUpdateResponse. - - *Deprecated - please use likes instead* The number of users who have hearted this status. # noqa: E501 - - :param num_hearts: The num_hearts of this StatusUpdateResponse. # noqa: E501 - :type: int - """ - - self._num_hearts = num_hearts - - @property - def num_likes(self): - """Gets the num_likes of this StatusUpdateResponse. # noqa: E501 - - The number of users who have liked this status. # noqa: E501 - - :return: The num_likes of this StatusUpdateResponse. # noqa: E501 - :rtype: int - """ - return self._num_likes - - @num_likes.setter - def num_likes(self, num_likes): - """Sets the num_likes of this StatusUpdateResponse. - - The number of users who have liked this status. # noqa: E501 - - :param num_likes: The num_likes of this StatusUpdateResponse. # noqa: E501 - :type: int - """ - - self._num_likes = num_likes - - @property - def parent(self): - """Gets the parent of this StatusUpdateResponse. # noqa: E501 - - - :return: The parent of this StatusUpdateResponse. # noqa: E501 - :rtype: StatusUpdateResponseParent - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this StatusUpdateResponse. - - - :param parent: The parent of this StatusUpdateResponse. # noqa: E501 - :type: StatusUpdateResponseParent - """ - - self._parent = parent - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StatusUpdateResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StatusUpdateResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/status_update_response_array.py b/asana/models/status_update_response_array.py deleted file mode 100644 index d490432a..00000000 --- a/asana/models/status_update_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StatusUpdateResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[StatusUpdateResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """StatusUpdateResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this StatusUpdateResponseArray. # noqa: E501 - - - :return: The data of this StatusUpdateResponseArray. # noqa: E501 - :rtype: list[StatusUpdateResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this StatusUpdateResponseArray. - - - :param data: The data of this StatusUpdateResponseArray. # noqa: E501 - :type: list[StatusUpdateResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this StatusUpdateResponseArray. # noqa: E501 - - - :return: The next_page of this StatusUpdateResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this StatusUpdateResponseArray. - - - :param next_page: The next_page of this StatusUpdateResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StatusUpdateResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StatusUpdateResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/status_update_response_data.py b/asana/models/status_update_response_data.py deleted file mode 100644 index d9c968ba..00000000 --- a/asana/models/status_update_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StatusUpdateResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'StatusUpdateResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """StatusUpdateResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this StatusUpdateResponseData. # noqa: E501 - - - :return: The data of this StatusUpdateResponseData. # noqa: E501 - :rtype: StatusUpdateResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this StatusUpdateResponseData. - - - :param data: The data of this StatusUpdateResponseData. # noqa: E501 - :type: StatusUpdateResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StatusUpdateResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StatusUpdateResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/status_update_response_parent.py b/asana/models/status_update_response_parent.py deleted file mode 100644 index 1a89a3a9..00000000 --- a/asana/models/status_update_response_parent.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StatusUpdateResponseParent(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """StatusUpdateResponseParent - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this StatusUpdateResponseParent. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StatusUpdateResponseParent. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StatusUpdateResponseParent. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StatusUpdateResponseParent. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StatusUpdateResponseParent. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StatusUpdateResponseParent. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StatusUpdateResponseParent. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StatusUpdateResponseParent. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this StatusUpdateResponseParent. # noqa: E501 - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this StatusUpdateResponseParent. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this StatusUpdateResponseParent. - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this StatusUpdateResponseParent. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StatusUpdateResponseParent, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StatusUpdateResponseParent): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/status_updates_body.py b/asana/models/status_updates_body.py deleted file mode 100644 index d8395b21..00000000 --- a/asana/models/status_updates_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StatusUpdatesBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'StatusUpdateRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """StatusUpdatesBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this StatusUpdatesBody. # noqa: E501 - - - :return: The data of this StatusUpdatesBody. # noqa: E501 - :rtype: StatusUpdateRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this StatusUpdatesBody. - - - :param data: The data of this StatusUpdatesBody. # noqa: E501 - :type: StatusUpdateRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StatusUpdatesBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StatusUpdatesBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/stories_story_gid_body.py b/asana/models/stories_story_gid_body.py deleted file mode 100644 index 6fce7dce..00000000 --- a/asana/models/stories_story_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoriesStoryGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'StoryRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """StoriesStoryGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this StoriesStoryGidBody. # noqa: E501 - - - :return: The data of this StoriesStoryGidBody. # noqa: E501 - :rtype: StoryRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this StoriesStoryGidBody. - - - :param data: The data of this StoriesStoryGidBody. # noqa: E501 - :type: StoryRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoriesStoryGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoriesStoryGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_base.py b/asana/models/story_base.py deleted file mode 100644 index a0ff62e3..00000000 --- a/asana/models/story_base.py +++ /dev/null @@ -1,314 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'created_at': 'datetime', - 'resource_subtype': 'str', - 'text': 'str', - 'html_text': 'str', - 'is_pinned': 'bool', - 'sticker_name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'created_at': 'created_at', - 'resource_subtype': 'resource_subtype', - 'text': 'text', - 'html_text': 'html_text', - 'is_pinned': 'is_pinned', - 'sticker_name': 'sticker_name' - } - - def __init__(self, gid=None, resource_type=None, created_at=None, resource_subtype=None, text=None, html_text=None, is_pinned=None, sticker_name=None): # noqa: E501 - """StoryBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._created_at = None - self._resource_subtype = None - self._text = None - self._html_text = None - self._is_pinned = None - self._sticker_name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if created_at is not None: - self.created_at = created_at - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if text is not None: - self.text = text - if html_text is not None: - self.html_text = html_text - if is_pinned is not None: - self.is_pinned = is_pinned - if sticker_name is not None: - self.sticker_name = sticker_name - - @property - def gid(self): - """Gets the gid of this StoryBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StoryBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StoryBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StoryBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StoryBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StoryBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StoryBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StoryBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def created_at(self): - """Gets the created_at of this StoryBase. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this StoryBase. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this StoryBase. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this StoryBase. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def resource_subtype(self): - """Gets the resource_subtype of this StoryBase. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this StoryBase. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this StoryBase. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this StoryBase. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def text(self): - """Gets the text of this StoryBase. # noqa: E501 - - The plain text of the comment to add. Cannot be used with html_text. # noqa: E501 - - :return: The text of this StoryBase. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this StoryBase. - - The plain text of the comment to add. Cannot be used with html_text. # noqa: E501 - - :param text: The text of this StoryBase. # noqa: E501 - :type: str - """ - - self._text = text - - @property - def html_text(self): - """Gets the html_text of this StoryBase. # noqa: E501 - - [Opt In](/docs/inputoutput-options). HTML formatted text for a comment. This will not include the name of the creator. # noqa: E501 - - :return: The html_text of this StoryBase. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this StoryBase. - - [Opt In](/docs/inputoutput-options). HTML formatted text for a comment. This will not include the name of the creator. # noqa: E501 - - :param html_text: The html_text of this StoryBase. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def is_pinned(self): - """Gets the is_pinned of this StoryBase. # noqa: E501 - - *Conditional*. Whether the story should be pinned on the resource. # noqa: E501 - - :return: The is_pinned of this StoryBase. # noqa: E501 - :rtype: bool - """ - return self._is_pinned - - @is_pinned.setter - def is_pinned(self, is_pinned): - """Sets the is_pinned of this StoryBase. - - *Conditional*. Whether the story should be pinned on the resource. # noqa: E501 - - :param is_pinned: The is_pinned of this StoryBase. # noqa: E501 - :type: bool - """ - - self._is_pinned = is_pinned - - @property - def sticker_name(self): - """Gets the sticker_name of this StoryBase. # noqa: E501 - - The name of the sticker in this story. `null` if there is no sticker. # noqa: E501 - - :return: The sticker_name of this StoryBase. # noqa: E501 - :rtype: str - """ - return self._sticker_name - - @sticker_name.setter - def sticker_name(self, sticker_name): - """Sets the sticker_name of this StoryBase. - - The name of the sticker in this story. `null` if there is no sticker. # noqa: E501 - - :param sticker_name: The sticker_name of this StoryBase. # noqa: E501 - :type: str - """ - allowed_values = ["green_checkmark", "people_dancing", "dancing_unicorn", "heart", "party_popper", "people_waving_flags", "splashing_narwhal", "trophy", "yeti_riding_unicorn", "celebrating_people", "determined_climbers", "phoenix_spreading_love"] # noqa: E501 - if sticker_name not in allowed_values: - raise ValueError( - "Invalid value for `sticker_name` ({0}), must be one of {1}" # noqa: E501 - .format(sticker_name, allowed_values) - ) - - self._sticker_name = sticker_name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_compact.py b/asana/models/story_compact.py deleted file mode 100644 index 8d7ac8e0..00000000 --- a/asana/models/story_compact.py +++ /dev/null @@ -1,250 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'created_at': 'datetime', - 'created_by': 'CustomFieldResponsePeopleValue', - 'resource_subtype': 'str', - 'text': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'created_at': 'created_at', - 'created_by': 'created_by', - 'resource_subtype': 'resource_subtype', - 'text': 'text' - } - - def __init__(self, gid=None, resource_type=None, created_at=None, created_by=None, resource_subtype=None, text=None): # noqa: E501 - """StoryCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._created_at = None - self._created_by = None - self._resource_subtype = None - self._text = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if created_at is not None: - self.created_at = created_at - if created_by is not None: - self.created_by = created_by - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if text is not None: - self.text = text - - @property - def gid(self): - """Gets the gid of this StoryCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StoryCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StoryCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StoryCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StoryCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StoryCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StoryCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StoryCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def created_at(self): - """Gets the created_at of this StoryCompact. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this StoryCompact. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this StoryCompact. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this StoryCompact. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def created_by(self): - """Gets the created_by of this StoryCompact. # noqa: E501 - - - :return: The created_by of this StoryCompact. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this StoryCompact. - - - :param created_by: The created_by of this StoryCompact. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._created_by = created_by - - @property - def resource_subtype(self): - """Gets the resource_subtype of this StoryCompact. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this StoryCompact. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this StoryCompact. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this StoryCompact. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def text(self): - """Gets the text of this StoryCompact. # noqa: E501 - - *Create-only*. Human-readable text for the story or comment. This will not include the name of the creator. *Note: This is not guaranteed to be stable for a given type of story. For example, text for a reassignment may not always say “assigned to …” as the text for a story can both be edited and change based on the language settings of the user making the request.* Use the `resource_subtype` property to discover the action that created the story. # noqa: E501 - - :return: The text of this StoryCompact. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this StoryCompact. - - *Create-only*. Human-readable text for the story or comment. This will not include the name of the creator. *Note: This is not guaranteed to be stable for a given type of story. For example, text for a reassignment may not always say “assigned to …” as the text for a story can both be edited and change based on the language settings of the user making the request.* Use the `resource_subtype` property to discover the action that created the story. # noqa: E501 - - :param text: The text of this StoryCompact. # noqa: E501 - :type: str - """ - - self._text = text - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_request.py b/asana/models/story_request.py deleted file mode 100644 index 9e133194..00000000 --- a/asana/models/story_request.py +++ /dev/null @@ -1,314 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'created_at': 'datetime', - 'resource_subtype': 'str', - 'text': 'str', - 'html_text': 'str', - 'is_pinned': 'bool', - 'sticker_name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'created_at': 'created_at', - 'resource_subtype': 'resource_subtype', - 'text': 'text', - 'html_text': 'html_text', - 'is_pinned': 'is_pinned', - 'sticker_name': 'sticker_name' - } - - def __init__(self, gid=None, resource_type=None, created_at=None, resource_subtype=None, text=None, html_text=None, is_pinned=None, sticker_name=None): # noqa: E501 - """StoryRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._created_at = None - self._resource_subtype = None - self._text = None - self._html_text = None - self._is_pinned = None - self._sticker_name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if created_at is not None: - self.created_at = created_at - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if text is not None: - self.text = text - if html_text is not None: - self.html_text = html_text - if is_pinned is not None: - self.is_pinned = is_pinned - if sticker_name is not None: - self.sticker_name = sticker_name - - @property - def gid(self): - """Gets the gid of this StoryRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StoryRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StoryRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StoryRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StoryRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StoryRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StoryRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StoryRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def created_at(self): - """Gets the created_at of this StoryRequest. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this StoryRequest. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this StoryRequest. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this StoryRequest. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def resource_subtype(self): - """Gets the resource_subtype of this StoryRequest. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this StoryRequest. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this StoryRequest. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this StoryRequest. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def text(self): - """Gets the text of this StoryRequest. # noqa: E501 - - The plain text of the comment to add. Cannot be used with html_text. # noqa: E501 - - :return: The text of this StoryRequest. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this StoryRequest. - - The plain text of the comment to add. Cannot be used with html_text. # noqa: E501 - - :param text: The text of this StoryRequest. # noqa: E501 - :type: str - """ - - self._text = text - - @property - def html_text(self): - """Gets the html_text of this StoryRequest. # noqa: E501 - - [Opt In](/docs/inputoutput-options). HTML formatted text for a comment. This will not include the name of the creator. # noqa: E501 - - :return: The html_text of this StoryRequest. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this StoryRequest. - - [Opt In](/docs/inputoutput-options). HTML formatted text for a comment. This will not include the name of the creator. # noqa: E501 - - :param html_text: The html_text of this StoryRequest. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def is_pinned(self): - """Gets the is_pinned of this StoryRequest. # noqa: E501 - - *Conditional*. Whether the story should be pinned on the resource. # noqa: E501 - - :return: The is_pinned of this StoryRequest. # noqa: E501 - :rtype: bool - """ - return self._is_pinned - - @is_pinned.setter - def is_pinned(self, is_pinned): - """Sets the is_pinned of this StoryRequest. - - *Conditional*. Whether the story should be pinned on the resource. # noqa: E501 - - :param is_pinned: The is_pinned of this StoryRequest. # noqa: E501 - :type: bool - """ - - self._is_pinned = is_pinned - - @property - def sticker_name(self): - """Gets the sticker_name of this StoryRequest. # noqa: E501 - - The name of the sticker in this story. `null` if there is no sticker. # noqa: E501 - - :return: The sticker_name of this StoryRequest. # noqa: E501 - :rtype: str - """ - return self._sticker_name - - @sticker_name.setter - def sticker_name(self, sticker_name): - """Sets the sticker_name of this StoryRequest. - - The name of the sticker in this story. `null` if there is no sticker. # noqa: E501 - - :param sticker_name: The sticker_name of this StoryRequest. # noqa: E501 - :type: str - """ - allowed_values = ["green_checkmark", "people_dancing", "dancing_unicorn", "heart", "party_popper", "people_waving_flags", "splashing_narwhal", "trophy", "yeti_riding_unicorn", "celebrating_people", "determined_climbers", "phoenix_spreading_love"] # noqa: E501 - if sticker_name not in allowed_values: - raise ValueError( - "Invalid value for `sticker_name` ({0}), must be one of {1}" # noqa: E501 - .format(sticker_name, allowed_values) - ) - - self._sticker_name = sticker_name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response.py b/asana/models/story_response.py deleted file mode 100644 index e05a4a1b..00000000 --- a/asana/models/story_response.py +++ /dev/null @@ -1,1544 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'created_at': 'datetime', - 'resource_subtype': 'str', - 'text': 'str', - 'html_text': 'str', - 'is_pinned': 'bool', - 'sticker_name': 'str', - 'created_by': 'CustomFieldResponsePeopleValue', - 'type': 'str', - 'is_editable': 'bool', - 'is_edited': 'bool', - 'hearted': 'bool', - 'hearts': 'list[GoalResponseLikes]', - 'num_hearts': 'int', - 'liked': 'bool', - 'likes': 'list[GoalResponseLikes]', - 'num_likes': 'int', - 'previews': 'list[StoryResponsePreviews]', - 'old_name': 'str', - 'new_name': 'str', - 'old_dates': 'StoryResponseOldDates', - 'new_dates': 'StoryResponseOldDates', - 'old_resource_subtype': 'str', - 'new_resource_subtype': 'str', - 'story': 'StoryResponseStory', - 'assignee': 'StoryResponseAssignee', - 'follower': 'StoryResponseAssignee', - 'old_section': 'StoryResponseOldSection', - 'new_section': 'StoryResponseOldSection', - 'task': 'StoryResponseTask', - 'project': 'StoryResponseProject', - 'tag': 'StoryResponseTag', - 'custom_field': 'StoryResponseCustomField', - 'old_text_value': 'str', - 'new_text_value': 'str', - 'old_number_value': 'int', - 'new_number_value': 'int', - 'old_enum_value': 'StoryResponseOldEnumValue', - 'new_enum_value': 'StoryResponseOldEnumValue', - 'old_date_value': 'AllOfStoryResponseOldDateValue', - 'new_date_value': 'AllOfStoryResponseNewDateValue', - 'old_people_value': 'list[CustomFieldResponsePeopleValue]', - 'new_people_value': 'list[CustomFieldResponsePeopleValue]', - 'old_multi_enum_values': 'list[CustomFieldBaseEnumOptions]', - 'new_multi_enum_values': 'list[CustomFieldBaseEnumOptions]', - 'new_approval_status': 'str', - 'old_approval_status': 'str', - 'duplicate_of': 'StoryResponseTask', - 'duplicated_from': 'StoryResponseTask', - 'dependency': 'StoryResponseTask', - 'source': 'str', - 'target': 'StoryResponseTarget' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'created_at': 'created_at', - 'resource_subtype': 'resource_subtype', - 'text': 'text', - 'html_text': 'html_text', - 'is_pinned': 'is_pinned', - 'sticker_name': 'sticker_name', - 'created_by': 'created_by', - 'type': 'type', - 'is_editable': 'is_editable', - 'is_edited': 'is_edited', - 'hearted': 'hearted', - 'hearts': 'hearts', - 'num_hearts': 'num_hearts', - 'liked': 'liked', - 'likes': 'likes', - 'num_likes': 'num_likes', - 'previews': 'previews', - 'old_name': 'old_name', - 'new_name': 'new_name', - 'old_dates': 'old_dates', - 'new_dates': 'new_dates', - 'old_resource_subtype': 'old_resource_subtype', - 'new_resource_subtype': 'new_resource_subtype', - 'story': 'story', - 'assignee': 'assignee', - 'follower': 'follower', - 'old_section': 'old_section', - 'new_section': 'new_section', - 'task': 'task', - 'project': 'project', - 'tag': 'tag', - 'custom_field': 'custom_field', - 'old_text_value': 'old_text_value', - 'new_text_value': 'new_text_value', - 'old_number_value': 'old_number_value', - 'new_number_value': 'new_number_value', - 'old_enum_value': 'old_enum_value', - 'new_enum_value': 'new_enum_value', - 'old_date_value': 'old_date_value', - 'new_date_value': 'new_date_value', - 'old_people_value': 'old_people_value', - 'new_people_value': 'new_people_value', - 'old_multi_enum_values': 'old_multi_enum_values', - 'new_multi_enum_values': 'new_multi_enum_values', - 'new_approval_status': 'new_approval_status', - 'old_approval_status': 'old_approval_status', - 'duplicate_of': 'duplicate_of', - 'duplicated_from': 'duplicated_from', - 'dependency': 'dependency', - 'source': 'source', - 'target': 'target' - } - - def __init__(self, gid=None, resource_type=None, created_at=None, resource_subtype=None, text=None, html_text=None, is_pinned=None, sticker_name=None, created_by=None, type=None, is_editable=None, is_edited=None, hearted=None, hearts=None, num_hearts=None, liked=None, likes=None, num_likes=None, previews=None, old_name=None, new_name=None, old_dates=None, new_dates=None, old_resource_subtype=None, new_resource_subtype=None, story=None, assignee=None, follower=None, old_section=None, new_section=None, task=None, project=None, tag=None, custom_field=None, old_text_value=None, new_text_value=None, old_number_value=None, new_number_value=None, old_enum_value=None, new_enum_value=None, old_date_value=None, new_date_value=None, old_people_value=None, new_people_value=None, old_multi_enum_values=None, new_multi_enum_values=None, new_approval_status=None, old_approval_status=None, duplicate_of=None, duplicated_from=None, dependency=None, source=None, target=None): # noqa: E501 - """StoryResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._created_at = None - self._resource_subtype = None - self._text = None - self._html_text = None - self._is_pinned = None - self._sticker_name = None - self._created_by = None - self._type = None - self._is_editable = None - self._is_edited = None - self._hearted = None - self._hearts = None - self._num_hearts = None - self._liked = None - self._likes = None - self._num_likes = None - self._previews = None - self._old_name = None - self._new_name = None - self._old_dates = None - self._new_dates = None - self._old_resource_subtype = None - self._new_resource_subtype = None - self._story = None - self._assignee = None - self._follower = None - self._old_section = None - self._new_section = None - self._task = None - self._project = None - self._tag = None - self._custom_field = None - self._old_text_value = None - self._new_text_value = None - self._old_number_value = None - self._new_number_value = None - self._old_enum_value = None - self._new_enum_value = None - self._old_date_value = None - self._new_date_value = None - self._old_people_value = None - self._new_people_value = None - self._old_multi_enum_values = None - self._new_multi_enum_values = None - self._new_approval_status = None - self._old_approval_status = None - self._duplicate_of = None - self._duplicated_from = None - self._dependency = None - self._source = None - self._target = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if created_at is not None: - self.created_at = created_at - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if text is not None: - self.text = text - if html_text is not None: - self.html_text = html_text - if is_pinned is not None: - self.is_pinned = is_pinned - if sticker_name is not None: - self.sticker_name = sticker_name - if created_by is not None: - self.created_by = created_by - if type is not None: - self.type = type - if is_editable is not None: - self.is_editable = is_editable - if is_edited is not None: - self.is_edited = is_edited - if hearted is not None: - self.hearted = hearted - if hearts is not None: - self.hearts = hearts - if num_hearts is not None: - self.num_hearts = num_hearts - if liked is not None: - self.liked = liked - if likes is not None: - self.likes = likes - if num_likes is not None: - self.num_likes = num_likes - if previews is not None: - self.previews = previews - if old_name is not None: - self.old_name = old_name - if new_name is not None: - self.new_name = new_name - if old_dates is not None: - self.old_dates = old_dates - if new_dates is not None: - self.new_dates = new_dates - if old_resource_subtype is not None: - self.old_resource_subtype = old_resource_subtype - if new_resource_subtype is not None: - self.new_resource_subtype = new_resource_subtype - if story is not None: - self.story = story - if assignee is not None: - self.assignee = assignee - if follower is not None: - self.follower = follower - if old_section is not None: - self.old_section = old_section - if new_section is not None: - self.new_section = new_section - if task is not None: - self.task = task - if project is not None: - self.project = project - if tag is not None: - self.tag = tag - if custom_field is not None: - self.custom_field = custom_field - if old_text_value is not None: - self.old_text_value = old_text_value - if new_text_value is not None: - self.new_text_value = new_text_value - if old_number_value is not None: - self.old_number_value = old_number_value - if new_number_value is not None: - self.new_number_value = new_number_value - if old_enum_value is not None: - self.old_enum_value = old_enum_value - if new_enum_value is not None: - self.new_enum_value = new_enum_value - if old_date_value is not None: - self.old_date_value = old_date_value - if new_date_value is not None: - self.new_date_value = new_date_value - if old_people_value is not None: - self.old_people_value = old_people_value - if new_people_value is not None: - self.new_people_value = new_people_value - if old_multi_enum_values is not None: - self.old_multi_enum_values = old_multi_enum_values - if new_multi_enum_values is not None: - self.new_multi_enum_values = new_multi_enum_values - if new_approval_status is not None: - self.new_approval_status = new_approval_status - if old_approval_status is not None: - self.old_approval_status = old_approval_status - if duplicate_of is not None: - self.duplicate_of = duplicate_of - if duplicated_from is not None: - self.duplicated_from = duplicated_from - if dependency is not None: - self.dependency = dependency - if source is not None: - self.source = source - if target is not None: - self.target = target - - @property - def gid(self): - """Gets the gid of this StoryResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StoryResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StoryResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StoryResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StoryResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StoryResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def created_at(self): - """Gets the created_at of this StoryResponse. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this StoryResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this StoryResponse. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this StoryResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def resource_subtype(self): - """Gets the resource_subtype of this StoryResponse. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this StoryResponse. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this StoryResponse. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def text(self): - """Gets the text of this StoryResponse. # noqa: E501 - - The plain text of the comment to add. Cannot be used with html_text. # noqa: E501 - - :return: The text of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this StoryResponse. - - The plain text of the comment to add. Cannot be used with html_text. # noqa: E501 - - :param text: The text of this StoryResponse. # noqa: E501 - :type: str - """ - - self._text = text - - @property - def html_text(self): - """Gets the html_text of this StoryResponse. # noqa: E501 - - [Opt In](/docs/inputoutput-options). HTML formatted text for a comment. This will not include the name of the creator. # noqa: E501 - - :return: The html_text of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this StoryResponse. - - [Opt In](/docs/inputoutput-options). HTML formatted text for a comment. This will not include the name of the creator. # noqa: E501 - - :param html_text: The html_text of this StoryResponse. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def is_pinned(self): - """Gets the is_pinned of this StoryResponse. # noqa: E501 - - *Conditional*. Whether the story should be pinned on the resource. # noqa: E501 - - :return: The is_pinned of this StoryResponse. # noqa: E501 - :rtype: bool - """ - return self._is_pinned - - @is_pinned.setter - def is_pinned(self, is_pinned): - """Sets the is_pinned of this StoryResponse. - - *Conditional*. Whether the story should be pinned on the resource. # noqa: E501 - - :param is_pinned: The is_pinned of this StoryResponse. # noqa: E501 - :type: bool - """ - - self._is_pinned = is_pinned - - @property - def sticker_name(self): - """Gets the sticker_name of this StoryResponse. # noqa: E501 - - The name of the sticker in this story. `null` if there is no sticker. # noqa: E501 - - :return: The sticker_name of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._sticker_name - - @sticker_name.setter - def sticker_name(self, sticker_name): - """Sets the sticker_name of this StoryResponse. - - The name of the sticker in this story. `null` if there is no sticker. # noqa: E501 - - :param sticker_name: The sticker_name of this StoryResponse. # noqa: E501 - :type: str - """ - allowed_values = ["green_checkmark", "people_dancing", "dancing_unicorn", "heart", "party_popper", "people_waving_flags", "splashing_narwhal", "trophy", "yeti_riding_unicorn", "celebrating_people", "determined_climbers", "phoenix_spreading_love"] # noqa: E501 - if sticker_name not in allowed_values: - raise ValueError( - "Invalid value for `sticker_name` ({0}), must be one of {1}" # noqa: E501 - .format(sticker_name, allowed_values) - ) - - self._sticker_name = sticker_name - - @property - def created_by(self): - """Gets the created_by of this StoryResponse. # noqa: E501 - - - :return: The created_by of this StoryResponse. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this StoryResponse. - - - :param created_by: The created_by of this StoryResponse. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._created_by = created_by - - @property - def type(self): - """Gets the type of this StoryResponse. # noqa: E501 - - - :return: The type of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this StoryResponse. - - - :param type: The type of this StoryResponse. # noqa: E501 - :type: str - """ - allowed_values = ["comment", "system"] # noqa: E501 - if type not in allowed_values: - raise ValueError( - "Invalid value for `type` ({0}), must be one of {1}" # noqa: E501 - .format(type, allowed_values) - ) - - self._type = type - - @property - def is_editable(self): - """Gets the is_editable of this StoryResponse. # noqa: E501 - - *Conditional*. Whether the text of the story can be edited after creation. # noqa: E501 - - :return: The is_editable of this StoryResponse. # noqa: E501 - :rtype: bool - """ - return self._is_editable - - @is_editable.setter - def is_editable(self, is_editable): - """Sets the is_editable of this StoryResponse. - - *Conditional*. Whether the text of the story can be edited after creation. # noqa: E501 - - :param is_editable: The is_editable of this StoryResponse. # noqa: E501 - :type: bool - """ - - self._is_editable = is_editable - - @property - def is_edited(self): - """Gets the is_edited of this StoryResponse. # noqa: E501 - - *Conditional*. Whether the text of the story has been edited after creation. # noqa: E501 - - :return: The is_edited of this StoryResponse. # noqa: E501 - :rtype: bool - """ - return self._is_edited - - @is_edited.setter - def is_edited(self, is_edited): - """Sets the is_edited of this StoryResponse. - - *Conditional*. Whether the text of the story has been edited after creation. # noqa: E501 - - :param is_edited: The is_edited of this StoryResponse. # noqa: E501 - :type: bool - """ - - self._is_edited = is_edited - - @property - def hearted(self): - """Gets the hearted of this StoryResponse. # noqa: E501 - - *Deprecated - please use likes instead* *Conditional*. True if the story is hearted by the authorized user, false if not. # noqa: E501 - - :return: The hearted of this StoryResponse. # noqa: E501 - :rtype: bool - """ - return self._hearted - - @hearted.setter - def hearted(self, hearted): - """Sets the hearted of this StoryResponse. - - *Deprecated - please use likes instead* *Conditional*. True if the story is hearted by the authorized user, false if not. # noqa: E501 - - :param hearted: The hearted of this StoryResponse. # noqa: E501 - :type: bool - """ - - self._hearted = hearted - - @property - def hearts(self): - """Gets the hearts of this StoryResponse. # noqa: E501 - - *Deprecated - please use likes instead* *Conditional*. Array of likes for users who have hearted this story. # noqa: E501 - - :return: The hearts of this StoryResponse. # noqa: E501 - :rtype: list[GoalResponseLikes] - """ - return self._hearts - - @hearts.setter - def hearts(self, hearts): - """Sets the hearts of this StoryResponse. - - *Deprecated - please use likes instead* *Conditional*. Array of likes for users who have hearted this story. # noqa: E501 - - :param hearts: The hearts of this StoryResponse. # noqa: E501 - :type: list[GoalResponseLikes] - """ - - self._hearts = hearts - - @property - def num_hearts(self): - """Gets the num_hearts of this StoryResponse. # noqa: E501 - - *Deprecated - please use likes instead* *Conditional*. The number of users who have hearted this story. # noqa: E501 - - :return: The num_hearts of this StoryResponse. # noqa: E501 - :rtype: int - """ - return self._num_hearts - - @num_hearts.setter - def num_hearts(self, num_hearts): - """Sets the num_hearts of this StoryResponse. - - *Deprecated - please use likes instead* *Conditional*. The number of users who have hearted this story. # noqa: E501 - - :param num_hearts: The num_hearts of this StoryResponse. # noqa: E501 - :type: int - """ - - self._num_hearts = num_hearts - - @property - def liked(self): - """Gets the liked of this StoryResponse. # noqa: E501 - - *Conditional*. True if the story is liked by the authorized user, false if not. # noqa: E501 - - :return: The liked of this StoryResponse. # noqa: E501 - :rtype: bool - """ - return self._liked - - @liked.setter - def liked(self, liked): - """Sets the liked of this StoryResponse. - - *Conditional*. True if the story is liked by the authorized user, false if not. # noqa: E501 - - :param liked: The liked of this StoryResponse. # noqa: E501 - :type: bool - """ - - self._liked = liked - - @property - def likes(self): - """Gets the likes of this StoryResponse. # noqa: E501 - - *Conditional*. Array of likes for users who have liked this story. # noqa: E501 - - :return: The likes of this StoryResponse. # noqa: E501 - :rtype: list[GoalResponseLikes] - """ - return self._likes - - @likes.setter - def likes(self, likes): - """Sets the likes of this StoryResponse. - - *Conditional*. Array of likes for users who have liked this story. # noqa: E501 - - :param likes: The likes of this StoryResponse. # noqa: E501 - :type: list[GoalResponseLikes] - """ - - self._likes = likes - - @property - def num_likes(self): - """Gets the num_likes of this StoryResponse. # noqa: E501 - - *Conditional*. The number of users who have liked this story. # noqa: E501 - - :return: The num_likes of this StoryResponse. # noqa: E501 - :rtype: int - """ - return self._num_likes - - @num_likes.setter - def num_likes(self, num_likes): - """Sets the num_likes of this StoryResponse. - - *Conditional*. The number of users who have liked this story. # noqa: E501 - - :param num_likes: The num_likes of this StoryResponse. # noqa: E501 - :type: int - """ - - self._num_likes = num_likes - - @property - def previews(self): - """Gets the previews of this StoryResponse. # noqa: E501 - - *Conditional*. A collection of previews to be displayed in the story. *Note: This property only exists for comment stories.* # noqa: E501 - - :return: The previews of this StoryResponse. # noqa: E501 - :rtype: list[StoryResponsePreviews] - """ - return self._previews - - @previews.setter - def previews(self, previews): - """Sets the previews of this StoryResponse. - - *Conditional*. A collection of previews to be displayed in the story. *Note: This property only exists for comment stories.* # noqa: E501 - - :param previews: The previews of this StoryResponse. # noqa: E501 - :type: list[StoryResponsePreviews] - """ - - self._previews = previews - - @property - def old_name(self): - """Gets the old_name of this StoryResponse. # noqa: E501 - - *Conditional*' # noqa: E501 - - :return: The old_name of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._old_name - - @old_name.setter - def old_name(self, old_name): - """Sets the old_name of this StoryResponse. - - *Conditional*' # noqa: E501 - - :param old_name: The old_name of this StoryResponse. # noqa: E501 - :type: str - """ - - self._old_name = old_name - - @property - def new_name(self): - """Gets the new_name of this StoryResponse. # noqa: E501 - - *Conditional* # noqa: E501 - - :return: The new_name of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._new_name - - @new_name.setter - def new_name(self, new_name): - """Sets the new_name of this StoryResponse. - - *Conditional* # noqa: E501 - - :param new_name: The new_name of this StoryResponse. # noqa: E501 - :type: str - """ - - self._new_name = new_name - - @property - def old_dates(self): - """Gets the old_dates of this StoryResponse. # noqa: E501 - - - :return: The old_dates of this StoryResponse. # noqa: E501 - :rtype: StoryResponseOldDates - """ - return self._old_dates - - @old_dates.setter - def old_dates(self, old_dates): - """Sets the old_dates of this StoryResponse. - - - :param old_dates: The old_dates of this StoryResponse. # noqa: E501 - :type: StoryResponseOldDates - """ - - self._old_dates = old_dates - - @property - def new_dates(self): - """Gets the new_dates of this StoryResponse. # noqa: E501 - - - :return: The new_dates of this StoryResponse. # noqa: E501 - :rtype: StoryResponseOldDates - """ - return self._new_dates - - @new_dates.setter - def new_dates(self, new_dates): - """Sets the new_dates of this StoryResponse. - - - :param new_dates: The new_dates of this StoryResponse. # noqa: E501 - :type: StoryResponseOldDates - """ - - self._new_dates = new_dates - - @property - def old_resource_subtype(self): - """Gets the old_resource_subtype of this StoryResponse. # noqa: E501 - - *Conditional* # noqa: E501 - - :return: The old_resource_subtype of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._old_resource_subtype - - @old_resource_subtype.setter - def old_resource_subtype(self, old_resource_subtype): - """Sets the old_resource_subtype of this StoryResponse. - - *Conditional* # noqa: E501 - - :param old_resource_subtype: The old_resource_subtype of this StoryResponse. # noqa: E501 - :type: str - """ - - self._old_resource_subtype = old_resource_subtype - - @property - def new_resource_subtype(self): - """Gets the new_resource_subtype of this StoryResponse. # noqa: E501 - - *Conditional* # noqa: E501 - - :return: The new_resource_subtype of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._new_resource_subtype - - @new_resource_subtype.setter - def new_resource_subtype(self, new_resource_subtype): - """Sets the new_resource_subtype of this StoryResponse. - - *Conditional* # noqa: E501 - - :param new_resource_subtype: The new_resource_subtype of this StoryResponse. # noqa: E501 - :type: str - """ - - self._new_resource_subtype = new_resource_subtype - - @property - def story(self): - """Gets the story of this StoryResponse. # noqa: E501 - - - :return: The story of this StoryResponse. # noqa: E501 - :rtype: StoryResponseStory - """ - return self._story - - @story.setter - def story(self, story): - """Sets the story of this StoryResponse. - - - :param story: The story of this StoryResponse. # noqa: E501 - :type: StoryResponseStory - """ - - self._story = story - - @property - def assignee(self): - """Gets the assignee of this StoryResponse. # noqa: E501 - - - :return: The assignee of this StoryResponse. # noqa: E501 - :rtype: StoryResponseAssignee - """ - return self._assignee - - @assignee.setter - def assignee(self, assignee): - """Sets the assignee of this StoryResponse. - - - :param assignee: The assignee of this StoryResponse. # noqa: E501 - :type: StoryResponseAssignee - """ - - self._assignee = assignee - - @property - def follower(self): - """Gets the follower of this StoryResponse. # noqa: E501 - - - :return: The follower of this StoryResponse. # noqa: E501 - :rtype: StoryResponseAssignee - """ - return self._follower - - @follower.setter - def follower(self, follower): - """Sets the follower of this StoryResponse. - - - :param follower: The follower of this StoryResponse. # noqa: E501 - :type: StoryResponseAssignee - """ - - self._follower = follower - - @property - def old_section(self): - """Gets the old_section of this StoryResponse. # noqa: E501 - - - :return: The old_section of this StoryResponse. # noqa: E501 - :rtype: StoryResponseOldSection - """ - return self._old_section - - @old_section.setter - def old_section(self, old_section): - """Sets the old_section of this StoryResponse. - - - :param old_section: The old_section of this StoryResponse. # noqa: E501 - :type: StoryResponseOldSection - """ - - self._old_section = old_section - - @property - def new_section(self): - """Gets the new_section of this StoryResponse. # noqa: E501 - - - :return: The new_section of this StoryResponse. # noqa: E501 - :rtype: StoryResponseOldSection - """ - return self._new_section - - @new_section.setter - def new_section(self, new_section): - """Sets the new_section of this StoryResponse. - - - :param new_section: The new_section of this StoryResponse. # noqa: E501 - :type: StoryResponseOldSection - """ - - self._new_section = new_section - - @property - def task(self): - """Gets the task of this StoryResponse. # noqa: E501 - - - :return: The task of this StoryResponse. # noqa: E501 - :rtype: StoryResponseTask - """ - return self._task - - @task.setter - def task(self, task): - """Sets the task of this StoryResponse. - - - :param task: The task of this StoryResponse. # noqa: E501 - :type: StoryResponseTask - """ - - self._task = task - - @property - def project(self): - """Gets the project of this StoryResponse. # noqa: E501 - - - :return: The project of this StoryResponse. # noqa: E501 - :rtype: StoryResponseProject - """ - return self._project - - @project.setter - def project(self, project): - """Sets the project of this StoryResponse. - - - :param project: The project of this StoryResponse. # noqa: E501 - :type: StoryResponseProject - """ - - self._project = project - - @property - def tag(self): - """Gets the tag of this StoryResponse. # noqa: E501 - - - :return: The tag of this StoryResponse. # noqa: E501 - :rtype: StoryResponseTag - """ - return self._tag - - @tag.setter - def tag(self, tag): - """Sets the tag of this StoryResponse. - - - :param tag: The tag of this StoryResponse. # noqa: E501 - :type: StoryResponseTag - """ - - self._tag = tag - - @property - def custom_field(self): - """Gets the custom_field of this StoryResponse. # noqa: E501 - - - :return: The custom_field of this StoryResponse. # noqa: E501 - :rtype: StoryResponseCustomField - """ - return self._custom_field - - @custom_field.setter - def custom_field(self, custom_field): - """Sets the custom_field of this StoryResponse. - - - :param custom_field: The custom_field of this StoryResponse. # noqa: E501 - :type: StoryResponseCustomField - """ - - self._custom_field = custom_field - - @property - def old_text_value(self): - """Gets the old_text_value of this StoryResponse. # noqa: E501 - - *Conditional* # noqa: E501 - - :return: The old_text_value of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._old_text_value - - @old_text_value.setter - def old_text_value(self, old_text_value): - """Sets the old_text_value of this StoryResponse. - - *Conditional* # noqa: E501 - - :param old_text_value: The old_text_value of this StoryResponse. # noqa: E501 - :type: str - """ - - self._old_text_value = old_text_value - - @property - def new_text_value(self): - """Gets the new_text_value of this StoryResponse. # noqa: E501 - - *Conditional* # noqa: E501 - - :return: The new_text_value of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._new_text_value - - @new_text_value.setter - def new_text_value(self, new_text_value): - """Sets the new_text_value of this StoryResponse. - - *Conditional* # noqa: E501 - - :param new_text_value: The new_text_value of this StoryResponse. # noqa: E501 - :type: str - """ - - self._new_text_value = new_text_value - - @property - def old_number_value(self): - """Gets the old_number_value of this StoryResponse. # noqa: E501 - - *Conditional* # noqa: E501 - - :return: The old_number_value of this StoryResponse. # noqa: E501 - :rtype: int - """ - return self._old_number_value - - @old_number_value.setter - def old_number_value(self, old_number_value): - """Sets the old_number_value of this StoryResponse. - - *Conditional* # noqa: E501 - - :param old_number_value: The old_number_value of this StoryResponse. # noqa: E501 - :type: int - """ - - self._old_number_value = old_number_value - - @property - def new_number_value(self): - """Gets the new_number_value of this StoryResponse. # noqa: E501 - - *Conditional* # noqa: E501 - - :return: The new_number_value of this StoryResponse. # noqa: E501 - :rtype: int - """ - return self._new_number_value - - @new_number_value.setter - def new_number_value(self, new_number_value): - """Sets the new_number_value of this StoryResponse. - - *Conditional* # noqa: E501 - - :param new_number_value: The new_number_value of this StoryResponse. # noqa: E501 - :type: int - """ - - self._new_number_value = new_number_value - - @property - def old_enum_value(self): - """Gets the old_enum_value of this StoryResponse. # noqa: E501 - - - :return: The old_enum_value of this StoryResponse. # noqa: E501 - :rtype: StoryResponseOldEnumValue - """ - return self._old_enum_value - - @old_enum_value.setter - def old_enum_value(self, old_enum_value): - """Sets the old_enum_value of this StoryResponse. - - - :param old_enum_value: The old_enum_value of this StoryResponse. # noqa: E501 - :type: StoryResponseOldEnumValue - """ - - self._old_enum_value = old_enum_value - - @property - def new_enum_value(self): - """Gets the new_enum_value of this StoryResponse. # noqa: E501 - - - :return: The new_enum_value of this StoryResponse. # noqa: E501 - :rtype: StoryResponseOldEnumValue - """ - return self._new_enum_value - - @new_enum_value.setter - def new_enum_value(self, new_enum_value): - """Sets the new_enum_value of this StoryResponse. - - - :param new_enum_value: The new_enum_value of this StoryResponse. # noqa: E501 - :type: StoryResponseOldEnumValue - """ - - self._new_enum_value = new_enum_value - - @property - def old_date_value(self): - """Gets the old_date_value of this StoryResponse. # noqa: E501 - - - :return: The old_date_value of this StoryResponse. # noqa: E501 - :rtype: AllOfStoryResponseOldDateValue - """ - return self._old_date_value - - @old_date_value.setter - def old_date_value(self, old_date_value): - """Sets the old_date_value of this StoryResponse. - - - :param old_date_value: The old_date_value of this StoryResponse. # noqa: E501 - :type: AllOfStoryResponseOldDateValue - """ - - self._old_date_value = old_date_value - - @property - def new_date_value(self): - """Gets the new_date_value of this StoryResponse. # noqa: E501 - - - :return: The new_date_value of this StoryResponse. # noqa: E501 - :rtype: AllOfStoryResponseNewDateValue - """ - return self._new_date_value - - @new_date_value.setter - def new_date_value(self, new_date_value): - """Sets the new_date_value of this StoryResponse. - - - :param new_date_value: The new_date_value of this StoryResponse. # noqa: E501 - :type: AllOfStoryResponseNewDateValue - """ - - self._new_date_value = new_date_value - - @property - def old_people_value(self): - """Gets the old_people_value of this StoryResponse. # noqa: E501 - - *Conditional*. The old value of a people custom field story. # noqa: E501 - - :return: The old_people_value of this StoryResponse. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._old_people_value - - @old_people_value.setter - def old_people_value(self, old_people_value): - """Sets the old_people_value of this StoryResponse. - - *Conditional*. The old value of a people custom field story. # noqa: E501 - - :param old_people_value: The old_people_value of this StoryResponse. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._old_people_value = old_people_value - - @property - def new_people_value(self): - """Gets the new_people_value of this StoryResponse. # noqa: E501 - - *Conditional*. The new value of a people custom field story. # noqa: E501 - - :return: The new_people_value of this StoryResponse. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._new_people_value - - @new_people_value.setter - def new_people_value(self, new_people_value): - """Sets the new_people_value of this StoryResponse. - - *Conditional*. The new value of a people custom field story. # noqa: E501 - - :param new_people_value: The new_people_value of this StoryResponse. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._new_people_value = new_people_value - - @property - def old_multi_enum_values(self): - """Gets the old_multi_enum_values of this StoryResponse. # noqa: E501 - - *Conditional*. The old value of a multi-enum custom field story. # noqa: E501 - - :return: The old_multi_enum_values of this StoryResponse. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._old_multi_enum_values - - @old_multi_enum_values.setter - def old_multi_enum_values(self, old_multi_enum_values): - """Sets the old_multi_enum_values of this StoryResponse. - - *Conditional*. The old value of a multi-enum custom field story. # noqa: E501 - - :param old_multi_enum_values: The old_multi_enum_values of this StoryResponse. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._old_multi_enum_values = old_multi_enum_values - - @property - def new_multi_enum_values(self): - """Gets the new_multi_enum_values of this StoryResponse. # noqa: E501 - - *Conditional*. The new value of a multi-enum custom field story. # noqa: E501 - - :return: The new_multi_enum_values of this StoryResponse. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._new_multi_enum_values - - @new_multi_enum_values.setter - def new_multi_enum_values(self, new_multi_enum_values): - """Sets the new_multi_enum_values of this StoryResponse. - - *Conditional*. The new value of a multi-enum custom field story. # noqa: E501 - - :param new_multi_enum_values: The new_multi_enum_values of this StoryResponse. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._new_multi_enum_values = new_multi_enum_values - - @property - def new_approval_status(self): - """Gets the new_approval_status of this StoryResponse. # noqa: E501 - - *Conditional*. The new value of approval status. # noqa: E501 - - :return: The new_approval_status of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._new_approval_status - - @new_approval_status.setter - def new_approval_status(self, new_approval_status): - """Sets the new_approval_status of this StoryResponse. - - *Conditional*. The new value of approval status. # noqa: E501 - - :param new_approval_status: The new_approval_status of this StoryResponse. # noqa: E501 - :type: str - """ - - self._new_approval_status = new_approval_status - - @property - def old_approval_status(self): - """Gets the old_approval_status of this StoryResponse. # noqa: E501 - - *Conditional*. The old value of approval status. # noqa: E501 - - :return: The old_approval_status of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._old_approval_status - - @old_approval_status.setter - def old_approval_status(self, old_approval_status): - """Sets the old_approval_status of this StoryResponse. - - *Conditional*. The old value of approval status. # noqa: E501 - - :param old_approval_status: The old_approval_status of this StoryResponse. # noqa: E501 - :type: str - """ - - self._old_approval_status = old_approval_status - - @property - def duplicate_of(self): - """Gets the duplicate_of of this StoryResponse. # noqa: E501 - - - :return: The duplicate_of of this StoryResponse. # noqa: E501 - :rtype: StoryResponseTask - """ - return self._duplicate_of - - @duplicate_of.setter - def duplicate_of(self, duplicate_of): - """Sets the duplicate_of of this StoryResponse. - - - :param duplicate_of: The duplicate_of of this StoryResponse. # noqa: E501 - :type: StoryResponseTask - """ - - self._duplicate_of = duplicate_of - - @property - def duplicated_from(self): - """Gets the duplicated_from of this StoryResponse. # noqa: E501 - - - :return: The duplicated_from of this StoryResponse. # noqa: E501 - :rtype: StoryResponseTask - """ - return self._duplicated_from - - @duplicated_from.setter - def duplicated_from(self, duplicated_from): - """Sets the duplicated_from of this StoryResponse. - - - :param duplicated_from: The duplicated_from of this StoryResponse. # noqa: E501 - :type: StoryResponseTask - """ - - self._duplicated_from = duplicated_from - - @property - def dependency(self): - """Gets the dependency of this StoryResponse. # noqa: E501 - - - :return: The dependency of this StoryResponse. # noqa: E501 - :rtype: StoryResponseTask - """ - return self._dependency - - @dependency.setter - def dependency(self, dependency): - """Sets the dependency of this StoryResponse. - - - :param dependency: The dependency of this StoryResponse. # noqa: E501 - :type: StoryResponseTask - """ - - self._dependency = dependency - - @property - def source(self): - """Gets the source of this StoryResponse. # noqa: E501 - - The component of the Asana product the user used to trigger the story. # noqa: E501 - - :return: The source of this StoryResponse. # noqa: E501 - :rtype: str - """ - return self._source - - @source.setter - def source(self, source): - """Sets the source of this StoryResponse. - - The component of the Asana product the user used to trigger the story. # noqa: E501 - - :param source: The source of this StoryResponse. # noqa: E501 - :type: str - """ - allowed_values = ["web", "email", "mobile", "api", "unknown"] # noqa: E501 - if source not in allowed_values: - raise ValueError( - "Invalid value for `source` ({0}), must be one of {1}" # noqa: E501 - .format(source, allowed_values) - ) - - self._source = source - - @property - def target(self): - """Gets the target of this StoryResponse. # noqa: E501 - - - :return: The target of this StoryResponse. # noqa: E501 - :rtype: StoryResponseTarget - """ - return self._target - - @target.setter - def target(self, target): - """Sets the target of this StoryResponse. - - - :param target: The target of this StoryResponse. # noqa: E501 - :type: StoryResponseTarget - """ - - self._target = target - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_array.py b/asana/models/story_response_array.py deleted file mode 100644 index a16b5491..00000000 --- a/asana/models/story_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[StoryResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """StoryResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this StoryResponseArray. # noqa: E501 - - - :return: The data of this StoryResponseArray. # noqa: E501 - :rtype: list[StoryResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this StoryResponseArray. - - - :param data: The data of this StoryResponseArray. # noqa: E501 - :type: list[StoryResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this StoryResponseArray. # noqa: E501 - - - :return: The next_page of this StoryResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this StoryResponseArray. - - - :param next_page: The next_page of this StoryResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_assignee.py b/asana/models/story_response_assignee.py deleted file mode 100644 index 86205db0..00000000 --- a/asana/models/story_response_assignee.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponseAssignee(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """StoryResponseAssignee - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this StoryResponseAssignee. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StoryResponseAssignee. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StoryResponseAssignee. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StoryResponseAssignee. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StoryResponseAssignee. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StoryResponseAssignee. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StoryResponseAssignee. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StoryResponseAssignee. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this StoryResponseAssignee. # noqa: E501 - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :return: The name of this StoryResponseAssignee. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this StoryResponseAssignee. - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :param name: The name of this StoryResponseAssignee. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponseAssignee, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponseAssignee): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_custom_field.py b/asana/models/story_response_custom_field.py deleted file mode 100644 index c3e63e53..00000000 --- a/asana/models/story_response_custom_field.py +++ /dev/null @@ -1,484 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponseCustomField(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'type': 'str', - 'enum_options': 'list[CustomFieldBaseEnumOptions]', - 'enabled': 'bool', - 'is_formula_field': 'bool', - 'date_value': 'CustomFieldBaseDateValue', - 'enum_value': 'CustomFieldBaseEnumValue', - 'multi_enum_values': 'list[CustomFieldBaseEnumOptions]', - 'number_value': 'float', - 'text_value': 'str', - 'display_value': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'type': 'type', - 'enum_options': 'enum_options', - 'enabled': 'enabled', - 'is_formula_field': 'is_formula_field', - 'date_value': 'date_value', - 'enum_value': 'enum_value', - 'multi_enum_values': 'multi_enum_values', - 'number_value': 'number_value', - 'text_value': 'text_value', - 'display_value': 'display_value' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, type=None, enum_options=None, enabled=None, is_formula_field=None, date_value=None, enum_value=None, multi_enum_values=None, number_value=None, text_value=None, display_value=None): # noqa: E501 - """StoryResponseCustomField - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._type = None - self._enum_options = None - self._enabled = None - self._is_formula_field = None - self._date_value = None - self._enum_value = None - self._multi_enum_values = None - self._number_value = None - self._text_value = None - self._display_value = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if type is not None: - self.type = type - if enum_options is not None: - self.enum_options = enum_options - if enabled is not None: - self.enabled = enabled - if is_formula_field is not None: - self.is_formula_field = is_formula_field - if date_value is not None: - self.date_value = date_value - if enum_value is not None: - self.enum_value = enum_value - if multi_enum_values is not None: - self.multi_enum_values = multi_enum_values - if number_value is not None: - self.number_value = number_value - if text_value is not None: - self.text_value = text_value - if display_value is not None: - self.display_value = display_value - - @property - def gid(self): - """Gets the gid of this StoryResponseCustomField. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StoryResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StoryResponseCustomField. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StoryResponseCustomField. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StoryResponseCustomField. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StoryResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StoryResponseCustomField. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StoryResponseCustomField. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this StoryResponseCustomField. # noqa: E501 - - The name of the custom field. # noqa: E501 - - :return: The name of this StoryResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this StoryResponseCustomField. - - The name of the custom field. # noqa: E501 - - :param name: The name of this StoryResponseCustomField. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this StoryResponseCustomField. # noqa: E501 - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The resource_subtype of this StoryResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this StoryResponseCustomField. - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :param resource_subtype: The resource_subtype of this StoryResponseCustomField. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def type(self): - """Gets the type of this StoryResponseCustomField. # noqa: E501 - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The type of this StoryResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this StoryResponseCustomField. - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :param type: The type of this StoryResponseCustomField. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if type not in allowed_values: - raise ValueError( - "Invalid value for `type` ({0}), must be one of {1}" # noqa: E501 - .format(type, allowed_values) - ) - - self._type = type - - @property - def enum_options(self): - """Gets the enum_options of this StoryResponseCustomField. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :return: The enum_options of this StoryResponseCustomField. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._enum_options - - @enum_options.setter - def enum_options(self, enum_options): - """Sets the enum_options of this StoryResponseCustomField. - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :param enum_options: The enum_options of this StoryResponseCustomField. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._enum_options = enum_options - - @property - def enabled(self): - """Gets the enabled of this StoryResponseCustomField. # noqa: E501 - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :return: The enabled of this StoryResponseCustomField. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this StoryResponseCustomField. - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :param enabled: The enabled of this StoryResponseCustomField. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def is_formula_field(self): - """Gets the is_formula_field of this StoryResponseCustomField. # noqa: E501 - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :return: The is_formula_field of this StoryResponseCustomField. # noqa: E501 - :rtype: bool - """ - return self._is_formula_field - - @is_formula_field.setter - def is_formula_field(self, is_formula_field): - """Sets the is_formula_field of this StoryResponseCustomField. - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :param is_formula_field: The is_formula_field of this StoryResponseCustomField. # noqa: E501 - :type: bool - """ - - self._is_formula_field = is_formula_field - - @property - def date_value(self): - """Gets the date_value of this StoryResponseCustomField. # noqa: E501 - - - :return: The date_value of this StoryResponseCustomField. # noqa: E501 - :rtype: CustomFieldBaseDateValue - """ - return self._date_value - - @date_value.setter - def date_value(self, date_value): - """Sets the date_value of this StoryResponseCustomField. - - - :param date_value: The date_value of this StoryResponseCustomField. # noqa: E501 - :type: CustomFieldBaseDateValue - """ - - self._date_value = date_value - - @property - def enum_value(self): - """Gets the enum_value of this StoryResponseCustomField. # noqa: E501 - - - :return: The enum_value of this StoryResponseCustomField. # noqa: E501 - :rtype: CustomFieldBaseEnumValue - """ - return self._enum_value - - @enum_value.setter - def enum_value(self, enum_value): - """Sets the enum_value of this StoryResponseCustomField. - - - :param enum_value: The enum_value of this StoryResponseCustomField. # noqa: E501 - :type: CustomFieldBaseEnumValue - """ - - self._enum_value = enum_value - - @property - def multi_enum_values(self): - """Gets the multi_enum_values of this StoryResponseCustomField. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :return: The multi_enum_values of this StoryResponseCustomField. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._multi_enum_values - - @multi_enum_values.setter - def multi_enum_values(self, multi_enum_values): - """Sets the multi_enum_values of this StoryResponseCustomField. - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :param multi_enum_values: The multi_enum_values of this StoryResponseCustomField. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._multi_enum_values = multi_enum_values - - @property - def number_value(self): - """Gets the number_value of this StoryResponseCustomField. # noqa: E501 - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :return: The number_value of this StoryResponseCustomField. # noqa: E501 - :rtype: float - """ - return self._number_value - - @number_value.setter - def number_value(self, number_value): - """Sets the number_value of this StoryResponseCustomField. - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :param number_value: The number_value of this StoryResponseCustomField. # noqa: E501 - :type: float - """ - - self._number_value = number_value - - @property - def text_value(self): - """Gets the text_value of this StoryResponseCustomField. # noqa: E501 - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :return: The text_value of this StoryResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._text_value - - @text_value.setter - def text_value(self, text_value): - """Sets the text_value of this StoryResponseCustomField. - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :param text_value: The text_value of this StoryResponseCustomField. # noqa: E501 - :type: str - """ - - self._text_value = text_value - - @property - def display_value(self): - """Gets the display_value of this StoryResponseCustomField. # noqa: E501 - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :return: The display_value of this StoryResponseCustomField. # noqa: E501 - :rtype: str - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this StoryResponseCustomField. - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :param display_value: The display_value of this StoryResponseCustomField. # noqa: E501 - :type: str - """ - - self._display_value = display_value - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponseCustomField, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponseCustomField): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_data.py b/asana/models/story_response_data.py deleted file mode 100644 index 651d4d12..00000000 --- a/asana/models/story_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'StoryResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """StoryResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this StoryResponseData. # noqa: E501 - - - :return: The data of this StoryResponseData. # noqa: E501 - :rtype: StoryResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this StoryResponseData. - - - :param data: The data of this StoryResponseData. # noqa: E501 - :type: StoryResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_dates.py b/asana/models/story_response_dates.py deleted file mode 100644 index cf896ddc..00000000 --- a/asana/models/story_response_dates.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponseDates(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'start_on': 'date', - 'due_at': 'datetime', - 'due_on': 'date' - } - - attribute_map = { - 'start_on': 'start_on', - 'due_at': 'due_at', - 'due_on': 'due_on' - } - - def __init__(self, start_on=None, due_at=None, due_on=None): # noqa: E501 - """StoryResponseDates - a model defined in Swagger""" # noqa: E501 - self._start_on = None - self._due_at = None - self._due_on = None - self.discriminator = None - if start_on is not None: - self.start_on = start_on - if due_at is not None: - self.due_at = due_at - if due_on is not None: - self.due_on = due_on - - @property - def start_on(self): - """Gets the start_on of this StoryResponseDates. # noqa: E501 - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :return: The start_on of this StoryResponseDates. # noqa: E501 - :rtype: date - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this StoryResponseDates. - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :param start_on: The start_on of this StoryResponseDates. # noqa: E501 - :type: date - """ - - self._start_on = start_on - - @property - def due_at(self): - """Gets the due_at of this StoryResponseDates. # noqa: E501 - - The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. # noqa: E501 - - :return: The due_at of this StoryResponseDates. # noqa: E501 - :rtype: datetime - """ - return self._due_at - - @due_at.setter - def due_at(self, due_at): - """Sets the due_at of this StoryResponseDates. - - The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. # noqa: E501 - - :param due_at: The due_at of this StoryResponseDates. # noqa: E501 - :type: datetime - """ - - self._due_at = due_at - - @property - def due_on(self): - """Gets the due_on of this StoryResponseDates. # noqa: E501 - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :return: The due_on of this StoryResponseDates. # noqa: E501 - :rtype: date - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this StoryResponseDates. - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :param due_on: The due_on of this StoryResponseDates. # noqa: E501 - :type: date - """ - - self._due_on = due_on - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponseDates, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponseDates): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_old_dates.py b/asana/models/story_response_old_dates.py deleted file mode 100644 index 71d67ab6..00000000 --- a/asana/models/story_response_old_dates.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponseOldDates(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'start_on': 'date', - 'due_at': 'datetime', - 'due_on': 'date' - } - - attribute_map = { - 'start_on': 'start_on', - 'due_at': 'due_at', - 'due_on': 'due_on' - } - - def __init__(self, start_on=None, due_at=None, due_on=None): # noqa: E501 - """StoryResponseOldDates - a model defined in Swagger""" # noqa: E501 - self._start_on = None - self._due_at = None - self._due_on = None - self.discriminator = None - if start_on is not None: - self.start_on = start_on - if due_at is not None: - self.due_at = due_at - if due_on is not None: - self.due_on = due_on - - @property - def start_on(self): - """Gets the start_on of this StoryResponseOldDates. # noqa: E501 - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :return: The start_on of this StoryResponseOldDates. # noqa: E501 - :rtype: date - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this StoryResponseOldDates. - - The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. # noqa: E501 - - :param start_on: The start_on of this StoryResponseOldDates. # noqa: E501 - :type: date - """ - - self._start_on = start_on - - @property - def due_at(self): - """Gets the due_at of this StoryResponseOldDates. # noqa: E501 - - The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. # noqa: E501 - - :return: The due_at of this StoryResponseOldDates. # noqa: E501 - :rtype: datetime - """ - return self._due_at - - @due_at.setter - def due_at(self, due_at): - """Sets the due_at of this StoryResponseOldDates. - - The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. # noqa: E501 - - :param due_at: The due_at of this StoryResponseOldDates. # noqa: E501 - :type: datetime - """ - - self._due_at = due_at - - @property - def due_on(self): - """Gets the due_on of this StoryResponseOldDates. # noqa: E501 - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :return: The due_on of this StoryResponseOldDates. # noqa: E501 - :rtype: date - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this StoryResponseOldDates. - - The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. # noqa: E501 - - :param due_on: The due_on of this StoryResponseOldDates. # noqa: E501 - :type: date - """ - - self._due_on = due_on - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponseOldDates, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponseOldDates): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_old_enum_value.py b/asana/models/story_response_old_enum_value.py deleted file mode 100644 index 8829b290..00000000 --- a/asana/models/story_response_old_enum_value.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponseOldEnumValue(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'enabled': 'bool', - 'color': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'enabled': 'enabled', - 'color': 'color' - } - - def __init__(self, gid=None, resource_type=None, name=None, enabled=None, color=None): # noqa: E501 - """StoryResponseOldEnumValue - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._enabled = None - self._color = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if enabled is not None: - self.enabled = enabled - if color is not None: - self.color = color - - @property - def gid(self): - """Gets the gid of this StoryResponseOldEnumValue. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StoryResponseOldEnumValue. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StoryResponseOldEnumValue. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StoryResponseOldEnumValue. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StoryResponseOldEnumValue. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StoryResponseOldEnumValue. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StoryResponseOldEnumValue. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StoryResponseOldEnumValue. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this StoryResponseOldEnumValue. # noqa: E501 - - The name of the enum option. # noqa: E501 - - :return: The name of this StoryResponseOldEnumValue. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this StoryResponseOldEnumValue. - - The name of the enum option. # noqa: E501 - - :param name: The name of this StoryResponseOldEnumValue. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def enabled(self): - """Gets the enabled of this StoryResponseOldEnumValue. # noqa: E501 - - Whether or not the enum option is a selectable value for the custom field. # noqa: E501 - - :return: The enabled of this StoryResponseOldEnumValue. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this StoryResponseOldEnumValue. - - Whether or not the enum option is a selectable value for the custom field. # noqa: E501 - - :param enabled: The enabled of this StoryResponseOldEnumValue. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def color(self): - """Gets the color of this StoryResponseOldEnumValue. # noqa: E501 - - The color of the enum option. Defaults to ‘none’. # noqa: E501 - - :return: The color of this StoryResponseOldEnumValue. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this StoryResponseOldEnumValue. - - The color of the enum option. Defaults to ‘none’. # noqa: E501 - - :param color: The color of this StoryResponseOldEnumValue. # noqa: E501 - :type: str - """ - - self._color = color - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponseOldEnumValue, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponseOldEnumValue): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_old_section.py b/asana/models/story_response_old_section.py deleted file mode 100644 index 32ddd2cc..00000000 --- a/asana/models/story_response_old_section.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponseOldSection(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """StoryResponseOldSection - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this StoryResponseOldSection. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StoryResponseOldSection. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StoryResponseOldSection. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StoryResponseOldSection. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StoryResponseOldSection. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StoryResponseOldSection. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StoryResponseOldSection. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StoryResponseOldSection. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this StoryResponseOldSection. # noqa: E501 - - The name of the section (i.e. the text displayed as the section header). # noqa: E501 - - :return: The name of this StoryResponseOldSection. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this StoryResponseOldSection. - - The name of the section (i.e. the text displayed as the section header). # noqa: E501 - - :param name: The name of this StoryResponseOldSection. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponseOldSection, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponseOldSection): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_previews.py b/asana/models/story_response_previews.py deleted file mode 100644 index 81cfe1d5..00000000 --- a/asana/models/story_response_previews.py +++ /dev/null @@ -1,308 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponsePreviews(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'fallback': 'str', - 'footer': 'str', - 'header': 'str', - 'header_link': 'str', - 'html_text': 'str', - 'text': 'str', - 'title': 'str', - 'title_link': 'str' - } - - attribute_map = { - 'fallback': 'fallback', - 'footer': 'footer', - 'header': 'header', - 'header_link': 'header_link', - 'html_text': 'html_text', - 'text': 'text', - 'title': 'title', - 'title_link': 'title_link' - } - - def __init__(self, fallback=None, footer=None, header=None, header_link=None, html_text=None, text=None, title=None, title_link=None): # noqa: E501 - """StoryResponsePreviews - a model defined in Swagger""" # noqa: E501 - self._fallback = None - self._footer = None - self._header = None - self._header_link = None - self._html_text = None - self._text = None - self._title = None - self._title_link = None - self.discriminator = None - if fallback is not None: - self.fallback = fallback - if footer is not None: - self.footer = footer - if header is not None: - self.header = header - if header_link is not None: - self.header_link = header_link - if html_text is not None: - self.html_text = html_text - if text is not None: - self.text = text - if title is not None: - self.title = title - if title_link is not None: - self.title_link = title_link - - @property - def fallback(self): - """Gets the fallback of this StoryResponsePreviews. # noqa: E501 - - Some fallback text to display if unable to display the full preview. # noqa: E501 - - :return: The fallback of this StoryResponsePreviews. # noqa: E501 - :rtype: str - """ - return self._fallback - - @fallback.setter - def fallback(self, fallback): - """Sets the fallback of this StoryResponsePreviews. - - Some fallback text to display if unable to display the full preview. # noqa: E501 - - :param fallback: The fallback of this StoryResponsePreviews. # noqa: E501 - :type: str - """ - - self._fallback = fallback - - @property - def footer(self): - """Gets the footer of this StoryResponsePreviews. # noqa: E501 - - Text to display in the footer. # noqa: E501 - - :return: The footer of this StoryResponsePreviews. # noqa: E501 - :rtype: str - """ - return self._footer - - @footer.setter - def footer(self, footer): - """Sets the footer of this StoryResponsePreviews. - - Text to display in the footer. # noqa: E501 - - :param footer: The footer of this StoryResponsePreviews. # noqa: E501 - :type: str - """ - - self._footer = footer - - @property - def header(self): - """Gets the header of this StoryResponsePreviews. # noqa: E501 - - Text to display in the header. # noqa: E501 - - :return: The header of this StoryResponsePreviews. # noqa: E501 - :rtype: str - """ - return self._header - - @header.setter - def header(self, header): - """Sets the header of this StoryResponsePreviews. - - Text to display in the header. # noqa: E501 - - :param header: The header of this StoryResponsePreviews. # noqa: E501 - :type: str - """ - - self._header = header - - @property - def header_link(self): - """Gets the header_link of this StoryResponsePreviews. # noqa: E501 - - Where the header will link to. # noqa: E501 - - :return: The header_link of this StoryResponsePreviews. # noqa: E501 - :rtype: str - """ - return self._header_link - - @header_link.setter - def header_link(self, header_link): - """Sets the header_link of this StoryResponsePreviews. - - Where the header will link to. # noqa: E501 - - :param header_link: The header_link of this StoryResponsePreviews. # noqa: E501 - :type: str - """ - - self._header_link = header_link - - @property - def html_text(self): - """Gets the html_text of this StoryResponsePreviews. # noqa: E501 - - HTML formatted text for the body of the preview. # noqa: E501 - - :return: The html_text of this StoryResponsePreviews. # noqa: E501 - :rtype: str - """ - return self._html_text - - @html_text.setter - def html_text(self, html_text): - """Sets the html_text of this StoryResponsePreviews. - - HTML formatted text for the body of the preview. # noqa: E501 - - :param html_text: The html_text of this StoryResponsePreviews. # noqa: E501 - :type: str - """ - - self._html_text = html_text - - @property - def text(self): - """Gets the text of this StoryResponsePreviews. # noqa: E501 - - Text for the body of the preview. # noqa: E501 - - :return: The text of this StoryResponsePreviews. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this StoryResponsePreviews. - - Text for the body of the preview. # noqa: E501 - - :param text: The text of this StoryResponsePreviews. # noqa: E501 - :type: str - """ - - self._text = text - - @property - def title(self): - """Gets the title of this StoryResponsePreviews. # noqa: E501 - - Text to display as the title. # noqa: E501 - - :return: The title of this StoryResponsePreviews. # noqa: E501 - :rtype: str - """ - return self._title - - @title.setter - def title(self, title): - """Sets the title of this StoryResponsePreviews. - - Text to display as the title. # noqa: E501 - - :param title: The title of this StoryResponsePreviews. # noqa: E501 - :type: str - """ - - self._title = title - - @property - def title_link(self): - """Gets the title_link of this StoryResponsePreviews. # noqa: E501 - - Where to title will link to. # noqa: E501 - - :return: The title_link of this StoryResponsePreviews. # noqa: E501 - :rtype: str - """ - return self._title_link - - @title_link.setter - def title_link(self, title_link): - """Sets the title_link of this StoryResponsePreviews. - - Where to title will link to. # noqa: E501 - - :param title_link: The title_link of this StoryResponsePreviews. # noqa: E501 - :type: str - """ - - self._title_link = title_link - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponsePreviews, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponsePreviews): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_project.py b/asana/models/story_response_project.py deleted file mode 100644 index 0e8cad49..00000000 --- a/asana/models/story_response_project.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponseProject(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """StoryResponseProject - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this StoryResponseProject. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StoryResponseProject. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StoryResponseProject. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StoryResponseProject. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StoryResponseProject. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StoryResponseProject. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StoryResponseProject. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StoryResponseProject. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this StoryResponseProject. # noqa: E501 - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this StoryResponseProject. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this StoryResponseProject. - - Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this StoryResponseProject. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponseProject, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponseProject): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_story.py b/asana/models/story_response_story.py deleted file mode 100644 index dd68c291..00000000 --- a/asana/models/story_response_story.py +++ /dev/null @@ -1,250 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponseStory(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'created_at': 'datetime', - 'created_by': 'CustomFieldResponsePeopleValue', - 'resource_subtype': 'str', - 'text': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'created_at': 'created_at', - 'created_by': 'created_by', - 'resource_subtype': 'resource_subtype', - 'text': 'text' - } - - def __init__(self, gid=None, resource_type=None, created_at=None, created_by=None, resource_subtype=None, text=None): # noqa: E501 - """StoryResponseStory - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._created_at = None - self._created_by = None - self._resource_subtype = None - self._text = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if created_at is not None: - self.created_at = created_at - if created_by is not None: - self.created_by = created_by - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if text is not None: - self.text = text - - @property - def gid(self): - """Gets the gid of this StoryResponseStory. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StoryResponseStory. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StoryResponseStory. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StoryResponseStory. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StoryResponseStory. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StoryResponseStory. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StoryResponseStory. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StoryResponseStory. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def created_at(self): - """Gets the created_at of this StoryResponseStory. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this StoryResponseStory. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this StoryResponseStory. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this StoryResponseStory. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def created_by(self): - """Gets the created_by of this StoryResponseStory. # noqa: E501 - - - :return: The created_by of this StoryResponseStory. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this StoryResponseStory. - - - :param created_by: The created_by of this StoryResponseStory. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._created_by = created_by - - @property - def resource_subtype(self): - """Gets the resource_subtype of this StoryResponseStory. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :return: The resource_subtype of this StoryResponseStory. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this StoryResponseStory. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. # noqa: E501 - - :param resource_subtype: The resource_subtype of this StoryResponseStory. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def text(self): - """Gets the text of this StoryResponseStory. # noqa: E501 - - *Create-only*. Human-readable text for the story or comment. This will not include the name of the creator. *Note: This is not guaranteed to be stable for a given type of story. For example, text for a reassignment may not always say “assigned to …” as the text for a story can both be edited and change based on the language settings of the user making the request.* Use the `resource_subtype` property to discover the action that created the story. # noqa: E501 - - :return: The text of this StoryResponseStory. # noqa: E501 - :rtype: str - """ - return self._text - - @text.setter - def text(self, text): - """Sets the text of this StoryResponseStory. - - *Create-only*. Human-readable text for the story or comment. This will not include the name of the creator. *Note: This is not guaranteed to be stable for a given type of story. For example, text for a reassignment may not always say “assigned to …” as the text for a story can both be edited and change based on the language settings of the user making the request.* Use the `resource_subtype` property to discover the action that created the story. # noqa: E501 - - :param text: The text of this StoryResponseStory. # noqa: E501 - :type: str - """ - - self._text = text - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponseStory, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponseStory): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_tag.py b/asana/models/story_response_tag.py deleted file mode 100644 index 0c98ff76..00000000 --- a/asana/models/story_response_tag.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponseTag(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """StoryResponseTag - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this StoryResponseTag. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StoryResponseTag. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StoryResponseTag. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StoryResponseTag. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StoryResponseTag. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StoryResponseTag. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StoryResponseTag. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StoryResponseTag. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this StoryResponseTag. # noqa: E501 - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this StoryResponseTag. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this StoryResponseTag. - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this StoryResponseTag. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponseTag, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponseTag): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_target.py b/asana/models/story_response_target.py deleted file mode 100644 index cd91037e..00000000 --- a/asana/models/story_response_target.py +++ /dev/null @@ -1,228 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponseTarget(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'created_by': 'AttachmentResponseParentCreatedBy' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'created_by': 'created_by' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, created_by=None): # noqa: E501 - """StoryResponseTarget - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._created_by = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if created_by is not None: - self.created_by = created_by - - @property - def gid(self): - """Gets the gid of this StoryResponseTarget. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StoryResponseTarget. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StoryResponseTarget. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StoryResponseTarget. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StoryResponseTarget. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StoryResponseTarget. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StoryResponseTarget. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StoryResponseTarget. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this StoryResponseTarget. # noqa: E501 - - The name of the task. # noqa: E501 - - :return: The name of this StoryResponseTarget. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this StoryResponseTarget. - - The name of the task. # noqa: E501 - - :param name: The name of this StoryResponseTarget. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this StoryResponseTarget. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :return: The resource_subtype of this StoryResponseTarget. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this StoryResponseTarget. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :param resource_subtype: The resource_subtype of this StoryResponseTarget. # noqa: E501 - :type: str - """ - allowed_values = ["default_task", "milestone", "section", "approval"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def created_by(self): - """Gets the created_by of this StoryResponseTarget. # noqa: E501 - - - :return: The created_by of this StoryResponseTarget. # noqa: E501 - :rtype: AttachmentResponseParentCreatedBy - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this StoryResponseTarget. - - - :param created_by: The created_by of this StoryResponseTarget. # noqa: E501 - :type: AttachmentResponseParentCreatedBy - """ - - self._created_by = created_by - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponseTarget, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponseTarget): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/story_response_task.py b/asana/models/story_response_task.py deleted file mode 100644 index 90bb0a7a..00000000 --- a/asana/models/story_response_task.py +++ /dev/null @@ -1,228 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class StoryResponseTask(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'created_by': 'AttachmentResponseParentCreatedBy' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'created_by': 'created_by' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, created_by=None): # noqa: E501 - """StoryResponseTask - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._created_by = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if created_by is not None: - self.created_by = created_by - - @property - def gid(self): - """Gets the gid of this StoryResponseTask. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this StoryResponseTask. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this StoryResponseTask. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this StoryResponseTask. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this StoryResponseTask. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this StoryResponseTask. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this StoryResponseTask. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this StoryResponseTask. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this StoryResponseTask. # noqa: E501 - - The name of the task. # noqa: E501 - - :return: The name of this StoryResponseTask. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this StoryResponseTask. - - The name of the task. # noqa: E501 - - :param name: The name of this StoryResponseTask. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this StoryResponseTask. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :return: The resource_subtype of this StoryResponseTask. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this StoryResponseTask. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :param resource_subtype: The resource_subtype of this StoryResponseTask. # noqa: E501 - :type: str - """ - allowed_values = ["default_task", "milestone", "section", "approval"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def created_by(self): - """Gets the created_by of this StoryResponseTask. # noqa: E501 - - - :return: The created_by of this StoryResponseTask. # noqa: E501 - :rtype: AttachmentResponseParentCreatedBy - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this StoryResponseTask. - - - :param created_by: The created_by of this StoryResponseTask. # noqa: E501 - :type: AttachmentResponseParentCreatedBy - """ - - self._created_by = created_by - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(StoryResponseTask, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, StoryResponseTask): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/tag_base.py b/asana/models/tag_base.py deleted file mode 100644 index 4698c1d4..00000000 --- a/asana/models/tag_base.py +++ /dev/null @@ -1,230 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TagBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'color': 'str', - 'notes': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'color': 'color', - 'notes': 'notes' - } - - def __init__(self, gid=None, resource_type=None, name=None, color=None, notes=None): # noqa: E501 - """TagBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._color = None - self._notes = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if color is not None: - self.color = color - if notes is not None: - self.notes = notes - - @property - def gid(self): - """Gets the gid of this TagBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TagBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TagBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TagBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TagBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TagBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TagBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TagBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TagBase. # noqa: E501 - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this TagBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TagBase. - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this TagBase. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def color(self): - """Gets the color of this TagBase. # noqa: E501 - - Color of the tag. # noqa: E501 - - :return: The color of this TagBase. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this TagBase. - - Color of the tag. # noqa: E501 - - :param color: The color of this TagBase. # noqa: E501 - :type: str - """ - allowed_values = ["dark-pink", "dark-green", "dark-blue", "dark-red", "dark-teal", "dark-brown", "dark-orange", "dark-purple", "dark-warm-gray", "light-pink", "light-green", "light-blue", "light-red", "light-teal", "light-brown", "light-orange", "light-purple", "light-warm-gray", ""] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def notes(self): - """Gets the notes of this TagBase. # noqa: E501 - - Free-form textual information associated with the tag (i.e. its description). # noqa: E501 - - :return: The notes of this TagBase. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this TagBase. - - Free-form textual information associated with the tag (i.e. its description). # noqa: E501 - - :param notes: The notes of this TagBase. # noqa: E501 - :type: str - """ - - self._notes = notes - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TagBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TagBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/tag_compact.py b/asana/models/tag_compact.py deleted file mode 100644 index be77771d..00000000 --- a/asana/models/tag_compact.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TagCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """TagCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this TagCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TagCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TagCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TagCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TagCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TagCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TagCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TagCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TagCompact. # noqa: E501 - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this TagCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TagCompact. - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this TagCompact. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TagCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TagCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/tag_create_tag_for_workspace_request.py b/asana/models/tag_create_tag_for_workspace_request.py deleted file mode 100644 index c18ea67f..00000000 --- a/asana/models/tag_create_tag_for_workspace_request.py +++ /dev/null @@ -1,258 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TagCreateTagForWorkspaceRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'color': 'str', - 'notes': 'str', - 'followers': 'list[str]' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'color': 'color', - 'notes': 'notes', - 'followers': 'followers' - } - - def __init__(self, gid=None, resource_type=None, name=None, color=None, notes=None, followers=None): # noqa: E501 - """TagCreateTagForWorkspaceRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._color = None - self._notes = None - self._followers = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if color is not None: - self.color = color - if notes is not None: - self.notes = notes - if followers is not None: - self.followers = followers - - @property - def gid(self): - """Gets the gid of this TagCreateTagForWorkspaceRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TagCreateTagForWorkspaceRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TagCreateTagForWorkspaceRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TagCreateTagForWorkspaceRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TagCreateTagForWorkspaceRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TagCreateTagForWorkspaceRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TagCreateTagForWorkspaceRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TagCreateTagForWorkspaceRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TagCreateTagForWorkspaceRequest. # noqa: E501 - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this TagCreateTagForWorkspaceRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TagCreateTagForWorkspaceRequest. - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this TagCreateTagForWorkspaceRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def color(self): - """Gets the color of this TagCreateTagForWorkspaceRequest. # noqa: E501 - - Color of the tag. # noqa: E501 - - :return: The color of this TagCreateTagForWorkspaceRequest. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this TagCreateTagForWorkspaceRequest. - - Color of the tag. # noqa: E501 - - :param color: The color of this TagCreateTagForWorkspaceRequest. # noqa: E501 - :type: str - """ - allowed_values = ["dark-pink", "dark-green", "dark-blue", "dark-red", "dark-teal", "dark-brown", "dark-orange", "dark-purple", "dark-warm-gray", "light-pink", "light-green", "light-blue", "light-red", "light-teal", "light-brown", "light-orange", "light-purple", "light-warm-gray", ""] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def notes(self): - """Gets the notes of this TagCreateTagForWorkspaceRequest. # noqa: E501 - - Free-form textual information associated with the tag (i.e. its description). # noqa: E501 - - :return: The notes of this TagCreateTagForWorkspaceRequest. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this TagCreateTagForWorkspaceRequest. - - Free-form textual information associated with the tag (i.e. its description). # noqa: E501 - - :param notes: The notes of this TagCreateTagForWorkspaceRequest. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def followers(self): - """Gets the followers of this TagCreateTagForWorkspaceRequest. # noqa: E501 - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :return: The followers of this TagCreateTagForWorkspaceRequest. # noqa: E501 - :rtype: list[str] - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this TagCreateTagForWorkspaceRequest. - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :param followers: The followers of this TagCreateTagForWorkspaceRequest. # noqa: E501 - :type: list[str] - """ - - self._followers = followers - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TagCreateTagForWorkspaceRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TagCreateTagForWorkspaceRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/tag_request.py b/asana/models/tag_request.py deleted file mode 100644 index 5defb5e4..00000000 --- a/asana/models/tag_request.py +++ /dev/null @@ -1,286 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TagRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'color': 'str', - 'notes': 'str', - 'followers': 'list[str]', - 'workspace': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'color': 'color', - 'notes': 'notes', - 'followers': 'followers', - 'workspace': 'workspace' - } - - def __init__(self, gid=None, resource_type=None, name=None, color=None, notes=None, followers=None, workspace=None): # noqa: E501 - """TagRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._color = None - self._notes = None - self._followers = None - self._workspace = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if color is not None: - self.color = color - if notes is not None: - self.notes = notes - if followers is not None: - self.followers = followers - if workspace is not None: - self.workspace = workspace - - @property - def gid(self): - """Gets the gid of this TagRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TagRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TagRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TagRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TagRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TagRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TagRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TagRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TagRequest. # noqa: E501 - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this TagRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TagRequest. - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this TagRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def color(self): - """Gets the color of this TagRequest. # noqa: E501 - - Color of the tag. # noqa: E501 - - :return: The color of this TagRequest. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this TagRequest. - - Color of the tag. # noqa: E501 - - :param color: The color of this TagRequest. # noqa: E501 - :type: str - """ - allowed_values = ["dark-pink", "dark-green", "dark-blue", "dark-red", "dark-teal", "dark-brown", "dark-orange", "dark-purple", "dark-warm-gray", "light-pink", "light-green", "light-blue", "light-red", "light-teal", "light-brown", "light-orange", "light-purple", "light-warm-gray", ""] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def notes(self): - """Gets the notes of this TagRequest. # noqa: E501 - - Free-form textual information associated with the tag (i.e. its description). # noqa: E501 - - :return: The notes of this TagRequest. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this TagRequest. - - Free-form textual information associated with the tag (i.e. its description). # noqa: E501 - - :param notes: The notes of this TagRequest. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def followers(self): - """Gets the followers of this TagRequest. # noqa: E501 - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :return: The followers of this TagRequest. # noqa: E501 - :rtype: list[str] - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this TagRequest. - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :param followers: The followers of this TagRequest. # noqa: E501 - :type: list[str] - """ - - self._followers = followers - - @property - def workspace(self): - """Gets the workspace of this TagRequest. # noqa: E501 - - Gid of an object. # noqa: E501 - - :return: The workspace of this TagRequest. # noqa: E501 - :rtype: str - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this TagRequest. - - Gid of an object. # noqa: E501 - - :param workspace: The workspace of this TagRequest. # noqa: E501 - :type: str - """ - - self._workspace = workspace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TagRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TagRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/tag_response.py b/asana/models/tag_response.py deleted file mode 100644 index 9ab6dd90..00000000 --- a/asana/models/tag_response.py +++ /dev/null @@ -1,340 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TagResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'color': 'str', - 'notes': 'str', - 'created_at': 'datetime', - 'followers': 'list[CustomFieldResponsePeopleValue]', - 'workspace': 'GoalResponseWorkspace', - 'permalink_url': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'color': 'color', - 'notes': 'notes', - 'created_at': 'created_at', - 'followers': 'followers', - 'workspace': 'workspace', - 'permalink_url': 'permalink_url' - } - - def __init__(self, gid=None, resource_type=None, name=None, color=None, notes=None, created_at=None, followers=None, workspace=None, permalink_url=None): # noqa: E501 - """TagResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._color = None - self._notes = None - self._created_at = None - self._followers = None - self._workspace = None - self._permalink_url = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if color is not None: - self.color = color - if notes is not None: - self.notes = notes - if created_at is not None: - self.created_at = created_at - if followers is not None: - self.followers = followers - if workspace is not None: - self.workspace = workspace - if permalink_url is not None: - self.permalink_url = permalink_url - - @property - def gid(self): - """Gets the gid of this TagResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TagResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TagResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TagResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TagResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TagResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TagResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TagResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TagResponse. # noqa: E501 - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this TagResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TagResponse. - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this TagResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def color(self): - """Gets the color of this TagResponse. # noqa: E501 - - Color of the tag. # noqa: E501 - - :return: The color of this TagResponse. # noqa: E501 - :rtype: str - """ - return self._color - - @color.setter - def color(self, color): - """Sets the color of this TagResponse. - - Color of the tag. # noqa: E501 - - :param color: The color of this TagResponse. # noqa: E501 - :type: str - """ - allowed_values = ["dark-pink", "dark-green", "dark-blue", "dark-red", "dark-teal", "dark-brown", "dark-orange", "dark-purple", "dark-warm-gray", "light-pink", "light-green", "light-blue", "light-red", "light-teal", "light-brown", "light-orange", "light-purple", "light-warm-gray", ""] # noqa: E501 - if color not in allowed_values: - raise ValueError( - "Invalid value for `color` ({0}), must be one of {1}" # noqa: E501 - .format(color, allowed_values) - ) - - self._color = color - - @property - def notes(self): - """Gets the notes of this TagResponse. # noqa: E501 - - Free-form textual information associated with the tag (i.e. its description). # noqa: E501 - - :return: The notes of this TagResponse. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this TagResponse. - - Free-form textual information associated with the tag (i.e. its description). # noqa: E501 - - :param notes: The notes of this TagResponse. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def created_at(self): - """Gets the created_at of this TagResponse. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this TagResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this TagResponse. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this TagResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def followers(self): - """Gets the followers of this TagResponse. # noqa: E501 - - Array of users following this tag. # noqa: E501 - - :return: The followers of this TagResponse. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this TagResponse. - - Array of users following this tag. # noqa: E501 - - :param followers: The followers of this TagResponse. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._followers = followers - - @property - def workspace(self): - """Gets the workspace of this TagResponse. # noqa: E501 - - - :return: The workspace of this TagResponse. # noqa: E501 - :rtype: GoalResponseWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this TagResponse. - - - :param workspace: The workspace of this TagResponse. # noqa: E501 - :type: GoalResponseWorkspace - """ - - self._workspace = workspace - - @property - def permalink_url(self): - """Gets the permalink_url of this TagResponse. # noqa: E501 - - A url that points directly to the object within Asana. # noqa: E501 - - :return: The permalink_url of this TagResponse. # noqa: E501 - :rtype: str - """ - return self._permalink_url - - @permalink_url.setter - def permalink_url(self, permalink_url): - """Sets the permalink_url of this TagResponse. - - A url that points directly to the object within Asana. # noqa: E501 - - :param permalink_url: The permalink_url of this TagResponse. # noqa: E501 - :type: str - """ - - self._permalink_url = permalink_url - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TagResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TagResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/tag_response_array.py b/asana/models/tag_response_array.py deleted file mode 100644 index cd4c1adb..00000000 --- a/asana/models/tag_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TagResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[TagResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """TagResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this TagResponseArray. # noqa: E501 - - - :return: The data of this TagResponseArray. # noqa: E501 - :rtype: list[TagResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TagResponseArray. - - - :param data: The data of this TagResponseArray. # noqa: E501 - :type: list[TagResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this TagResponseArray. # noqa: E501 - - - :return: The next_page of this TagResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this TagResponseArray. - - - :param next_page: The next_page of this TagResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TagResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TagResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/tag_response_data.py b/asana/models/tag_response_data.py deleted file mode 100644 index 5656d47c..00000000 --- a/asana/models/tag_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TagResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TagResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TagResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this TagResponseData. # noqa: E501 - - - :return: The data of this TagResponseData. # noqa: E501 - :rtype: TagResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TagResponseData. - - - :param data: The data of this TagResponseData. # noqa: E501 - :type: TagResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TagResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TagResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/tags_body.py b/asana/models/tags_body.py deleted file mode 100644 index 7a2c2746..00000000 --- a/asana/models/tags_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TagsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TagRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TagsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TagsBody. # noqa: E501 - - - :return: The data of this TagsBody. # noqa: E501 - :rtype: TagRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TagsBody. - - - :param data: The data of this TagsBody. # noqa: E501 - :type: TagRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TagsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TagsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_add_followers_request.py b/asana/models/task_add_followers_request.py deleted file mode 100644 index 6dcdc82a..00000000 --- a/asana/models/task_add_followers_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskAddFollowersRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'followers': 'list[str]' - } - - attribute_map = { - 'followers': 'followers' - } - - def __init__(self, followers=None): # noqa: E501 - """TaskAddFollowersRequest - a model defined in Swagger""" # noqa: E501 - self._followers = None - self.discriminator = None - self.followers = followers - - @property - def followers(self): - """Gets the followers of this TaskAddFollowersRequest. # noqa: E501 - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :return: The followers of this TaskAddFollowersRequest. # noqa: E501 - :rtype: list[str] - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this TaskAddFollowersRequest. - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :param followers: The followers of this TaskAddFollowersRequest. # noqa: E501 - :type: list[str] - """ - if followers is None: - raise ValueError("Invalid value for `followers`, must not be `None`") # noqa: E501 - - self._followers = followers - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskAddFollowersRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskAddFollowersRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_add_project_request.py b/asana/models/task_add_project_request.py deleted file mode 100644 index 8eaf4d3e..00000000 --- a/asana/models/task_add_project_request.py +++ /dev/null @@ -1,197 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskAddProjectRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'project': 'str', - 'insert_after': 'str', - 'insert_before': 'str', - 'section': 'str' - } - - attribute_map = { - 'project': 'project', - 'insert_after': 'insert_after', - 'insert_before': 'insert_before', - 'section': 'section' - } - - def __init__(self, project=None, insert_after=None, insert_before=None, section=None): # noqa: E501 - """TaskAddProjectRequest - a model defined in Swagger""" # noqa: E501 - self._project = None - self._insert_after = None - self._insert_before = None - self._section = None - self.discriminator = None - self.project = project - if insert_after is not None: - self.insert_after = insert_after - if insert_before is not None: - self.insert_before = insert_before - if section is not None: - self.section = section - - @property - def project(self): - """Gets the project of this TaskAddProjectRequest. # noqa: E501 - - The project to add the task to. # noqa: E501 - - :return: The project of this TaskAddProjectRequest. # noqa: E501 - :rtype: str - """ - return self._project - - @project.setter - def project(self, project): - """Sets the project of this TaskAddProjectRequest. - - The project to add the task to. # noqa: E501 - - :param project: The project of this TaskAddProjectRequest. # noqa: E501 - :type: str - """ - if project is None: - raise ValueError("Invalid value for `project`, must not be `None`") # noqa: E501 - - self._project = project - - @property - def insert_after(self): - """Gets the insert_after of this TaskAddProjectRequest. # noqa: E501 - - A task in the project to insert the task after, or `null` to insert at the beginning of the list. # noqa: E501 - - :return: The insert_after of this TaskAddProjectRequest. # noqa: E501 - :rtype: str - """ - return self._insert_after - - @insert_after.setter - def insert_after(self, insert_after): - """Sets the insert_after of this TaskAddProjectRequest. - - A task in the project to insert the task after, or `null` to insert at the beginning of the list. # noqa: E501 - - :param insert_after: The insert_after of this TaskAddProjectRequest. # noqa: E501 - :type: str - """ - - self._insert_after = insert_after - - @property - def insert_before(self): - """Gets the insert_before of this TaskAddProjectRequest. # noqa: E501 - - A task in the project to insert the task before, or `null` to insert at the end of the list. # noqa: E501 - - :return: The insert_before of this TaskAddProjectRequest. # noqa: E501 - :rtype: str - """ - return self._insert_before - - @insert_before.setter - def insert_before(self, insert_before): - """Sets the insert_before of this TaskAddProjectRequest. - - A task in the project to insert the task before, or `null` to insert at the end of the list. # noqa: E501 - - :param insert_before: The insert_before of this TaskAddProjectRequest. # noqa: E501 - :type: str - """ - - self._insert_before = insert_before - - @property - def section(self): - """Gets the section of this TaskAddProjectRequest. # noqa: E501 - - A section in the project to insert the task into. The task will be inserted at the bottom of the section. # noqa: E501 - - :return: The section of this TaskAddProjectRequest. # noqa: E501 - :rtype: str - """ - return self._section - - @section.setter - def section(self, section): - """Sets the section of this TaskAddProjectRequest. - - A section in the project to insert the task into. The task will be inserted at the bottom of the section. # noqa: E501 - - :param section: The section of this TaskAddProjectRequest. # noqa: E501 - :type: str - """ - - self._section = section - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskAddProjectRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskAddProjectRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_add_tag_request.py b/asana/models/task_add_tag_request.py deleted file mode 100644 index 77c88906..00000000 --- a/asana/models/task_add_tag_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskAddTagRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'tag': 'str' - } - - attribute_map = { - 'tag': 'tag' - } - - def __init__(self, tag=None): # noqa: E501 - """TaskAddTagRequest - a model defined in Swagger""" # noqa: E501 - self._tag = None - self.discriminator = None - self.tag = tag - - @property - def tag(self): - """Gets the tag of this TaskAddTagRequest. # noqa: E501 - - The tag to add to the task. # noqa: E501 - - :return: The tag of this TaskAddTagRequest. # noqa: E501 - :rtype: str - """ - return self._tag - - @tag.setter - def tag(self, tag): - """Sets the tag of this TaskAddTagRequest. - - The tag to add to the task. # noqa: E501 - - :param tag: The tag of this TaskAddTagRequest. # noqa: E501 - :type: str - """ - if tag is None: - raise ValueError("Invalid value for `tag`, must not be `None`") # noqa: E501 - - self._tag = tag - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskAddTagRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskAddTagRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_base.py b/asana/models/task_base.py deleted file mode 100644 index 4589d390..00000000 --- a/asana/models/task_base.py +++ /dev/null @@ -1,964 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'created_by': 'AttachmentResponseParentCreatedBy', - 'approval_status': 'str', - 'assignee_status': 'str', - 'completed': 'bool', - 'completed_at': 'datetime', - 'completed_by': 'TaskBaseCompletedBy', - 'created_at': 'datetime', - 'dependencies': 'list[TaskBaseDependencies]', - 'dependents': 'list[TaskBaseDependencies]', - 'due_at': 'datetime', - 'due_on': 'date', - 'external': 'TaskBaseExternal', - 'html_notes': 'str', - 'hearted': 'bool', - 'hearts': 'list[GoalResponseLikes]', - 'is_rendered_as_separator': 'bool', - 'liked': 'bool', - 'likes': 'list[GoalResponseLikes]', - 'memberships': 'list[TaskBaseMemberships]', - 'modified_at': 'datetime', - 'notes': 'str', - 'num_hearts': 'int', - 'num_likes': 'int', - 'num_subtasks': 'int', - 'start_at': 'datetime', - 'start_on': 'date', - 'actual_time_minutes': 'float' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'created_by': 'created_by', - 'approval_status': 'approval_status', - 'assignee_status': 'assignee_status', - 'completed': 'completed', - 'completed_at': 'completed_at', - 'completed_by': 'completed_by', - 'created_at': 'created_at', - 'dependencies': 'dependencies', - 'dependents': 'dependents', - 'due_at': 'due_at', - 'due_on': 'due_on', - 'external': 'external', - 'html_notes': 'html_notes', - 'hearted': 'hearted', - 'hearts': 'hearts', - 'is_rendered_as_separator': 'is_rendered_as_separator', - 'liked': 'liked', - 'likes': 'likes', - 'memberships': 'memberships', - 'modified_at': 'modified_at', - 'notes': 'notes', - 'num_hearts': 'num_hearts', - 'num_likes': 'num_likes', - 'num_subtasks': 'num_subtasks', - 'start_at': 'start_at', - 'start_on': 'start_on', - 'actual_time_minutes': 'actual_time_minutes' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, created_by=None, approval_status=None, assignee_status=None, completed=None, completed_at=None, completed_by=None, created_at=None, dependencies=None, dependents=None, due_at=None, due_on=None, external=None, html_notes=None, hearted=None, hearts=None, is_rendered_as_separator=None, liked=None, likes=None, memberships=None, modified_at=None, notes=None, num_hearts=None, num_likes=None, num_subtasks=None, start_at=None, start_on=None, actual_time_minutes=None): # noqa: E501 - """TaskBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._created_by = None - self._approval_status = None - self._assignee_status = None - self._completed = None - self._completed_at = None - self._completed_by = None - self._created_at = None - self._dependencies = None - self._dependents = None - self._due_at = None - self._due_on = None - self._external = None - self._html_notes = None - self._hearted = None - self._hearts = None - self._is_rendered_as_separator = None - self._liked = None - self._likes = None - self._memberships = None - self._modified_at = None - self._notes = None - self._num_hearts = None - self._num_likes = None - self._num_subtasks = None - self._start_at = None - self._start_on = None - self._actual_time_minutes = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if created_by is not None: - self.created_by = created_by - if approval_status is not None: - self.approval_status = approval_status - if assignee_status is not None: - self.assignee_status = assignee_status - if completed is not None: - self.completed = completed - if completed_at is not None: - self.completed_at = completed_at - if completed_by is not None: - self.completed_by = completed_by - if created_at is not None: - self.created_at = created_at - if dependencies is not None: - self.dependencies = dependencies - if dependents is not None: - self.dependents = dependents - if due_at is not None: - self.due_at = due_at - if due_on is not None: - self.due_on = due_on - if external is not None: - self.external = external - if html_notes is not None: - self.html_notes = html_notes - if hearted is not None: - self.hearted = hearted - if hearts is not None: - self.hearts = hearts - if is_rendered_as_separator is not None: - self.is_rendered_as_separator = is_rendered_as_separator - if liked is not None: - self.liked = liked - if likes is not None: - self.likes = likes - if memberships is not None: - self.memberships = memberships - if modified_at is not None: - self.modified_at = modified_at - if notes is not None: - self.notes = notes - if num_hearts is not None: - self.num_hearts = num_hearts - if num_likes is not None: - self.num_likes = num_likes - if num_subtasks is not None: - self.num_subtasks = num_subtasks - if start_at is not None: - self.start_at = start_at - if start_on is not None: - self.start_on = start_on - if actual_time_minutes is not None: - self.actual_time_minutes = actual_time_minutes - - @property - def gid(self): - """Gets the gid of this TaskBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskBase. # noqa: E501 - - Name of the task. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this TaskBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskBase. - - Name of the task. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this TaskBase. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this TaskBase. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :return: The resource_subtype of this TaskBase. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this TaskBase. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :param resource_subtype: The resource_subtype of this TaskBase. # noqa: E501 - :type: str - """ - allowed_values = ["default_task", "milestone", "section", "approval"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def created_by(self): - """Gets the created_by of this TaskBase. # noqa: E501 - - - :return: The created_by of this TaskBase. # noqa: E501 - :rtype: AttachmentResponseParentCreatedBy - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this TaskBase. - - - :param created_by: The created_by of this TaskBase. # noqa: E501 - :type: AttachmentResponseParentCreatedBy - """ - - self._created_by = created_by - - @property - def approval_status(self): - """Gets the approval_status of this TaskBase. # noqa: E501 - - *Conditional* Reflects the approval status of this task. This field is kept in sync with `completed`, meaning `pending` translates to false while `approved`, `rejected`, and `changes_requested` translate to true. If you set completed to true, this field will be set to `approved`. # noqa: E501 - - :return: The approval_status of this TaskBase. # noqa: E501 - :rtype: str - """ - return self._approval_status - - @approval_status.setter - def approval_status(self, approval_status): - """Sets the approval_status of this TaskBase. - - *Conditional* Reflects the approval status of this task. This field is kept in sync with `completed`, meaning `pending` translates to false while `approved`, `rejected`, and `changes_requested` translate to true. If you set completed to true, this field will be set to `approved`. # noqa: E501 - - :param approval_status: The approval_status of this TaskBase. # noqa: E501 - :type: str - """ - allowed_values = ["pending", "approved", "rejected", "changes_requested"] # noqa: E501 - if approval_status not in allowed_values: - raise ValueError( - "Invalid value for `approval_status` ({0}), must be one of {1}" # noqa: E501 - .format(approval_status, allowed_values) - ) - - self._approval_status = approval_status - - @property - def assignee_status(self): - """Gets the assignee_status of this TaskBase. # noqa: E501 - - *Deprecated* Scheduling status of this task for the user it is assigned to. This field can only be set if the assignee is non-null. Setting this field to \"inbox\" or \"upcoming\" inserts it at the top of the section, while the other options will insert at the bottom. # noqa: E501 - - :return: The assignee_status of this TaskBase. # noqa: E501 - :rtype: str - """ - return self._assignee_status - - @assignee_status.setter - def assignee_status(self, assignee_status): - """Sets the assignee_status of this TaskBase. - - *Deprecated* Scheduling status of this task for the user it is assigned to. This field can only be set if the assignee is non-null. Setting this field to \"inbox\" or \"upcoming\" inserts it at the top of the section, while the other options will insert at the bottom. # noqa: E501 - - :param assignee_status: The assignee_status of this TaskBase. # noqa: E501 - :type: str - """ - allowed_values = ["today", "upcoming", "later", "new", "inbox"] # noqa: E501 - if assignee_status not in allowed_values: - raise ValueError( - "Invalid value for `assignee_status` ({0}), must be one of {1}" # noqa: E501 - .format(assignee_status, allowed_values) - ) - - self._assignee_status = assignee_status - - @property - def completed(self): - """Gets the completed of this TaskBase. # noqa: E501 - - True if the task is currently marked complete, false if not. # noqa: E501 - - :return: The completed of this TaskBase. # noqa: E501 - :rtype: bool - """ - return self._completed - - @completed.setter - def completed(self, completed): - """Sets the completed of this TaskBase. - - True if the task is currently marked complete, false if not. # noqa: E501 - - :param completed: The completed of this TaskBase. # noqa: E501 - :type: bool - """ - - self._completed = completed - - @property - def completed_at(self): - """Gets the completed_at of this TaskBase. # noqa: E501 - - The time at which this task was completed, or null if the task is incomplete. # noqa: E501 - - :return: The completed_at of this TaskBase. # noqa: E501 - :rtype: datetime - """ - return self._completed_at - - @completed_at.setter - def completed_at(self, completed_at): - """Sets the completed_at of this TaskBase. - - The time at which this task was completed, or null if the task is incomplete. # noqa: E501 - - :param completed_at: The completed_at of this TaskBase. # noqa: E501 - :type: datetime - """ - - self._completed_at = completed_at - - @property - def completed_by(self): - """Gets the completed_by of this TaskBase. # noqa: E501 - - - :return: The completed_by of this TaskBase. # noqa: E501 - :rtype: TaskBaseCompletedBy - """ - return self._completed_by - - @completed_by.setter - def completed_by(self, completed_by): - """Sets the completed_by of this TaskBase. - - - :param completed_by: The completed_by of this TaskBase. # noqa: E501 - :type: TaskBaseCompletedBy - """ - - self._completed_by = completed_by - - @property - def created_at(self): - """Gets the created_at of this TaskBase. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this TaskBase. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this TaskBase. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this TaskBase. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def dependencies(self): - """Gets the dependencies of this TaskBase. # noqa: E501 - - [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that this task depends on. The objects contain only the gid of the dependency. # noqa: E501 - - :return: The dependencies of this TaskBase. # noqa: E501 - :rtype: list[TaskBaseDependencies] - """ - return self._dependencies - - @dependencies.setter - def dependencies(self, dependencies): - """Sets the dependencies of this TaskBase. - - [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that this task depends on. The objects contain only the gid of the dependency. # noqa: E501 - - :param dependencies: The dependencies of this TaskBase. # noqa: E501 - :type: list[TaskBaseDependencies] - """ - - self._dependencies = dependencies - - @property - def dependents(self): - """Gets the dependents of this TaskBase. # noqa: E501 - - [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that depend on this task. The objects contain only the ID of the dependent. # noqa: E501 - - :return: The dependents of this TaskBase. # noqa: E501 - :rtype: list[TaskBaseDependencies] - """ - return self._dependents - - @dependents.setter - def dependents(self, dependents): - """Sets the dependents of this TaskBase. - - [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that depend on this task. The objects contain only the ID of the dependent. # noqa: E501 - - :param dependents: The dependents of this TaskBase. # noqa: E501 - :type: list[TaskBaseDependencies] - """ - - self._dependents = dependents - - @property - def due_at(self): - """Gets the due_at of this TaskBase. # noqa: E501 - - The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. # noqa: E501 - - :return: The due_at of this TaskBase. # noqa: E501 - :rtype: datetime - """ - return self._due_at - - @due_at.setter - def due_at(self, due_at): - """Sets the due_at of this TaskBase. - - The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. # noqa: E501 - - :param due_at: The due_at of this TaskBase. # noqa: E501 - :type: datetime - """ - - self._due_at = due_at - - @property - def due_on(self): - """Gets the due_on of this TaskBase. # noqa: E501 - - The localized date on which this task is due, or null if the task has no due date. This takes a date with `YYYY-MM-DD` format and should not be used together with `due_at`. # noqa: E501 - - :return: The due_on of this TaskBase. # noqa: E501 - :rtype: date - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this TaskBase. - - The localized date on which this task is due, or null if the task has no due date. This takes a date with `YYYY-MM-DD` format and should not be used together with `due_at`. # noqa: E501 - - :param due_on: The due_on of this TaskBase. # noqa: E501 - :type: date - """ - - self._due_on = due_on - - @property - def external(self): - """Gets the external of this TaskBase. # noqa: E501 - - - :return: The external of this TaskBase. # noqa: E501 - :rtype: TaskBaseExternal - """ - return self._external - - @external.setter - def external(self, external): - """Sets the external of this TaskBase. - - - :param external: The external of this TaskBase. # noqa: E501 - :type: TaskBaseExternal - """ - - self._external = external - - @property - def html_notes(self): - """Gets the html_notes of this TaskBase. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The notes of the text with formatting as HTML. # noqa: E501 - - :return: The html_notes of this TaskBase. # noqa: E501 - :rtype: str - """ - return self._html_notes - - @html_notes.setter - def html_notes(self, html_notes): - """Sets the html_notes of this TaskBase. - - [Opt In](/docs/inputoutput-options). The notes of the text with formatting as HTML. # noqa: E501 - - :param html_notes: The html_notes of this TaskBase. # noqa: E501 - :type: str - """ - - self._html_notes = html_notes - - @property - def hearted(self): - """Gets the hearted of this TaskBase. # noqa: E501 - - *Deprecated - please use liked instead* True if the task is hearted by the authorized user, false if not. # noqa: E501 - - :return: The hearted of this TaskBase. # noqa: E501 - :rtype: bool - """ - return self._hearted - - @hearted.setter - def hearted(self, hearted): - """Sets the hearted of this TaskBase. - - *Deprecated - please use liked instead* True if the task is hearted by the authorized user, false if not. # noqa: E501 - - :param hearted: The hearted of this TaskBase. # noqa: E501 - :type: bool - """ - - self._hearted = hearted - - @property - def hearts(self): - """Gets the hearts of this TaskBase. # noqa: E501 - - *Deprecated - please use likes instead* Array of likes for users who have hearted this task. # noqa: E501 - - :return: The hearts of this TaskBase. # noqa: E501 - :rtype: list[GoalResponseLikes] - """ - return self._hearts - - @hearts.setter - def hearts(self, hearts): - """Sets the hearts of this TaskBase. - - *Deprecated - please use likes instead* Array of likes for users who have hearted this task. # noqa: E501 - - :param hearts: The hearts of this TaskBase. # noqa: E501 - :type: list[GoalResponseLikes] - """ - - self._hearts = hearts - - @property - def is_rendered_as_separator(self): - """Gets the is_rendered_as_separator of this TaskBase. # noqa: E501 - - [Opt In](/docs/inputoutput-options). In some contexts tasks can be rendered as a visual separator; for instance, subtasks can appear similar to [sections](/reference/sections) without being true `section` objects. If a `task` object is rendered this way in any context it will have the property `is_rendered_as_separator` set to `true`. # noqa: E501 - - :return: The is_rendered_as_separator of this TaskBase. # noqa: E501 - :rtype: bool - """ - return self._is_rendered_as_separator - - @is_rendered_as_separator.setter - def is_rendered_as_separator(self, is_rendered_as_separator): - """Sets the is_rendered_as_separator of this TaskBase. - - [Opt In](/docs/inputoutput-options). In some contexts tasks can be rendered as a visual separator; for instance, subtasks can appear similar to [sections](/reference/sections) without being true `section` objects. If a `task` object is rendered this way in any context it will have the property `is_rendered_as_separator` set to `true`. # noqa: E501 - - :param is_rendered_as_separator: The is_rendered_as_separator of this TaskBase. # noqa: E501 - :type: bool - """ - - self._is_rendered_as_separator = is_rendered_as_separator - - @property - def liked(self): - """Gets the liked of this TaskBase. # noqa: E501 - - True if the task is liked by the authorized user, false if not. # noqa: E501 - - :return: The liked of this TaskBase. # noqa: E501 - :rtype: bool - """ - return self._liked - - @liked.setter - def liked(self, liked): - """Sets the liked of this TaskBase. - - True if the task is liked by the authorized user, false if not. # noqa: E501 - - :param liked: The liked of this TaskBase. # noqa: E501 - :type: bool - """ - - self._liked = liked - - @property - def likes(self): - """Gets the likes of this TaskBase. # noqa: E501 - - Array of likes for users who have liked this task. # noqa: E501 - - :return: The likes of this TaskBase. # noqa: E501 - :rtype: list[GoalResponseLikes] - """ - return self._likes - - @likes.setter - def likes(self, likes): - """Sets the likes of this TaskBase. - - Array of likes for users who have liked this task. # noqa: E501 - - :param likes: The likes of this TaskBase. # noqa: E501 - :type: list[GoalResponseLikes] - """ - - self._likes = likes - - @property - def memberships(self): - """Gets the memberships of this TaskBase. # noqa: E501 - - *Create-only*. Array of projects this task is associated with and the section it is in. At task creation time, this array can be used to add the task to specific sections. After task creation, these associations can be modified using the `addProject` and `removeProject` endpoints. Note that over time, more types of memberships may be added to this property. # noqa: E501 - - :return: The memberships of this TaskBase. # noqa: E501 - :rtype: list[TaskBaseMemberships] - """ - return self._memberships - - @memberships.setter - def memberships(self, memberships): - """Sets the memberships of this TaskBase. - - *Create-only*. Array of projects this task is associated with and the section it is in. At task creation time, this array can be used to add the task to specific sections. After task creation, these associations can be modified using the `addProject` and `removeProject` endpoints. Note that over time, more types of memberships may be added to this property. # noqa: E501 - - :param memberships: The memberships of this TaskBase. # noqa: E501 - :type: list[TaskBaseMemberships] - """ - - self._memberships = memberships - - @property - def modified_at(self): - """Gets the modified_at of this TaskBase. # noqa: E501 - - The time at which this task was last modified. The following conditions will change `modified_at`: - story is created on a task - story is trashed on a task - attachment is trashed on a task - task is assigned or unassigned - custom field value is changed - the task itself is trashed - Or if any of the following fields are updated: - completed - name - due_date - description - attachments - items - schedule_status The following conditions will _not_ change `modified_at`: - moving to a new container (project, portfolio, etc) - comments being added to the task (but the stories they generate _will_ affect `modified_at`) # noqa: E501 - - :return: The modified_at of this TaskBase. # noqa: E501 - :rtype: datetime - """ - return self._modified_at - - @modified_at.setter - def modified_at(self, modified_at): - """Sets the modified_at of this TaskBase. - - The time at which this task was last modified. The following conditions will change `modified_at`: - story is created on a task - story is trashed on a task - attachment is trashed on a task - task is assigned or unassigned - custom field value is changed - the task itself is trashed - Or if any of the following fields are updated: - completed - name - due_date - description - attachments - items - schedule_status The following conditions will _not_ change `modified_at`: - moving to a new container (project, portfolio, etc) - comments being added to the task (but the stories they generate _will_ affect `modified_at`) # noqa: E501 - - :param modified_at: The modified_at of this TaskBase. # noqa: E501 - :type: datetime - """ - - self._modified_at = modified_at - - @property - def notes(self): - """Gets the notes of this TaskBase. # noqa: E501 - - Free-form textual information associated with the task (i.e. its description). # noqa: E501 - - :return: The notes of this TaskBase. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this TaskBase. - - Free-form textual information associated with the task (i.e. its description). # noqa: E501 - - :param notes: The notes of this TaskBase. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def num_hearts(self): - """Gets the num_hearts of this TaskBase. # noqa: E501 - - *Deprecated - please use likes instead* The number of users who have hearted this task. # noqa: E501 - - :return: The num_hearts of this TaskBase. # noqa: E501 - :rtype: int - """ - return self._num_hearts - - @num_hearts.setter - def num_hearts(self, num_hearts): - """Sets the num_hearts of this TaskBase. - - *Deprecated - please use likes instead* The number of users who have hearted this task. # noqa: E501 - - :param num_hearts: The num_hearts of this TaskBase. # noqa: E501 - :type: int - """ - - self._num_hearts = num_hearts - - @property - def num_likes(self): - """Gets the num_likes of this TaskBase. # noqa: E501 - - The number of users who have liked this task. # noqa: E501 - - :return: The num_likes of this TaskBase. # noqa: E501 - :rtype: int - """ - return self._num_likes - - @num_likes.setter - def num_likes(self, num_likes): - """Sets the num_likes of this TaskBase. - - The number of users who have liked this task. # noqa: E501 - - :param num_likes: The num_likes of this TaskBase. # noqa: E501 - :type: int - """ - - self._num_likes = num_likes - - @property - def num_subtasks(self): - """Gets the num_subtasks of this TaskBase. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The number of subtasks on this task. # noqa: E501 - - :return: The num_subtasks of this TaskBase. # noqa: E501 - :rtype: int - """ - return self._num_subtasks - - @num_subtasks.setter - def num_subtasks(self, num_subtasks): - """Sets the num_subtasks of this TaskBase. - - [Opt In](/docs/inputoutput-options). The number of subtasks on this task. # noqa: E501 - - :param num_subtasks: The num_subtasks of this TaskBase. # noqa: E501 - :type: int - """ - - self._num_subtasks = num_subtasks - - @property - def start_at(self): - """Gets the start_at of this TaskBase. # noqa: E501 - - Date and time on which work begins for the task, or null if the task has no start time. This takes an ISO 8601 date string in UTC and should not be used together with `start_on`. *Note: `due_at` must be present in the request when setting or unsetting the `start_at` parameter.* # noqa: E501 - - :return: The start_at of this TaskBase. # noqa: E501 - :rtype: datetime - """ - return self._start_at - - @start_at.setter - def start_at(self, start_at): - """Sets the start_at of this TaskBase. - - Date and time on which work begins for the task, or null if the task has no start time. This takes an ISO 8601 date string in UTC and should not be used together with `start_on`. *Note: `due_at` must be present in the request when setting or unsetting the `start_at` parameter.* # noqa: E501 - - :param start_at: The start_at of this TaskBase. # noqa: E501 - :type: datetime - """ - - self._start_at = start_at - - @property - def start_on(self): - """Gets the start_on of this TaskBase. # noqa: E501 - - The day on which work begins for the task , or null if the task has no start date. This takes a date with `YYYY-MM-DD` format and should not be used together with `start_at`. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter.* # noqa: E501 - - :return: The start_on of this TaskBase. # noqa: E501 - :rtype: date - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this TaskBase. - - The day on which work begins for the task , or null if the task has no start date. This takes a date with `YYYY-MM-DD` format and should not be used together with `start_at`. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter.* # noqa: E501 - - :param start_on: The start_on of this TaskBase. # noqa: E501 - :type: date - """ - - self._start_on = start_on - - @property - def actual_time_minutes(self): - """Gets the actual_time_minutes of this TaskBase. # noqa: E501 - - This value represents the sum of all the Time Tracking entries in the Actual Time field on a given Task. It is represented as a nullable long value. # noqa: E501 - - :return: The actual_time_minutes of this TaskBase. # noqa: E501 - :rtype: float - """ - return self._actual_time_minutes - - @actual_time_minutes.setter - def actual_time_minutes(self, actual_time_minutes): - """Sets the actual_time_minutes of this TaskBase. - - This value represents the sum of all the Time Tracking entries in the Actual Time field on a given Task. It is represented as a nullable long value. # noqa: E501 - - :param actual_time_minutes: The actual_time_minutes of this TaskBase. # noqa: E501 - :type: float - """ - - self._actual_time_minutes = actual_time_minutes - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_base_completed_by.py b/asana/models/task_base_completed_by.py deleted file mode 100644 index 7792d719..00000000 --- a/asana/models/task_base_completed_by.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskBaseCompletedBy(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """TaskBaseCompletedBy - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this TaskBaseCompletedBy. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskBaseCompletedBy. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskBaseCompletedBy. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskBaseCompletedBy. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskBaseCompletedBy. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskBaseCompletedBy. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskBaseCompletedBy. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskBaseCompletedBy. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskBaseCompletedBy. # noqa: E501 - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :return: The name of this TaskBaseCompletedBy. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskBaseCompletedBy. - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :param name: The name of this TaskBaseCompletedBy. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskBaseCompletedBy, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskBaseCompletedBy): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_base_dependencies.py b/asana/models/task_base_dependencies.py deleted file mode 100644 index a04109e7..00000000 --- a/asana/models/task_base_dependencies.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskBaseDependencies(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type' - } - - def __init__(self, gid=None, resource_type=None): # noqa: E501 - """TaskBaseDependencies - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - - @property - def gid(self): - """Gets the gid of this TaskBaseDependencies. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskBaseDependencies. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskBaseDependencies. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskBaseDependencies. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskBaseDependencies. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskBaseDependencies. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskBaseDependencies. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskBaseDependencies. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskBaseDependencies, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskBaseDependencies): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_base_external.py b/asana/models/task_base_external.py deleted file mode 100644 index 6476ed6b..00000000 --- a/asana/models/task_base_external.py +++ /dev/null @@ -1,136 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskBaseExternal(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'data': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'data': 'data' - } - - def __init__(self, gid=None, data=None): # noqa: E501 - """TaskBaseExternal - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._data = None - self.discriminator = None - if gid is not None: - self.gid = gid - if data is not None: - self.data = data - - @property - def gid(self): - """Gets the gid of this TaskBaseExternal. # noqa: E501 - - - :return: The gid of this TaskBaseExternal. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskBaseExternal. - - - :param gid: The gid of this TaskBaseExternal. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def data(self): - """Gets the data of this TaskBaseExternal. # noqa: E501 - - - :return: The data of this TaskBaseExternal. # noqa: E501 - :rtype: str - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskBaseExternal. - - - :param data: The data of this TaskBaseExternal. # noqa: E501 - :type: str - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskBaseExternal, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskBaseExternal): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_base_memberships.py b/asana/models/task_base_memberships.py deleted file mode 100644 index 0818e2ac..00000000 --- a/asana/models/task_base_memberships.py +++ /dev/null @@ -1,136 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskBaseMemberships(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'project': 'JobBaseNewProject', - 'section': 'TaskBaseSection' - } - - attribute_map = { - 'project': 'project', - 'section': 'section' - } - - def __init__(self, project=None, section=None): # noqa: E501 - """TaskBaseMemberships - a model defined in Swagger""" # noqa: E501 - self._project = None - self._section = None - self.discriminator = None - if project is not None: - self.project = project - if section is not None: - self.section = section - - @property - def project(self): - """Gets the project of this TaskBaseMemberships. # noqa: E501 - - - :return: The project of this TaskBaseMemberships. # noqa: E501 - :rtype: JobBaseNewProject - """ - return self._project - - @project.setter - def project(self, project): - """Sets the project of this TaskBaseMemberships. - - - :param project: The project of this TaskBaseMemberships. # noqa: E501 - :type: JobBaseNewProject - """ - - self._project = project - - @property - def section(self): - """Gets the section of this TaskBaseMemberships. # noqa: E501 - - - :return: The section of this TaskBaseMemberships. # noqa: E501 - :rtype: TaskBaseSection - """ - return self._section - - @section.setter - def section(self, section): - """Sets the section of this TaskBaseMemberships. - - - :param section: The section of this TaskBaseMemberships. # noqa: E501 - :type: TaskBaseSection - """ - - self._section = section - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskBaseMemberships, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskBaseMemberships): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_base_section.py b/asana/models/task_base_section.py deleted file mode 100644 index 79369035..00000000 --- a/asana/models/task_base_section.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskBaseSection(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """TaskBaseSection - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this TaskBaseSection. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskBaseSection. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskBaseSection. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskBaseSection. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskBaseSection. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskBaseSection. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskBaseSection. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskBaseSection. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskBaseSection. # noqa: E501 - - The name of the section (i.e. the text displayed as the section header). # noqa: E501 - - :return: The name of this TaskBaseSection. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskBaseSection. - - The name of the section (i.e. the text displayed as the section header). # noqa: E501 - - :param name: The name of this TaskBaseSection. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskBaseSection, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskBaseSection): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_compact.py b/asana/models/task_compact.py deleted file mode 100644 index 826f6278..00000000 --- a/asana/models/task_compact.py +++ /dev/null @@ -1,228 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'created_by': 'AttachmentResponseParentCreatedBy' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'created_by': 'created_by' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, created_by=None): # noqa: E501 - """TaskCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._created_by = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if created_by is not None: - self.created_by = created_by - - @property - def gid(self): - """Gets the gid of this TaskCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskCompact. # noqa: E501 - - The name of the task. # noqa: E501 - - :return: The name of this TaskCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskCompact. - - The name of the task. # noqa: E501 - - :param name: The name of this TaskCompact. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this TaskCompact. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :return: The resource_subtype of this TaskCompact. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this TaskCompact. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :param resource_subtype: The resource_subtype of this TaskCompact. # noqa: E501 - :type: str - """ - allowed_values = ["default_task", "milestone", "section", "approval"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def created_by(self): - """Gets the created_by of this TaskCompact. # noqa: E501 - - - :return: The created_by of this TaskCompact. # noqa: E501 - :rtype: AttachmentResponseParentCreatedBy - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this TaskCompact. - - - :param created_by: The created_by of this TaskCompact. # noqa: E501 - :type: AttachmentResponseParentCreatedBy - """ - - self._created_by = created_by - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_count_response.py b/asana/models/task_count_response.py deleted file mode 100644 index 57762828..00000000 --- a/asana/models/task_count_response.py +++ /dev/null @@ -1,252 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskCountResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'num_tasks': 'int', - 'num_incomplete_tasks': 'int', - 'num_completed_tasks': 'int', - 'num_milestones': 'int', - 'num_incomplete_milestones': 'int', - 'num_completed_milestones': 'int' - } - - attribute_map = { - 'num_tasks': 'num_tasks', - 'num_incomplete_tasks': 'num_incomplete_tasks', - 'num_completed_tasks': 'num_completed_tasks', - 'num_milestones': 'num_milestones', - 'num_incomplete_milestones': 'num_incomplete_milestones', - 'num_completed_milestones': 'num_completed_milestones' - } - - def __init__(self, num_tasks=None, num_incomplete_tasks=None, num_completed_tasks=None, num_milestones=None, num_incomplete_milestones=None, num_completed_milestones=None): # noqa: E501 - """TaskCountResponse - a model defined in Swagger""" # noqa: E501 - self._num_tasks = None - self._num_incomplete_tasks = None - self._num_completed_tasks = None - self._num_milestones = None - self._num_incomplete_milestones = None - self._num_completed_milestones = None - self.discriminator = None - if num_tasks is not None: - self.num_tasks = num_tasks - if num_incomplete_tasks is not None: - self.num_incomplete_tasks = num_incomplete_tasks - if num_completed_tasks is not None: - self.num_completed_tasks = num_completed_tasks - if num_milestones is not None: - self.num_milestones = num_milestones - if num_incomplete_milestones is not None: - self.num_incomplete_milestones = num_incomplete_milestones - if num_completed_milestones is not None: - self.num_completed_milestones = num_completed_milestones - - @property - def num_tasks(self): - """Gets the num_tasks of this TaskCountResponse. # noqa: E501 - - The number of tasks in a project. # noqa: E501 - - :return: The num_tasks of this TaskCountResponse. # noqa: E501 - :rtype: int - """ - return self._num_tasks - - @num_tasks.setter - def num_tasks(self, num_tasks): - """Sets the num_tasks of this TaskCountResponse. - - The number of tasks in a project. # noqa: E501 - - :param num_tasks: The num_tasks of this TaskCountResponse. # noqa: E501 - :type: int - """ - - self._num_tasks = num_tasks - - @property - def num_incomplete_tasks(self): - """Gets the num_incomplete_tasks of this TaskCountResponse. # noqa: E501 - - The number of incomplete tasks in a project. # noqa: E501 - - :return: The num_incomplete_tasks of this TaskCountResponse. # noqa: E501 - :rtype: int - """ - return self._num_incomplete_tasks - - @num_incomplete_tasks.setter - def num_incomplete_tasks(self, num_incomplete_tasks): - """Sets the num_incomplete_tasks of this TaskCountResponse. - - The number of incomplete tasks in a project. # noqa: E501 - - :param num_incomplete_tasks: The num_incomplete_tasks of this TaskCountResponse. # noqa: E501 - :type: int - """ - - self._num_incomplete_tasks = num_incomplete_tasks - - @property - def num_completed_tasks(self): - """Gets the num_completed_tasks of this TaskCountResponse. # noqa: E501 - - The number of completed tasks in a project. # noqa: E501 - - :return: The num_completed_tasks of this TaskCountResponse. # noqa: E501 - :rtype: int - """ - return self._num_completed_tasks - - @num_completed_tasks.setter - def num_completed_tasks(self, num_completed_tasks): - """Sets the num_completed_tasks of this TaskCountResponse. - - The number of completed tasks in a project. # noqa: E501 - - :param num_completed_tasks: The num_completed_tasks of this TaskCountResponse. # noqa: E501 - :type: int - """ - - self._num_completed_tasks = num_completed_tasks - - @property - def num_milestones(self): - """Gets the num_milestones of this TaskCountResponse. # noqa: E501 - - The number of milestones in a project. # noqa: E501 - - :return: The num_milestones of this TaskCountResponse. # noqa: E501 - :rtype: int - """ - return self._num_milestones - - @num_milestones.setter - def num_milestones(self, num_milestones): - """Sets the num_milestones of this TaskCountResponse. - - The number of milestones in a project. # noqa: E501 - - :param num_milestones: The num_milestones of this TaskCountResponse. # noqa: E501 - :type: int - """ - - self._num_milestones = num_milestones - - @property - def num_incomplete_milestones(self): - """Gets the num_incomplete_milestones of this TaskCountResponse. # noqa: E501 - - The number of incomplete milestones in a project. # noqa: E501 - - :return: The num_incomplete_milestones of this TaskCountResponse. # noqa: E501 - :rtype: int - """ - return self._num_incomplete_milestones - - @num_incomplete_milestones.setter - def num_incomplete_milestones(self, num_incomplete_milestones): - """Sets the num_incomplete_milestones of this TaskCountResponse. - - The number of incomplete milestones in a project. # noqa: E501 - - :param num_incomplete_milestones: The num_incomplete_milestones of this TaskCountResponse. # noqa: E501 - :type: int - """ - - self._num_incomplete_milestones = num_incomplete_milestones - - @property - def num_completed_milestones(self): - """Gets the num_completed_milestones of this TaskCountResponse. # noqa: E501 - - The number of completed milestones in a project. # noqa: E501 - - :return: The num_completed_milestones of this TaskCountResponse. # noqa: E501 - :rtype: int - """ - return self._num_completed_milestones - - @num_completed_milestones.setter - def num_completed_milestones(self, num_completed_milestones): - """Sets the num_completed_milestones of this TaskCountResponse. - - The number of completed milestones in a project. # noqa: E501 - - :param num_completed_milestones: The num_completed_milestones of this TaskCountResponse. # noqa: E501 - :type: int - """ - - self._num_completed_milestones = num_completed_milestones - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskCountResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskCountResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_count_response_data.py b/asana/models/task_count_response_data.py deleted file mode 100644 index b1b1ee52..00000000 --- a/asana/models/task_count_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskCountResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskCountResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskCountResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this TaskCountResponseData. # noqa: E501 - - - :return: The data of this TaskCountResponseData. # noqa: E501 - :rtype: TaskCountResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskCountResponseData. - - - :param data: The data of this TaskCountResponseData. # noqa: E501 - :type: TaskCountResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskCountResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskCountResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_duplicate_request.py b/asana/models/task_duplicate_request.py deleted file mode 100644 index b71527ea..00000000 --- a/asana/models/task_duplicate_request.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskDuplicateRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'name': 'str', - 'include': 'str' - } - - attribute_map = { - 'name': 'name', - 'include': 'include' - } - - def __init__(self, name=None, include=None): # noqa: E501 - """TaskDuplicateRequest - a model defined in Swagger""" # noqa: E501 - self._name = None - self._include = None - self.discriminator = None - if name is not None: - self.name = name - if include is not None: - self.include = include - - @property - def name(self): - """Gets the name of this TaskDuplicateRequest. # noqa: E501 - - The name of the new task. # noqa: E501 - - :return: The name of this TaskDuplicateRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskDuplicateRequest. - - The name of the new task. # noqa: E501 - - :param name: The name of this TaskDuplicateRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def include(self): - """Gets the include of this TaskDuplicateRequest. # noqa: E501 - - A comma-separated list of fields that will be duplicated to the new task. ##### Fields - assignee - attachments - dates - dependencies - followers - notes - parent - projects - subtasks - tags # noqa: E501 - - :return: The include of this TaskDuplicateRequest. # noqa: E501 - :rtype: str - """ - return self._include - - @include.setter - def include(self, include): - """Sets the include of this TaskDuplicateRequest. - - A comma-separated list of fields that will be duplicated to the new task. ##### Fields - assignee - attachments - dates - dependencies - followers - notes - parent - projects - subtasks - tags # noqa: E501 - - :param include: The include of this TaskDuplicateRequest. # noqa: E501 - :type: str - """ - - self._include = include - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskDuplicateRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskDuplicateRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_add_dependencies_body.py b/asana/models/task_gid_add_dependencies_body.py deleted file mode 100644 index b9a29c1a..00000000 --- a/asana/models/task_gid_add_dependencies_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidAddDependenciesBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ModifyDependenciesRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidAddDependenciesBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidAddDependenciesBody. # noqa: E501 - - - :return: The data of this TaskGidAddDependenciesBody. # noqa: E501 - :rtype: ModifyDependenciesRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidAddDependenciesBody. - - - :param data: The data of this TaskGidAddDependenciesBody. # noqa: E501 - :type: ModifyDependenciesRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidAddDependenciesBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidAddDependenciesBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_add_dependents_body.py b/asana/models/task_gid_add_dependents_body.py deleted file mode 100644 index 3d4c9dc4..00000000 --- a/asana/models/task_gid_add_dependents_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidAddDependentsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ModifyDependentsRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidAddDependentsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidAddDependentsBody. # noqa: E501 - - - :return: The data of this TaskGidAddDependentsBody. # noqa: E501 - :rtype: ModifyDependentsRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidAddDependentsBody. - - - :param data: The data of this TaskGidAddDependentsBody. # noqa: E501 - :type: ModifyDependentsRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidAddDependentsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidAddDependentsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_add_followers_body.py b/asana/models/task_gid_add_followers_body.py deleted file mode 100644 index b030a351..00000000 --- a/asana/models/task_gid_add_followers_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidAddFollowersBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskAddFollowersRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidAddFollowersBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidAddFollowersBody. # noqa: E501 - - - :return: The data of this TaskGidAddFollowersBody. # noqa: E501 - :rtype: TaskAddFollowersRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidAddFollowersBody. - - - :param data: The data of this TaskGidAddFollowersBody. # noqa: E501 - :type: TaskAddFollowersRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidAddFollowersBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidAddFollowersBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_add_project_body.py b/asana/models/task_gid_add_project_body.py deleted file mode 100644 index b8b08ba7..00000000 --- a/asana/models/task_gid_add_project_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidAddProjectBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskAddProjectRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidAddProjectBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidAddProjectBody. # noqa: E501 - - - :return: The data of this TaskGidAddProjectBody. # noqa: E501 - :rtype: TaskAddProjectRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidAddProjectBody. - - - :param data: The data of this TaskGidAddProjectBody. # noqa: E501 - :type: TaskAddProjectRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidAddProjectBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidAddProjectBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_add_tag_body.py b/asana/models/task_gid_add_tag_body.py deleted file mode 100644 index 359a42bb..00000000 --- a/asana/models/task_gid_add_tag_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidAddTagBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskAddTagRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidAddTagBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidAddTagBody. # noqa: E501 - - - :return: The data of this TaskGidAddTagBody. # noqa: E501 - :rtype: TaskAddTagRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidAddTagBody. - - - :param data: The data of this TaskGidAddTagBody. # noqa: E501 - :type: TaskAddTagRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidAddTagBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidAddTagBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_duplicate_body.py b/asana/models/task_gid_duplicate_body.py deleted file mode 100644 index c61f411c..00000000 --- a/asana/models/task_gid_duplicate_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidDuplicateBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskDuplicateRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidDuplicateBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidDuplicateBody. # noqa: E501 - - - :return: The data of this TaskGidDuplicateBody. # noqa: E501 - :rtype: TaskDuplicateRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidDuplicateBody. - - - :param data: The data of this TaskGidDuplicateBody. # noqa: E501 - :type: TaskDuplicateRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidDuplicateBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidDuplicateBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_remove_dependencies_body.py b/asana/models/task_gid_remove_dependencies_body.py deleted file mode 100644 index d0e5c870..00000000 --- a/asana/models/task_gid_remove_dependencies_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidRemoveDependenciesBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ModifyDependenciesRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidRemoveDependenciesBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidRemoveDependenciesBody. # noqa: E501 - - - :return: The data of this TaskGidRemoveDependenciesBody. # noqa: E501 - :rtype: ModifyDependenciesRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidRemoveDependenciesBody. - - - :param data: The data of this TaskGidRemoveDependenciesBody. # noqa: E501 - :type: ModifyDependenciesRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidRemoveDependenciesBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidRemoveDependenciesBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_remove_dependents_body.py b/asana/models/task_gid_remove_dependents_body.py deleted file mode 100644 index 09838af3..00000000 --- a/asana/models/task_gid_remove_dependents_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidRemoveDependentsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ModifyDependentsRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidRemoveDependentsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidRemoveDependentsBody. # noqa: E501 - - - :return: The data of this TaskGidRemoveDependentsBody. # noqa: E501 - :rtype: ModifyDependentsRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidRemoveDependentsBody. - - - :param data: The data of this TaskGidRemoveDependentsBody. # noqa: E501 - :type: ModifyDependentsRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidRemoveDependentsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidRemoveDependentsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_remove_followers_body.py b/asana/models/task_gid_remove_followers_body.py deleted file mode 100644 index e6465cc1..00000000 --- a/asana/models/task_gid_remove_followers_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidRemoveFollowersBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskRemoveFollowersRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidRemoveFollowersBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidRemoveFollowersBody. # noqa: E501 - - - :return: The data of this TaskGidRemoveFollowersBody. # noqa: E501 - :rtype: TaskRemoveFollowersRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidRemoveFollowersBody. - - - :param data: The data of this TaskGidRemoveFollowersBody. # noqa: E501 - :type: TaskRemoveFollowersRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidRemoveFollowersBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidRemoveFollowersBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_remove_project_body.py b/asana/models/task_gid_remove_project_body.py deleted file mode 100644 index 9c5536ba..00000000 --- a/asana/models/task_gid_remove_project_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidRemoveProjectBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskRemoveProjectRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidRemoveProjectBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidRemoveProjectBody. # noqa: E501 - - - :return: The data of this TaskGidRemoveProjectBody. # noqa: E501 - :rtype: TaskRemoveProjectRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidRemoveProjectBody. - - - :param data: The data of this TaskGidRemoveProjectBody. # noqa: E501 - :type: TaskRemoveProjectRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidRemoveProjectBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidRemoveProjectBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_remove_tag_body.py b/asana/models/task_gid_remove_tag_body.py deleted file mode 100644 index 2de38942..00000000 --- a/asana/models/task_gid_remove_tag_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidRemoveTagBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskRemoveTagRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidRemoveTagBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidRemoveTagBody. # noqa: E501 - - - :return: The data of this TaskGidRemoveTagBody. # noqa: E501 - :rtype: TaskRemoveTagRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidRemoveTagBody. - - - :param data: The data of this TaskGidRemoveTagBody. # noqa: E501 - :type: TaskRemoveTagRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidRemoveTagBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidRemoveTagBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_set_parent_body.py b/asana/models/task_gid_set_parent_body.py deleted file mode 100644 index c31b3e43..00000000 --- a/asana/models/task_gid_set_parent_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidSetParentBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskSetParentRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidSetParentBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidSetParentBody. # noqa: E501 - - - :return: The data of this TaskGidSetParentBody. # noqa: E501 - :rtype: TaskSetParentRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidSetParentBody. - - - :param data: The data of this TaskGidSetParentBody. # noqa: E501 - :type: TaskSetParentRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidSetParentBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidSetParentBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_stories_body.py b/asana/models/task_gid_stories_body.py deleted file mode 100644 index 289913c2..00000000 --- a/asana/models/task_gid_stories_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidStoriesBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'StoryRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidStoriesBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidStoriesBody. # noqa: E501 - - - :return: The data of this TaskGidStoriesBody. # noqa: E501 - :rtype: StoryRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidStoriesBody. - - - :param data: The data of this TaskGidStoriesBody. # noqa: E501 - :type: StoryRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidStoriesBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidStoriesBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_subtasks_body.py b/asana/models/task_gid_subtasks_body.py deleted file mode 100644 index f2479c56..00000000 --- a/asana/models/task_gid_subtasks_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidSubtasksBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidSubtasksBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidSubtasksBody. # noqa: E501 - - - :return: The data of this TaskGidSubtasksBody. # noqa: E501 - :rtype: TaskRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidSubtasksBody. - - - :param data: The data of this TaskGidSubtasksBody. # noqa: E501 - :type: TaskRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidSubtasksBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidSubtasksBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_gid_time_tracking_entries_body.py b/asana/models/task_gid_time_tracking_entries_body.py deleted file mode 100644 index b1ca9b0e..00000000 --- a/asana/models/task_gid_time_tracking_entries_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskGidTimeTrackingEntriesBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'CreateTimeTrackingEntryRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskGidTimeTrackingEntriesBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskGidTimeTrackingEntriesBody. # noqa: E501 - - - :return: The data of this TaskGidTimeTrackingEntriesBody. # noqa: E501 - :rtype: CreateTimeTrackingEntryRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskGidTimeTrackingEntriesBody. - - - :param data: The data of this TaskGidTimeTrackingEntriesBody. # noqa: E501 - :type: CreateTimeTrackingEntryRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskGidTimeTrackingEntriesBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskGidTimeTrackingEntriesBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_remove_followers_request.py b/asana/models/task_remove_followers_request.py deleted file mode 100644 index 5d36fef8..00000000 --- a/asana/models/task_remove_followers_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskRemoveFollowersRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'followers': 'list[str]' - } - - attribute_map = { - 'followers': 'followers' - } - - def __init__(self, followers=None): # noqa: E501 - """TaskRemoveFollowersRequest - a model defined in Swagger""" # noqa: E501 - self._followers = None - self.discriminator = None - self.followers = followers - - @property - def followers(self): - """Gets the followers of this TaskRemoveFollowersRequest. # noqa: E501 - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :return: The followers of this TaskRemoveFollowersRequest. # noqa: E501 - :rtype: list[str] - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this TaskRemoveFollowersRequest. - - An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :param followers: The followers of this TaskRemoveFollowersRequest. # noqa: E501 - :type: list[str] - """ - if followers is None: - raise ValueError("Invalid value for `followers`, must not be `None`") # noqa: E501 - - self._followers = followers - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskRemoveFollowersRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskRemoveFollowersRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_remove_project_request.py b/asana/models/task_remove_project_request.py deleted file mode 100644 index 1c11071e..00000000 --- a/asana/models/task_remove_project_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskRemoveProjectRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'project': 'str' - } - - attribute_map = { - 'project': 'project' - } - - def __init__(self, project=None): # noqa: E501 - """TaskRemoveProjectRequest - a model defined in Swagger""" # noqa: E501 - self._project = None - self.discriminator = None - self.project = project - - @property - def project(self): - """Gets the project of this TaskRemoveProjectRequest. # noqa: E501 - - The project to remove the task from. # noqa: E501 - - :return: The project of this TaskRemoveProjectRequest. # noqa: E501 - :rtype: str - """ - return self._project - - @project.setter - def project(self, project): - """Sets the project of this TaskRemoveProjectRequest. - - The project to remove the task from. # noqa: E501 - - :param project: The project of this TaskRemoveProjectRequest. # noqa: E501 - :type: str - """ - if project is None: - raise ValueError("Invalid value for `project`, must not be `None`") # noqa: E501 - - self._project = project - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskRemoveProjectRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskRemoveProjectRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_remove_tag_request.py b/asana/models/task_remove_tag_request.py deleted file mode 100644 index 435cc39a..00000000 --- a/asana/models/task_remove_tag_request.py +++ /dev/null @@ -1,113 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskRemoveTagRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'tag': 'str' - } - - attribute_map = { - 'tag': 'tag' - } - - def __init__(self, tag=None): # noqa: E501 - """TaskRemoveTagRequest - a model defined in Swagger""" # noqa: E501 - self._tag = None - self.discriminator = None - self.tag = tag - - @property - def tag(self): - """Gets the tag of this TaskRemoveTagRequest. # noqa: E501 - - The tag to remove from the task. # noqa: E501 - - :return: The tag of this TaskRemoveTagRequest. # noqa: E501 - :rtype: str - """ - return self._tag - - @tag.setter - def tag(self, tag): - """Sets the tag of this TaskRemoveTagRequest. - - The tag to remove from the task. # noqa: E501 - - :param tag: The tag of this TaskRemoveTagRequest. # noqa: E501 - :type: str - """ - if tag is None: - raise ValueError("Invalid value for `tag`, must not be `None`") # noqa: E501 - - self._tag = tag - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskRemoveTagRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskRemoveTagRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_request.py b/asana/models/task_request.py deleted file mode 100644 index a0f77ae0..00000000 --- a/asana/models/task_request.py +++ /dev/null @@ -1,1188 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'created_by': 'AttachmentResponseParentCreatedBy', - 'approval_status': 'str', - 'assignee_status': 'str', - 'completed': 'bool', - 'completed_at': 'datetime', - 'completed_by': 'TaskBaseCompletedBy', - 'created_at': 'datetime', - 'dependencies': 'list[TaskBaseDependencies]', - 'dependents': 'list[TaskBaseDependencies]', - 'due_at': 'datetime', - 'due_on': 'date', - 'external': 'TaskBaseExternal', - 'html_notes': 'str', - 'hearted': 'bool', - 'hearts': 'list[GoalResponseLikes]', - 'is_rendered_as_separator': 'bool', - 'liked': 'bool', - 'likes': 'list[GoalResponseLikes]', - 'memberships': 'list[TaskBaseMemberships]', - 'modified_at': 'datetime', - 'notes': 'str', - 'num_hearts': 'int', - 'num_likes': 'int', - 'num_subtasks': 'int', - 'start_at': 'datetime', - 'start_on': 'date', - 'actual_time_minutes': 'float', - 'assignee': 'str', - 'assignee_section': 'str', - 'custom_fields': 'dict(str, str)', - 'followers': 'list[str]', - 'parent': 'str', - 'projects': 'list[str]', - 'tags': 'list[str]', - 'workspace': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'created_by': 'created_by', - 'approval_status': 'approval_status', - 'assignee_status': 'assignee_status', - 'completed': 'completed', - 'completed_at': 'completed_at', - 'completed_by': 'completed_by', - 'created_at': 'created_at', - 'dependencies': 'dependencies', - 'dependents': 'dependents', - 'due_at': 'due_at', - 'due_on': 'due_on', - 'external': 'external', - 'html_notes': 'html_notes', - 'hearted': 'hearted', - 'hearts': 'hearts', - 'is_rendered_as_separator': 'is_rendered_as_separator', - 'liked': 'liked', - 'likes': 'likes', - 'memberships': 'memberships', - 'modified_at': 'modified_at', - 'notes': 'notes', - 'num_hearts': 'num_hearts', - 'num_likes': 'num_likes', - 'num_subtasks': 'num_subtasks', - 'start_at': 'start_at', - 'start_on': 'start_on', - 'actual_time_minutes': 'actual_time_minutes', - 'assignee': 'assignee', - 'assignee_section': 'assignee_section', - 'custom_fields': 'custom_fields', - 'followers': 'followers', - 'parent': 'parent', - 'projects': 'projects', - 'tags': 'tags', - 'workspace': 'workspace' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, created_by=None, approval_status=None, assignee_status=None, completed=None, completed_at=None, completed_by=None, created_at=None, dependencies=None, dependents=None, due_at=None, due_on=None, external=None, html_notes=None, hearted=None, hearts=None, is_rendered_as_separator=None, liked=None, likes=None, memberships=None, modified_at=None, notes=None, num_hearts=None, num_likes=None, num_subtasks=None, start_at=None, start_on=None, actual_time_minutes=None, assignee=None, assignee_section=None, custom_fields=None, followers=None, parent=None, projects=None, tags=None, workspace=None): # noqa: E501 - """TaskRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._created_by = None - self._approval_status = None - self._assignee_status = None - self._completed = None - self._completed_at = None - self._completed_by = None - self._created_at = None - self._dependencies = None - self._dependents = None - self._due_at = None - self._due_on = None - self._external = None - self._html_notes = None - self._hearted = None - self._hearts = None - self._is_rendered_as_separator = None - self._liked = None - self._likes = None - self._memberships = None - self._modified_at = None - self._notes = None - self._num_hearts = None - self._num_likes = None - self._num_subtasks = None - self._start_at = None - self._start_on = None - self._actual_time_minutes = None - self._assignee = None - self._assignee_section = None - self._custom_fields = None - self._followers = None - self._parent = None - self._projects = None - self._tags = None - self._workspace = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if created_by is not None: - self.created_by = created_by - if approval_status is not None: - self.approval_status = approval_status - if assignee_status is not None: - self.assignee_status = assignee_status - if completed is not None: - self.completed = completed - if completed_at is not None: - self.completed_at = completed_at - if completed_by is not None: - self.completed_by = completed_by - if created_at is not None: - self.created_at = created_at - if dependencies is not None: - self.dependencies = dependencies - if dependents is not None: - self.dependents = dependents - if due_at is not None: - self.due_at = due_at - if due_on is not None: - self.due_on = due_on - if external is not None: - self.external = external - if html_notes is not None: - self.html_notes = html_notes - if hearted is not None: - self.hearted = hearted - if hearts is not None: - self.hearts = hearts - if is_rendered_as_separator is not None: - self.is_rendered_as_separator = is_rendered_as_separator - if liked is not None: - self.liked = liked - if likes is not None: - self.likes = likes - if memberships is not None: - self.memberships = memberships - if modified_at is not None: - self.modified_at = modified_at - if notes is not None: - self.notes = notes - if num_hearts is not None: - self.num_hearts = num_hearts - if num_likes is not None: - self.num_likes = num_likes - if num_subtasks is not None: - self.num_subtasks = num_subtasks - if start_at is not None: - self.start_at = start_at - if start_on is not None: - self.start_on = start_on - if actual_time_minutes is not None: - self.actual_time_minutes = actual_time_minutes - if assignee is not None: - self.assignee = assignee - if assignee_section is not None: - self.assignee_section = assignee_section - if custom_fields is not None: - self.custom_fields = custom_fields - if followers is not None: - self.followers = followers - if parent is not None: - self.parent = parent - if projects is not None: - self.projects = projects - if tags is not None: - self.tags = tags - if workspace is not None: - self.workspace = workspace - - @property - def gid(self): - """Gets the gid of this TaskRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskRequest. # noqa: E501 - - Name of the task. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this TaskRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskRequest. - - Name of the task. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this TaskRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this TaskRequest. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :return: The resource_subtype of this TaskRequest. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this TaskRequest. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :param resource_subtype: The resource_subtype of this TaskRequest. # noqa: E501 - :type: str - """ - allowed_values = ["default_task", "milestone", "section", "approval"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def created_by(self): - """Gets the created_by of this TaskRequest. # noqa: E501 - - - :return: The created_by of this TaskRequest. # noqa: E501 - :rtype: AttachmentResponseParentCreatedBy - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this TaskRequest. - - - :param created_by: The created_by of this TaskRequest. # noqa: E501 - :type: AttachmentResponseParentCreatedBy - """ - - self._created_by = created_by - - @property - def approval_status(self): - """Gets the approval_status of this TaskRequest. # noqa: E501 - - *Conditional* Reflects the approval status of this task. This field is kept in sync with `completed`, meaning `pending` translates to false while `approved`, `rejected`, and `changes_requested` translate to true. If you set completed to true, this field will be set to `approved`. # noqa: E501 - - :return: The approval_status of this TaskRequest. # noqa: E501 - :rtype: str - """ - return self._approval_status - - @approval_status.setter - def approval_status(self, approval_status): - """Sets the approval_status of this TaskRequest. - - *Conditional* Reflects the approval status of this task. This field is kept in sync with `completed`, meaning `pending` translates to false while `approved`, `rejected`, and `changes_requested` translate to true. If you set completed to true, this field will be set to `approved`. # noqa: E501 - - :param approval_status: The approval_status of this TaskRequest. # noqa: E501 - :type: str - """ - allowed_values = ["pending", "approved", "rejected", "changes_requested"] # noqa: E501 - if approval_status not in allowed_values: - raise ValueError( - "Invalid value for `approval_status` ({0}), must be one of {1}" # noqa: E501 - .format(approval_status, allowed_values) - ) - - self._approval_status = approval_status - - @property - def assignee_status(self): - """Gets the assignee_status of this TaskRequest. # noqa: E501 - - *Deprecated* Scheduling status of this task for the user it is assigned to. This field can only be set if the assignee is non-null. Setting this field to \"inbox\" or \"upcoming\" inserts it at the top of the section, while the other options will insert at the bottom. # noqa: E501 - - :return: The assignee_status of this TaskRequest. # noqa: E501 - :rtype: str - """ - return self._assignee_status - - @assignee_status.setter - def assignee_status(self, assignee_status): - """Sets the assignee_status of this TaskRequest. - - *Deprecated* Scheduling status of this task for the user it is assigned to. This field can only be set if the assignee is non-null. Setting this field to \"inbox\" or \"upcoming\" inserts it at the top of the section, while the other options will insert at the bottom. # noqa: E501 - - :param assignee_status: The assignee_status of this TaskRequest. # noqa: E501 - :type: str - """ - allowed_values = ["today", "upcoming", "later", "new", "inbox"] # noqa: E501 - if assignee_status not in allowed_values: - raise ValueError( - "Invalid value for `assignee_status` ({0}), must be one of {1}" # noqa: E501 - .format(assignee_status, allowed_values) - ) - - self._assignee_status = assignee_status - - @property - def completed(self): - """Gets the completed of this TaskRequest. # noqa: E501 - - True if the task is currently marked complete, false if not. # noqa: E501 - - :return: The completed of this TaskRequest. # noqa: E501 - :rtype: bool - """ - return self._completed - - @completed.setter - def completed(self, completed): - """Sets the completed of this TaskRequest. - - True if the task is currently marked complete, false if not. # noqa: E501 - - :param completed: The completed of this TaskRequest. # noqa: E501 - :type: bool - """ - - self._completed = completed - - @property - def completed_at(self): - """Gets the completed_at of this TaskRequest. # noqa: E501 - - The time at which this task was completed, or null if the task is incomplete. # noqa: E501 - - :return: The completed_at of this TaskRequest. # noqa: E501 - :rtype: datetime - """ - return self._completed_at - - @completed_at.setter - def completed_at(self, completed_at): - """Sets the completed_at of this TaskRequest. - - The time at which this task was completed, or null if the task is incomplete. # noqa: E501 - - :param completed_at: The completed_at of this TaskRequest. # noqa: E501 - :type: datetime - """ - - self._completed_at = completed_at - - @property - def completed_by(self): - """Gets the completed_by of this TaskRequest. # noqa: E501 - - - :return: The completed_by of this TaskRequest. # noqa: E501 - :rtype: TaskBaseCompletedBy - """ - return self._completed_by - - @completed_by.setter - def completed_by(self, completed_by): - """Sets the completed_by of this TaskRequest. - - - :param completed_by: The completed_by of this TaskRequest. # noqa: E501 - :type: TaskBaseCompletedBy - """ - - self._completed_by = completed_by - - @property - def created_at(self): - """Gets the created_at of this TaskRequest. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this TaskRequest. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this TaskRequest. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this TaskRequest. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def dependencies(self): - """Gets the dependencies of this TaskRequest. # noqa: E501 - - [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that this task depends on. The objects contain only the gid of the dependency. # noqa: E501 - - :return: The dependencies of this TaskRequest. # noqa: E501 - :rtype: list[TaskBaseDependencies] - """ - return self._dependencies - - @dependencies.setter - def dependencies(self, dependencies): - """Sets the dependencies of this TaskRequest. - - [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that this task depends on. The objects contain only the gid of the dependency. # noqa: E501 - - :param dependencies: The dependencies of this TaskRequest. # noqa: E501 - :type: list[TaskBaseDependencies] - """ - - self._dependencies = dependencies - - @property - def dependents(self): - """Gets the dependents of this TaskRequest. # noqa: E501 - - [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that depend on this task. The objects contain only the ID of the dependent. # noqa: E501 - - :return: The dependents of this TaskRequest. # noqa: E501 - :rtype: list[TaskBaseDependencies] - """ - return self._dependents - - @dependents.setter - def dependents(self, dependents): - """Sets the dependents of this TaskRequest. - - [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that depend on this task. The objects contain only the ID of the dependent. # noqa: E501 - - :param dependents: The dependents of this TaskRequest. # noqa: E501 - :type: list[TaskBaseDependencies] - """ - - self._dependents = dependents - - @property - def due_at(self): - """Gets the due_at of this TaskRequest. # noqa: E501 - - The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. # noqa: E501 - - :return: The due_at of this TaskRequest. # noqa: E501 - :rtype: datetime - """ - return self._due_at - - @due_at.setter - def due_at(self, due_at): - """Sets the due_at of this TaskRequest. - - The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. # noqa: E501 - - :param due_at: The due_at of this TaskRequest. # noqa: E501 - :type: datetime - """ - - self._due_at = due_at - - @property - def due_on(self): - """Gets the due_on of this TaskRequest. # noqa: E501 - - The localized date on which this task is due, or null if the task has no due date. This takes a date with `YYYY-MM-DD` format and should not be used together with `due_at`. # noqa: E501 - - :return: The due_on of this TaskRequest. # noqa: E501 - :rtype: date - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this TaskRequest. - - The localized date on which this task is due, or null if the task has no due date. This takes a date with `YYYY-MM-DD` format and should not be used together with `due_at`. # noqa: E501 - - :param due_on: The due_on of this TaskRequest. # noqa: E501 - :type: date - """ - - self._due_on = due_on - - @property - def external(self): - """Gets the external of this TaskRequest. # noqa: E501 - - - :return: The external of this TaskRequest. # noqa: E501 - :rtype: TaskBaseExternal - """ - return self._external - - @external.setter - def external(self, external): - """Sets the external of this TaskRequest. - - - :param external: The external of this TaskRequest. # noqa: E501 - :type: TaskBaseExternal - """ - - self._external = external - - @property - def html_notes(self): - """Gets the html_notes of this TaskRequest. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The notes of the text with formatting as HTML. # noqa: E501 - - :return: The html_notes of this TaskRequest. # noqa: E501 - :rtype: str - """ - return self._html_notes - - @html_notes.setter - def html_notes(self, html_notes): - """Sets the html_notes of this TaskRequest. - - [Opt In](/docs/inputoutput-options). The notes of the text with formatting as HTML. # noqa: E501 - - :param html_notes: The html_notes of this TaskRequest. # noqa: E501 - :type: str - """ - - self._html_notes = html_notes - - @property - def hearted(self): - """Gets the hearted of this TaskRequest. # noqa: E501 - - *Deprecated - please use liked instead* True if the task is hearted by the authorized user, false if not. # noqa: E501 - - :return: The hearted of this TaskRequest. # noqa: E501 - :rtype: bool - """ - return self._hearted - - @hearted.setter - def hearted(self, hearted): - """Sets the hearted of this TaskRequest. - - *Deprecated - please use liked instead* True if the task is hearted by the authorized user, false if not. # noqa: E501 - - :param hearted: The hearted of this TaskRequest. # noqa: E501 - :type: bool - """ - - self._hearted = hearted - - @property - def hearts(self): - """Gets the hearts of this TaskRequest. # noqa: E501 - - *Deprecated - please use likes instead* Array of likes for users who have hearted this task. # noqa: E501 - - :return: The hearts of this TaskRequest. # noqa: E501 - :rtype: list[GoalResponseLikes] - """ - return self._hearts - - @hearts.setter - def hearts(self, hearts): - """Sets the hearts of this TaskRequest. - - *Deprecated - please use likes instead* Array of likes for users who have hearted this task. # noqa: E501 - - :param hearts: The hearts of this TaskRequest. # noqa: E501 - :type: list[GoalResponseLikes] - """ - - self._hearts = hearts - - @property - def is_rendered_as_separator(self): - """Gets the is_rendered_as_separator of this TaskRequest. # noqa: E501 - - [Opt In](/docs/inputoutput-options). In some contexts tasks can be rendered as a visual separator; for instance, subtasks can appear similar to [sections](/reference/sections) without being true `section` objects. If a `task` object is rendered this way in any context it will have the property `is_rendered_as_separator` set to `true`. # noqa: E501 - - :return: The is_rendered_as_separator of this TaskRequest. # noqa: E501 - :rtype: bool - """ - return self._is_rendered_as_separator - - @is_rendered_as_separator.setter - def is_rendered_as_separator(self, is_rendered_as_separator): - """Sets the is_rendered_as_separator of this TaskRequest. - - [Opt In](/docs/inputoutput-options). In some contexts tasks can be rendered as a visual separator; for instance, subtasks can appear similar to [sections](/reference/sections) without being true `section` objects. If a `task` object is rendered this way in any context it will have the property `is_rendered_as_separator` set to `true`. # noqa: E501 - - :param is_rendered_as_separator: The is_rendered_as_separator of this TaskRequest. # noqa: E501 - :type: bool - """ - - self._is_rendered_as_separator = is_rendered_as_separator - - @property - def liked(self): - """Gets the liked of this TaskRequest. # noqa: E501 - - True if the task is liked by the authorized user, false if not. # noqa: E501 - - :return: The liked of this TaskRequest. # noqa: E501 - :rtype: bool - """ - return self._liked - - @liked.setter - def liked(self, liked): - """Sets the liked of this TaskRequest. - - True if the task is liked by the authorized user, false if not. # noqa: E501 - - :param liked: The liked of this TaskRequest. # noqa: E501 - :type: bool - """ - - self._liked = liked - - @property - def likes(self): - """Gets the likes of this TaskRequest. # noqa: E501 - - Array of likes for users who have liked this task. # noqa: E501 - - :return: The likes of this TaskRequest. # noqa: E501 - :rtype: list[GoalResponseLikes] - """ - return self._likes - - @likes.setter - def likes(self, likes): - """Sets the likes of this TaskRequest. - - Array of likes for users who have liked this task. # noqa: E501 - - :param likes: The likes of this TaskRequest. # noqa: E501 - :type: list[GoalResponseLikes] - """ - - self._likes = likes - - @property - def memberships(self): - """Gets the memberships of this TaskRequest. # noqa: E501 - - *Create-only*. Array of projects this task is associated with and the section it is in. At task creation time, this array can be used to add the task to specific sections. After task creation, these associations can be modified using the `addProject` and `removeProject` endpoints. Note that over time, more types of memberships may be added to this property. # noqa: E501 - - :return: The memberships of this TaskRequest. # noqa: E501 - :rtype: list[TaskBaseMemberships] - """ - return self._memberships - - @memberships.setter - def memberships(self, memberships): - """Sets the memberships of this TaskRequest. - - *Create-only*. Array of projects this task is associated with and the section it is in. At task creation time, this array can be used to add the task to specific sections. After task creation, these associations can be modified using the `addProject` and `removeProject` endpoints. Note that over time, more types of memberships may be added to this property. # noqa: E501 - - :param memberships: The memberships of this TaskRequest. # noqa: E501 - :type: list[TaskBaseMemberships] - """ - - self._memberships = memberships - - @property - def modified_at(self): - """Gets the modified_at of this TaskRequest. # noqa: E501 - - The time at which this task was last modified. The following conditions will change `modified_at`: - story is created on a task - story is trashed on a task - attachment is trashed on a task - task is assigned or unassigned - custom field value is changed - the task itself is trashed - Or if any of the following fields are updated: - completed - name - due_date - description - attachments - items - schedule_status The following conditions will _not_ change `modified_at`: - moving to a new container (project, portfolio, etc) - comments being added to the task (but the stories they generate _will_ affect `modified_at`) # noqa: E501 - - :return: The modified_at of this TaskRequest. # noqa: E501 - :rtype: datetime - """ - return self._modified_at - - @modified_at.setter - def modified_at(self, modified_at): - """Sets the modified_at of this TaskRequest. - - The time at which this task was last modified. The following conditions will change `modified_at`: - story is created on a task - story is trashed on a task - attachment is trashed on a task - task is assigned or unassigned - custom field value is changed - the task itself is trashed - Or if any of the following fields are updated: - completed - name - due_date - description - attachments - items - schedule_status The following conditions will _not_ change `modified_at`: - moving to a new container (project, portfolio, etc) - comments being added to the task (but the stories they generate _will_ affect `modified_at`) # noqa: E501 - - :param modified_at: The modified_at of this TaskRequest. # noqa: E501 - :type: datetime - """ - - self._modified_at = modified_at - - @property - def notes(self): - """Gets the notes of this TaskRequest. # noqa: E501 - - Free-form textual information associated with the task (i.e. its description). # noqa: E501 - - :return: The notes of this TaskRequest. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this TaskRequest. - - Free-form textual information associated with the task (i.e. its description). # noqa: E501 - - :param notes: The notes of this TaskRequest. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def num_hearts(self): - """Gets the num_hearts of this TaskRequest. # noqa: E501 - - *Deprecated - please use likes instead* The number of users who have hearted this task. # noqa: E501 - - :return: The num_hearts of this TaskRequest. # noqa: E501 - :rtype: int - """ - return self._num_hearts - - @num_hearts.setter - def num_hearts(self, num_hearts): - """Sets the num_hearts of this TaskRequest. - - *Deprecated - please use likes instead* The number of users who have hearted this task. # noqa: E501 - - :param num_hearts: The num_hearts of this TaskRequest. # noqa: E501 - :type: int - """ - - self._num_hearts = num_hearts - - @property - def num_likes(self): - """Gets the num_likes of this TaskRequest. # noqa: E501 - - The number of users who have liked this task. # noqa: E501 - - :return: The num_likes of this TaskRequest. # noqa: E501 - :rtype: int - """ - return self._num_likes - - @num_likes.setter - def num_likes(self, num_likes): - """Sets the num_likes of this TaskRequest. - - The number of users who have liked this task. # noqa: E501 - - :param num_likes: The num_likes of this TaskRequest. # noqa: E501 - :type: int - """ - - self._num_likes = num_likes - - @property - def num_subtasks(self): - """Gets the num_subtasks of this TaskRequest. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The number of subtasks on this task. # noqa: E501 - - :return: The num_subtasks of this TaskRequest. # noqa: E501 - :rtype: int - """ - return self._num_subtasks - - @num_subtasks.setter - def num_subtasks(self, num_subtasks): - """Sets the num_subtasks of this TaskRequest. - - [Opt In](/docs/inputoutput-options). The number of subtasks on this task. # noqa: E501 - - :param num_subtasks: The num_subtasks of this TaskRequest. # noqa: E501 - :type: int - """ - - self._num_subtasks = num_subtasks - - @property - def start_at(self): - """Gets the start_at of this TaskRequest. # noqa: E501 - - Date and time on which work begins for the task, or null if the task has no start time. This takes an ISO 8601 date string in UTC and should not be used together with `start_on`. *Note: `due_at` must be present in the request when setting or unsetting the `start_at` parameter.* # noqa: E501 - - :return: The start_at of this TaskRequest. # noqa: E501 - :rtype: datetime - """ - return self._start_at - - @start_at.setter - def start_at(self, start_at): - """Sets the start_at of this TaskRequest. - - Date and time on which work begins for the task, or null if the task has no start time. This takes an ISO 8601 date string in UTC and should not be used together with `start_on`. *Note: `due_at` must be present in the request when setting or unsetting the `start_at` parameter.* # noqa: E501 - - :param start_at: The start_at of this TaskRequest. # noqa: E501 - :type: datetime - """ - - self._start_at = start_at - - @property - def start_on(self): - """Gets the start_on of this TaskRequest. # noqa: E501 - - The day on which work begins for the task , or null if the task has no start date. This takes a date with `YYYY-MM-DD` format and should not be used together with `start_at`. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter.* # noqa: E501 - - :return: The start_on of this TaskRequest. # noqa: E501 - :rtype: date - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this TaskRequest. - - The day on which work begins for the task , or null if the task has no start date. This takes a date with `YYYY-MM-DD` format and should not be used together with `start_at`. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter.* # noqa: E501 - - :param start_on: The start_on of this TaskRequest. # noqa: E501 - :type: date - """ - - self._start_on = start_on - - @property - def actual_time_minutes(self): - """Gets the actual_time_minutes of this TaskRequest. # noqa: E501 - - This value represents the sum of all the Time Tracking entries in the Actual Time field on a given Task. It is represented as a nullable long value. # noqa: E501 - - :return: The actual_time_minutes of this TaskRequest. # noqa: E501 - :rtype: float - """ - return self._actual_time_minutes - - @actual_time_minutes.setter - def actual_time_minutes(self, actual_time_minutes): - """Sets the actual_time_minutes of this TaskRequest. - - This value represents the sum of all the Time Tracking entries in the Actual Time field on a given Task. It is represented as a nullable long value. # noqa: E501 - - :param actual_time_minutes: The actual_time_minutes of this TaskRequest. # noqa: E501 - :type: float - """ - - self._actual_time_minutes = actual_time_minutes - - @property - def assignee(self): - """Gets the assignee of this TaskRequest. # noqa: E501 - - Gid of a user. # noqa: E501 - - :return: The assignee of this TaskRequest. # noqa: E501 - :rtype: str - """ - return self._assignee - - @assignee.setter - def assignee(self, assignee): - """Sets the assignee of this TaskRequest. - - Gid of a user. # noqa: E501 - - :param assignee: The assignee of this TaskRequest. # noqa: E501 - :type: str - """ - - self._assignee = assignee - - @property - def assignee_section(self): - """Gets the assignee_section of this TaskRequest. # noqa: E501 - - The *assignee section* is a subdivision of a project that groups tasks together in the assignee's \"My Tasks\" list. It can either be a header above a list of tasks in a list view or a column in a board view of \"My Tasks.\" The `assignee_section` property will be returned in the response only if the request was sent by the user who is the assignee of the task. Note that you can only write to `assignee_section` with the gid of an existing section visible in the user's \"My Tasks\" list. # noqa: E501 - - :return: The assignee_section of this TaskRequest. # noqa: E501 - :rtype: str - """ - return self._assignee_section - - @assignee_section.setter - def assignee_section(self, assignee_section): - """Sets the assignee_section of this TaskRequest. - - The *assignee section* is a subdivision of a project that groups tasks together in the assignee's \"My Tasks\" list. It can either be a header above a list of tasks in a list view or a column in a board view of \"My Tasks.\" The `assignee_section` property will be returned in the response only if the request was sent by the user who is the assignee of the task. Note that you can only write to `assignee_section` with the gid of an existing section visible in the user's \"My Tasks\" list. # noqa: E501 - - :param assignee_section: The assignee_section of this TaskRequest. # noqa: E501 - :type: str - """ - - self._assignee_section = assignee_section - - @property - def custom_fields(self): - """Gets the custom_fields of this TaskRequest. # noqa: E501 - - An object where each key is the GID of a custom field and its corresponding value is either an enum GID, string, number, object, or array (depending on the custom field type). See the [custom fields guide](/docs/custom-fields-guide) for details on creating and updating custom field values. # noqa: E501 - - :return: The custom_fields of this TaskRequest. # noqa: E501 - :rtype: dict(str, str) - """ - return self._custom_fields - - @custom_fields.setter - def custom_fields(self, custom_fields): - """Sets the custom_fields of this TaskRequest. - - An object where each key is the GID of a custom field and its corresponding value is either an enum GID, string, number, object, or array (depending on the custom field type). See the [custom fields guide](/docs/custom-fields-guide) for details on creating and updating custom field values. # noqa: E501 - - :param custom_fields: The custom_fields of this TaskRequest. # noqa: E501 - :type: dict(str, str) - """ - - self._custom_fields = custom_fields - - @property - def followers(self): - """Gets the followers of this TaskRequest. # noqa: E501 - - *Create-Only* An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. In order to change followers on an existing task use `addFollowers` and `removeFollowers`. # noqa: E501 - - :return: The followers of this TaskRequest. # noqa: E501 - :rtype: list[str] - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this TaskRequest. - - *Create-Only* An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. In order to change followers on an existing task use `addFollowers` and `removeFollowers`. # noqa: E501 - - :param followers: The followers of this TaskRequest. # noqa: E501 - :type: list[str] - """ - - self._followers = followers - - @property - def parent(self): - """Gets the parent of this TaskRequest. # noqa: E501 - - Gid of a task. # noqa: E501 - - :return: The parent of this TaskRequest. # noqa: E501 - :rtype: str - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this TaskRequest. - - Gid of a task. # noqa: E501 - - :param parent: The parent of this TaskRequest. # noqa: E501 - :type: str - """ - - self._parent = parent - - @property - def projects(self): - """Gets the projects of this TaskRequest. # noqa: E501 - - *Create-Only* Array of project gids. In order to change projects on an existing task use `addProject` and `removeProject`. # noqa: E501 - - :return: The projects of this TaskRequest. # noqa: E501 - :rtype: list[str] - """ - return self._projects - - @projects.setter - def projects(self, projects): - """Sets the projects of this TaskRequest. - - *Create-Only* Array of project gids. In order to change projects on an existing task use `addProject` and `removeProject`. # noqa: E501 - - :param projects: The projects of this TaskRequest. # noqa: E501 - :type: list[str] - """ - - self._projects = projects - - @property - def tags(self): - """Gets the tags of this TaskRequest. # noqa: E501 - - *Create-Only* Array of tag gids. In order to change tags on an existing task use `addTag` and `removeTag`. # noqa: E501 - - :return: The tags of this TaskRequest. # noqa: E501 - :rtype: list[str] - """ - return self._tags - - @tags.setter - def tags(self, tags): - """Sets the tags of this TaskRequest. - - *Create-Only* Array of tag gids. In order to change tags on an existing task use `addTag` and `removeTag`. # noqa: E501 - - :param tags: The tags of this TaskRequest. # noqa: E501 - :type: list[str] - """ - - self._tags = tags - - @property - def workspace(self): - """Gets the workspace of this TaskRequest. # noqa: E501 - - Gid of a workspace. # noqa: E501 - - :return: The workspace of this TaskRequest. # noqa: E501 - :rtype: str - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this TaskRequest. - - Gid of a workspace. # noqa: E501 - - :param workspace: The workspace of this TaskRequest. # noqa: E501 - :type: str - """ - - self._workspace = workspace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_response.py b/asana/models/task_response.py deleted file mode 100644 index 7f9f6c9f..00000000 --- a/asana/models/task_response.py +++ /dev/null @@ -1,1208 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'created_by': 'AttachmentResponseParentCreatedBy', - 'approval_status': 'str', - 'assignee_status': 'str', - 'completed': 'bool', - 'completed_at': 'datetime', - 'completed_by': 'TaskBaseCompletedBy', - 'created_at': 'datetime', - 'dependencies': 'list[TaskBaseDependencies]', - 'dependents': 'list[TaskBaseDependencies]', - 'due_at': 'datetime', - 'due_on': 'date', - 'external': 'TaskBaseExternal', - 'html_notes': 'str', - 'hearted': 'bool', - 'hearts': 'list[GoalResponseLikes]', - 'is_rendered_as_separator': 'bool', - 'liked': 'bool', - 'likes': 'list[GoalResponseLikes]', - 'memberships': 'list[TaskBaseMemberships]', - 'modified_at': 'datetime', - 'notes': 'str', - 'num_hearts': 'int', - 'num_likes': 'int', - 'num_subtasks': 'int', - 'start_at': 'datetime', - 'start_on': 'date', - 'actual_time_minutes': 'float', - 'assignee': 'CustomFieldResponseCreatedBy', - 'assignee_section': 'TaskResponseAssigneeSection', - 'custom_fields': 'list[TaskResponseCustomFields]', - 'followers': 'list[CustomFieldResponsePeopleValue]', - 'parent': 'TaskResponseParent', - 'projects': 'list[JobBaseNewProject]', - 'tags': 'list[TaskResponseTags]', - 'workspace': 'TaskResponseWorkspace', - 'permalink_url': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'created_by': 'created_by', - 'approval_status': 'approval_status', - 'assignee_status': 'assignee_status', - 'completed': 'completed', - 'completed_at': 'completed_at', - 'completed_by': 'completed_by', - 'created_at': 'created_at', - 'dependencies': 'dependencies', - 'dependents': 'dependents', - 'due_at': 'due_at', - 'due_on': 'due_on', - 'external': 'external', - 'html_notes': 'html_notes', - 'hearted': 'hearted', - 'hearts': 'hearts', - 'is_rendered_as_separator': 'is_rendered_as_separator', - 'liked': 'liked', - 'likes': 'likes', - 'memberships': 'memberships', - 'modified_at': 'modified_at', - 'notes': 'notes', - 'num_hearts': 'num_hearts', - 'num_likes': 'num_likes', - 'num_subtasks': 'num_subtasks', - 'start_at': 'start_at', - 'start_on': 'start_on', - 'actual_time_minutes': 'actual_time_minutes', - 'assignee': 'assignee', - 'assignee_section': 'assignee_section', - 'custom_fields': 'custom_fields', - 'followers': 'followers', - 'parent': 'parent', - 'projects': 'projects', - 'tags': 'tags', - 'workspace': 'workspace', - 'permalink_url': 'permalink_url' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, created_by=None, approval_status=None, assignee_status=None, completed=None, completed_at=None, completed_by=None, created_at=None, dependencies=None, dependents=None, due_at=None, due_on=None, external=None, html_notes=None, hearted=None, hearts=None, is_rendered_as_separator=None, liked=None, likes=None, memberships=None, modified_at=None, notes=None, num_hearts=None, num_likes=None, num_subtasks=None, start_at=None, start_on=None, actual_time_minutes=None, assignee=None, assignee_section=None, custom_fields=None, followers=None, parent=None, projects=None, tags=None, workspace=None, permalink_url=None): # noqa: E501 - """TaskResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._created_by = None - self._approval_status = None - self._assignee_status = None - self._completed = None - self._completed_at = None - self._completed_by = None - self._created_at = None - self._dependencies = None - self._dependents = None - self._due_at = None - self._due_on = None - self._external = None - self._html_notes = None - self._hearted = None - self._hearts = None - self._is_rendered_as_separator = None - self._liked = None - self._likes = None - self._memberships = None - self._modified_at = None - self._notes = None - self._num_hearts = None - self._num_likes = None - self._num_subtasks = None - self._start_at = None - self._start_on = None - self._actual_time_minutes = None - self._assignee = None - self._assignee_section = None - self._custom_fields = None - self._followers = None - self._parent = None - self._projects = None - self._tags = None - self._workspace = None - self._permalink_url = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if created_by is not None: - self.created_by = created_by - if approval_status is not None: - self.approval_status = approval_status - if assignee_status is not None: - self.assignee_status = assignee_status - if completed is not None: - self.completed = completed - if completed_at is not None: - self.completed_at = completed_at - if completed_by is not None: - self.completed_by = completed_by - if created_at is not None: - self.created_at = created_at - if dependencies is not None: - self.dependencies = dependencies - if dependents is not None: - self.dependents = dependents - if due_at is not None: - self.due_at = due_at - if due_on is not None: - self.due_on = due_on - if external is not None: - self.external = external - if html_notes is not None: - self.html_notes = html_notes - if hearted is not None: - self.hearted = hearted - if hearts is not None: - self.hearts = hearts - if is_rendered_as_separator is not None: - self.is_rendered_as_separator = is_rendered_as_separator - if liked is not None: - self.liked = liked - if likes is not None: - self.likes = likes - if memberships is not None: - self.memberships = memberships - if modified_at is not None: - self.modified_at = modified_at - if notes is not None: - self.notes = notes - if num_hearts is not None: - self.num_hearts = num_hearts - if num_likes is not None: - self.num_likes = num_likes - if num_subtasks is not None: - self.num_subtasks = num_subtasks - if start_at is not None: - self.start_at = start_at - if start_on is not None: - self.start_on = start_on - if actual_time_minutes is not None: - self.actual_time_minutes = actual_time_minutes - if assignee is not None: - self.assignee = assignee - if assignee_section is not None: - self.assignee_section = assignee_section - if custom_fields is not None: - self.custom_fields = custom_fields - if followers is not None: - self.followers = followers - if parent is not None: - self.parent = parent - if projects is not None: - self.projects = projects - if tags is not None: - self.tags = tags - if workspace is not None: - self.workspace = workspace - if permalink_url is not None: - self.permalink_url = permalink_url - - @property - def gid(self): - """Gets the gid of this TaskResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskResponse. # noqa: E501 - - Name of the task. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this TaskResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskResponse. - - Name of the task. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this TaskResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this TaskResponse. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :return: The resource_subtype of this TaskResponse. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this TaskResponse. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :param resource_subtype: The resource_subtype of this TaskResponse. # noqa: E501 - :type: str - """ - allowed_values = ["default_task", "milestone", "section", "approval"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def created_by(self): - """Gets the created_by of this TaskResponse. # noqa: E501 - - - :return: The created_by of this TaskResponse. # noqa: E501 - :rtype: AttachmentResponseParentCreatedBy - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this TaskResponse. - - - :param created_by: The created_by of this TaskResponse. # noqa: E501 - :type: AttachmentResponseParentCreatedBy - """ - - self._created_by = created_by - - @property - def approval_status(self): - """Gets the approval_status of this TaskResponse. # noqa: E501 - - *Conditional* Reflects the approval status of this task. This field is kept in sync with `completed`, meaning `pending` translates to false while `approved`, `rejected`, and `changes_requested` translate to true. If you set completed to true, this field will be set to `approved`. # noqa: E501 - - :return: The approval_status of this TaskResponse. # noqa: E501 - :rtype: str - """ - return self._approval_status - - @approval_status.setter - def approval_status(self, approval_status): - """Sets the approval_status of this TaskResponse. - - *Conditional* Reflects the approval status of this task. This field is kept in sync with `completed`, meaning `pending` translates to false while `approved`, `rejected`, and `changes_requested` translate to true. If you set completed to true, this field will be set to `approved`. # noqa: E501 - - :param approval_status: The approval_status of this TaskResponse. # noqa: E501 - :type: str - """ - allowed_values = ["pending", "approved", "rejected", "changes_requested"] # noqa: E501 - if approval_status not in allowed_values: - raise ValueError( - "Invalid value for `approval_status` ({0}), must be one of {1}" # noqa: E501 - .format(approval_status, allowed_values) - ) - - self._approval_status = approval_status - - @property - def assignee_status(self): - """Gets the assignee_status of this TaskResponse. # noqa: E501 - - *Deprecated* Scheduling status of this task for the user it is assigned to. This field can only be set if the assignee is non-null. Setting this field to \"inbox\" or \"upcoming\" inserts it at the top of the section, while the other options will insert at the bottom. # noqa: E501 - - :return: The assignee_status of this TaskResponse. # noqa: E501 - :rtype: str - """ - return self._assignee_status - - @assignee_status.setter - def assignee_status(self, assignee_status): - """Sets the assignee_status of this TaskResponse. - - *Deprecated* Scheduling status of this task for the user it is assigned to. This field can only be set if the assignee is non-null. Setting this field to \"inbox\" or \"upcoming\" inserts it at the top of the section, while the other options will insert at the bottom. # noqa: E501 - - :param assignee_status: The assignee_status of this TaskResponse. # noqa: E501 - :type: str - """ - allowed_values = ["today", "upcoming", "later", "new", "inbox"] # noqa: E501 - if assignee_status not in allowed_values: - raise ValueError( - "Invalid value for `assignee_status` ({0}), must be one of {1}" # noqa: E501 - .format(assignee_status, allowed_values) - ) - - self._assignee_status = assignee_status - - @property - def completed(self): - """Gets the completed of this TaskResponse. # noqa: E501 - - True if the task is currently marked complete, false if not. # noqa: E501 - - :return: The completed of this TaskResponse. # noqa: E501 - :rtype: bool - """ - return self._completed - - @completed.setter - def completed(self, completed): - """Sets the completed of this TaskResponse. - - True if the task is currently marked complete, false if not. # noqa: E501 - - :param completed: The completed of this TaskResponse. # noqa: E501 - :type: bool - """ - - self._completed = completed - - @property - def completed_at(self): - """Gets the completed_at of this TaskResponse. # noqa: E501 - - The time at which this task was completed, or null if the task is incomplete. # noqa: E501 - - :return: The completed_at of this TaskResponse. # noqa: E501 - :rtype: datetime - """ - return self._completed_at - - @completed_at.setter - def completed_at(self, completed_at): - """Sets the completed_at of this TaskResponse. - - The time at which this task was completed, or null if the task is incomplete. # noqa: E501 - - :param completed_at: The completed_at of this TaskResponse. # noqa: E501 - :type: datetime - """ - - self._completed_at = completed_at - - @property - def completed_by(self): - """Gets the completed_by of this TaskResponse. # noqa: E501 - - - :return: The completed_by of this TaskResponse. # noqa: E501 - :rtype: TaskBaseCompletedBy - """ - return self._completed_by - - @completed_by.setter - def completed_by(self, completed_by): - """Sets the completed_by of this TaskResponse. - - - :param completed_by: The completed_by of this TaskResponse. # noqa: E501 - :type: TaskBaseCompletedBy - """ - - self._completed_by = completed_by - - @property - def created_at(self): - """Gets the created_at of this TaskResponse. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this TaskResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this TaskResponse. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this TaskResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def dependencies(self): - """Gets the dependencies of this TaskResponse. # noqa: E501 - - [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that this task depends on. The objects contain only the gid of the dependency. # noqa: E501 - - :return: The dependencies of this TaskResponse. # noqa: E501 - :rtype: list[TaskBaseDependencies] - """ - return self._dependencies - - @dependencies.setter - def dependencies(self, dependencies): - """Sets the dependencies of this TaskResponse. - - [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that this task depends on. The objects contain only the gid of the dependency. # noqa: E501 - - :param dependencies: The dependencies of this TaskResponse. # noqa: E501 - :type: list[TaskBaseDependencies] - """ - - self._dependencies = dependencies - - @property - def dependents(self): - """Gets the dependents of this TaskResponse. # noqa: E501 - - [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that depend on this task. The objects contain only the ID of the dependent. # noqa: E501 - - :return: The dependents of this TaskResponse. # noqa: E501 - :rtype: list[TaskBaseDependencies] - """ - return self._dependents - - @dependents.setter - def dependents(self, dependents): - """Sets the dependents of this TaskResponse. - - [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that depend on this task. The objects contain only the ID of the dependent. # noqa: E501 - - :param dependents: The dependents of this TaskResponse. # noqa: E501 - :type: list[TaskBaseDependencies] - """ - - self._dependents = dependents - - @property - def due_at(self): - """Gets the due_at of this TaskResponse. # noqa: E501 - - The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. # noqa: E501 - - :return: The due_at of this TaskResponse. # noqa: E501 - :rtype: datetime - """ - return self._due_at - - @due_at.setter - def due_at(self, due_at): - """Sets the due_at of this TaskResponse. - - The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. # noqa: E501 - - :param due_at: The due_at of this TaskResponse. # noqa: E501 - :type: datetime - """ - - self._due_at = due_at - - @property - def due_on(self): - """Gets the due_on of this TaskResponse. # noqa: E501 - - The localized date on which this task is due, or null if the task has no due date. This takes a date with `YYYY-MM-DD` format and should not be used together with `due_at`. # noqa: E501 - - :return: The due_on of this TaskResponse. # noqa: E501 - :rtype: date - """ - return self._due_on - - @due_on.setter - def due_on(self, due_on): - """Sets the due_on of this TaskResponse. - - The localized date on which this task is due, or null if the task has no due date. This takes a date with `YYYY-MM-DD` format and should not be used together with `due_at`. # noqa: E501 - - :param due_on: The due_on of this TaskResponse. # noqa: E501 - :type: date - """ - - self._due_on = due_on - - @property - def external(self): - """Gets the external of this TaskResponse. # noqa: E501 - - - :return: The external of this TaskResponse. # noqa: E501 - :rtype: TaskBaseExternal - """ - return self._external - - @external.setter - def external(self, external): - """Sets the external of this TaskResponse. - - - :param external: The external of this TaskResponse. # noqa: E501 - :type: TaskBaseExternal - """ - - self._external = external - - @property - def html_notes(self): - """Gets the html_notes of this TaskResponse. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The notes of the text with formatting as HTML. # noqa: E501 - - :return: The html_notes of this TaskResponse. # noqa: E501 - :rtype: str - """ - return self._html_notes - - @html_notes.setter - def html_notes(self, html_notes): - """Sets the html_notes of this TaskResponse. - - [Opt In](/docs/inputoutput-options). The notes of the text with formatting as HTML. # noqa: E501 - - :param html_notes: The html_notes of this TaskResponse. # noqa: E501 - :type: str - """ - - self._html_notes = html_notes - - @property - def hearted(self): - """Gets the hearted of this TaskResponse. # noqa: E501 - - *Deprecated - please use liked instead* True if the task is hearted by the authorized user, false if not. # noqa: E501 - - :return: The hearted of this TaskResponse. # noqa: E501 - :rtype: bool - """ - return self._hearted - - @hearted.setter - def hearted(self, hearted): - """Sets the hearted of this TaskResponse. - - *Deprecated - please use liked instead* True if the task is hearted by the authorized user, false if not. # noqa: E501 - - :param hearted: The hearted of this TaskResponse. # noqa: E501 - :type: bool - """ - - self._hearted = hearted - - @property - def hearts(self): - """Gets the hearts of this TaskResponse. # noqa: E501 - - *Deprecated - please use likes instead* Array of likes for users who have hearted this task. # noqa: E501 - - :return: The hearts of this TaskResponse. # noqa: E501 - :rtype: list[GoalResponseLikes] - """ - return self._hearts - - @hearts.setter - def hearts(self, hearts): - """Sets the hearts of this TaskResponse. - - *Deprecated - please use likes instead* Array of likes for users who have hearted this task. # noqa: E501 - - :param hearts: The hearts of this TaskResponse. # noqa: E501 - :type: list[GoalResponseLikes] - """ - - self._hearts = hearts - - @property - def is_rendered_as_separator(self): - """Gets the is_rendered_as_separator of this TaskResponse. # noqa: E501 - - [Opt In](/docs/inputoutput-options). In some contexts tasks can be rendered as a visual separator; for instance, subtasks can appear similar to [sections](/reference/sections) without being true `section` objects. If a `task` object is rendered this way in any context it will have the property `is_rendered_as_separator` set to `true`. # noqa: E501 - - :return: The is_rendered_as_separator of this TaskResponse. # noqa: E501 - :rtype: bool - """ - return self._is_rendered_as_separator - - @is_rendered_as_separator.setter - def is_rendered_as_separator(self, is_rendered_as_separator): - """Sets the is_rendered_as_separator of this TaskResponse. - - [Opt In](/docs/inputoutput-options). In some contexts tasks can be rendered as a visual separator; for instance, subtasks can appear similar to [sections](/reference/sections) without being true `section` objects. If a `task` object is rendered this way in any context it will have the property `is_rendered_as_separator` set to `true`. # noqa: E501 - - :param is_rendered_as_separator: The is_rendered_as_separator of this TaskResponse. # noqa: E501 - :type: bool - """ - - self._is_rendered_as_separator = is_rendered_as_separator - - @property - def liked(self): - """Gets the liked of this TaskResponse. # noqa: E501 - - True if the task is liked by the authorized user, false if not. # noqa: E501 - - :return: The liked of this TaskResponse. # noqa: E501 - :rtype: bool - """ - return self._liked - - @liked.setter - def liked(self, liked): - """Sets the liked of this TaskResponse. - - True if the task is liked by the authorized user, false if not. # noqa: E501 - - :param liked: The liked of this TaskResponse. # noqa: E501 - :type: bool - """ - - self._liked = liked - - @property - def likes(self): - """Gets the likes of this TaskResponse. # noqa: E501 - - Array of likes for users who have liked this task. # noqa: E501 - - :return: The likes of this TaskResponse. # noqa: E501 - :rtype: list[GoalResponseLikes] - """ - return self._likes - - @likes.setter - def likes(self, likes): - """Sets the likes of this TaskResponse. - - Array of likes for users who have liked this task. # noqa: E501 - - :param likes: The likes of this TaskResponse. # noqa: E501 - :type: list[GoalResponseLikes] - """ - - self._likes = likes - - @property - def memberships(self): - """Gets the memberships of this TaskResponse. # noqa: E501 - - *Create-only*. Array of projects this task is associated with and the section it is in. At task creation time, this array can be used to add the task to specific sections. After task creation, these associations can be modified using the `addProject` and `removeProject` endpoints. Note that over time, more types of memberships may be added to this property. # noqa: E501 - - :return: The memberships of this TaskResponse. # noqa: E501 - :rtype: list[TaskBaseMemberships] - """ - return self._memberships - - @memberships.setter - def memberships(self, memberships): - """Sets the memberships of this TaskResponse. - - *Create-only*. Array of projects this task is associated with and the section it is in. At task creation time, this array can be used to add the task to specific sections. After task creation, these associations can be modified using the `addProject` and `removeProject` endpoints. Note that over time, more types of memberships may be added to this property. # noqa: E501 - - :param memberships: The memberships of this TaskResponse. # noqa: E501 - :type: list[TaskBaseMemberships] - """ - - self._memberships = memberships - - @property - def modified_at(self): - """Gets the modified_at of this TaskResponse. # noqa: E501 - - The time at which this task was last modified. The following conditions will change `modified_at`: - story is created on a task - story is trashed on a task - attachment is trashed on a task - task is assigned or unassigned - custom field value is changed - the task itself is trashed - Or if any of the following fields are updated: - completed - name - due_date - description - attachments - items - schedule_status The following conditions will _not_ change `modified_at`: - moving to a new container (project, portfolio, etc) - comments being added to the task (but the stories they generate _will_ affect `modified_at`) # noqa: E501 - - :return: The modified_at of this TaskResponse. # noqa: E501 - :rtype: datetime - """ - return self._modified_at - - @modified_at.setter - def modified_at(self, modified_at): - """Sets the modified_at of this TaskResponse. - - The time at which this task was last modified. The following conditions will change `modified_at`: - story is created on a task - story is trashed on a task - attachment is trashed on a task - task is assigned or unassigned - custom field value is changed - the task itself is trashed - Or if any of the following fields are updated: - completed - name - due_date - description - attachments - items - schedule_status The following conditions will _not_ change `modified_at`: - moving to a new container (project, portfolio, etc) - comments being added to the task (but the stories they generate _will_ affect `modified_at`) # noqa: E501 - - :param modified_at: The modified_at of this TaskResponse. # noqa: E501 - :type: datetime - """ - - self._modified_at = modified_at - - @property - def notes(self): - """Gets the notes of this TaskResponse. # noqa: E501 - - Free-form textual information associated with the task (i.e. its description). # noqa: E501 - - :return: The notes of this TaskResponse. # noqa: E501 - :rtype: str - """ - return self._notes - - @notes.setter - def notes(self, notes): - """Sets the notes of this TaskResponse. - - Free-form textual information associated with the task (i.e. its description). # noqa: E501 - - :param notes: The notes of this TaskResponse. # noqa: E501 - :type: str - """ - - self._notes = notes - - @property - def num_hearts(self): - """Gets the num_hearts of this TaskResponse. # noqa: E501 - - *Deprecated - please use likes instead* The number of users who have hearted this task. # noqa: E501 - - :return: The num_hearts of this TaskResponse. # noqa: E501 - :rtype: int - """ - return self._num_hearts - - @num_hearts.setter - def num_hearts(self, num_hearts): - """Sets the num_hearts of this TaskResponse. - - *Deprecated - please use likes instead* The number of users who have hearted this task. # noqa: E501 - - :param num_hearts: The num_hearts of this TaskResponse. # noqa: E501 - :type: int - """ - - self._num_hearts = num_hearts - - @property - def num_likes(self): - """Gets the num_likes of this TaskResponse. # noqa: E501 - - The number of users who have liked this task. # noqa: E501 - - :return: The num_likes of this TaskResponse. # noqa: E501 - :rtype: int - """ - return self._num_likes - - @num_likes.setter - def num_likes(self, num_likes): - """Sets the num_likes of this TaskResponse. - - The number of users who have liked this task. # noqa: E501 - - :param num_likes: The num_likes of this TaskResponse. # noqa: E501 - :type: int - """ - - self._num_likes = num_likes - - @property - def num_subtasks(self): - """Gets the num_subtasks of this TaskResponse. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The number of subtasks on this task. # noqa: E501 - - :return: The num_subtasks of this TaskResponse. # noqa: E501 - :rtype: int - """ - return self._num_subtasks - - @num_subtasks.setter - def num_subtasks(self, num_subtasks): - """Sets the num_subtasks of this TaskResponse. - - [Opt In](/docs/inputoutput-options). The number of subtasks on this task. # noqa: E501 - - :param num_subtasks: The num_subtasks of this TaskResponse. # noqa: E501 - :type: int - """ - - self._num_subtasks = num_subtasks - - @property - def start_at(self): - """Gets the start_at of this TaskResponse. # noqa: E501 - - Date and time on which work begins for the task, or null if the task has no start time. This takes an ISO 8601 date string in UTC and should not be used together with `start_on`. *Note: `due_at` must be present in the request when setting or unsetting the `start_at` parameter.* # noqa: E501 - - :return: The start_at of this TaskResponse. # noqa: E501 - :rtype: datetime - """ - return self._start_at - - @start_at.setter - def start_at(self, start_at): - """Sets the start_at of this TaskResponse. - - Date and time on which work begins for the task, or null if the task has no start time. This takes an ISO 8601 date string in UTC and should not be used together with `start_on`. *Note: `due_at` must be present in the request when setting or unsetting the `start_at` parameter.* # noqa: E501 - - :param start_at: The start_at of this TaskResponse. # noqa: E501 - :type: datetime - """ - - self._start_at = start_at - - @property - def start_on(self): - """Gets the start_on of this TaskResponse. # noqa: E501 - - The day on which work begins for the task , or null if the task has no start date. This takes a date with `YYYY-MM-DD` format and should not be used together with `start_at`. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter.* # noqa: E501 - - :return: The start_on of this TaskResponse. # noqa: E501 - :rtype: date - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this TaskResponse. - - The day on which work begins for the task , or null if the task has no start date. This takes a date with `YYYY-MM-DD` format and should not be used together with `start_at`. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter.* # noqa: E501 - - :param start_on: The start_on of this TaskResponse. # noqa: E501 - :type: date - """ - - self._start_on = start_on - - @property - def actual_time_minutes(self): - """Gets the actual_time_minutes of this TaskResponse. # noqa: E501 - - This value represents the sum of all the Time Tracking entries in the Actual Time field on a given Task. It is represented as a nullable long value. # noqa: E501 - - :return: The actual_time_minutes of this TaskResponse. # noqa: E501 - :rtype: float - """ - return self._actual_time_minutes - - @actual_time_minutes.setter - def actual_time_minutes(self, actual_time_minutes): - """Sets the actual_time_minutes of this TaskResponse. - - This value represents the sum of all the Time Tracking entries in the Actual Time field on a given Task. It is represented as a nullable long value. # noqa: E501 - - :param actual_time_minutes: The actual_time_minutes of this TaskResponse. # noqa: E501 - :type: float - """ - - self._actual_time_minutes = actual_time_minutes - - @property - def assignee(self): - """Gets the assignee of this TaskResponse. # noqa: E501 - - - :return: The assignee of this TaskResponse. # noqa: E501 - :rtype: CustomFieldResponseCreatedBy - """ - return self._assignee - - @assignee.setter - def assignee(self, assignee): - """Sets the assignee of this TaskResponse. - - - :param assignee: The assignee of this TaskResponse. # noqa: E501 - :type: CustomFieldResponseCreatedBy - """ - - self._assignee = assignee - - @property - def assignee_section(self): - """Gets the assignee_section of this TaskResponse. # noqa: E501 - - - :return: The assignee_section of this TaskResponse. # noqa: E501 - :rtype: TaskResponseAssigneeSection - """ - return self._assignee_section - - @assignee_section.setter - def assignee_section(self, assignee_section): - """Sets the assignee_section of this TaskResponse. - - - :param assignee_section: The assignee_section of this TaskResponse. # noqa: E501 - :type: TaskResponseAssigneeSection - """ - - self._assignee_section = assignee_section - - @property - def custom_fields(self): - """Gets the custom_fields of this TaskResponse. # noqa: E501 - - Array of custom field values applied to the task. These represent the custom field values recorded on this project for a particular custom field. For example, these custom field values will contain an `enum_value` property for custom fields of type `enum`, a `text_value` property for custom fields of type `text`, and so on. Please note that the `gid` returned on each custom field value *is identical* to the `gid` of the custom field, which allows referencing the custom field metadata through the `/custom_fields/custom_field-gid` endpoint. # noqa: E501 - - :return: The custom_fields of this TaskResponse. # noqa: E501 - :rtype: list[TaskResponseCustomFields] - """ - return self._custom_fields - - @custom_fields.setter - def custom_fields(self, custom_fields): - """Sets the custom_fields of this TaskResponse. - - Array of custom field values applied to the task. These represent the custom field values recorded on this project for a particular custom field. For example, these custom field values will contain an `enum_value` property for custom fields of type `enum`, a `text_value` property for custom fields of type `text`, and so on. Please note that the `gid` returned on each custom field value *is identical* to the `gid` of the custom field, which allows referencing the custom field metadata through the `/custom_fields/custom_field-gid` endpoint. # noqa: E501 - - :param custom_fields: The custom_fields of this TaskResponse. # noqa: E501 - :type: list[TaskResponseCustomFields] - """ - - self._custom_fields = custom_fields - - @property - def followers(self): - """Gets the followers of this TaskResponse. # noqa: E501 - - Array of users following this task. # noqa: E501 - - :return: The followers of this TaskResponse. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this TaskResponse. - - Array of users following this task. # noqa: E501 - - :param followers: The followers of this TaskResponse. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._followers = followers - - @property - def parent(self): - """Gets the parent of this TaskResponse. # noqa: E501 - - - :return: The parent of this TaskResponse. # noqa: E501 - :rtype: TaskResponseParent - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this TaskResponse. - - - :param parent: The parent of this TaskResponse. # noqa: E501 - :type: TaskResponseParent - """ - - self._parent = parent - - @property - def projects(self): - """Gets the projects of this TaskResponse. # noqa: E501 - - *Create-only.* Array of projects this task is associated with. At task creation time, this array can be used to add the task to many projects at once. After task creation, these associations can be modified using the addProject and removeProject endpoints. # noqa: E501 - - :return: The projects of this TaskResponse. # noqa: E501 - :rtype: list[JobBaseNewProject] - """ - return self._projects - - @projects.setter - def projects(self, projects): - """Sets the projects of this TaskResponse. - - *Create-only.* Array of projects this task is associated with. At task creation time, this array can be used to add the task to many projects at once. After task creation, these associations can be modified using the addProject and removeProject endpoints. # noqa: E501 - - :param projects: The projects of this TaskResponse. # noqa: E501 - :type: list[JobBaseNewProject] - """ - - self._projects = projects - - @property - def tags(self): - """Gets the tags of this TaskResponse. # noqa: E501 - - Array of tags associated with this task. In order to change tags on an existing task use `addTag` and `removeTag`. # noqa: E501 - - :return: The tags of this TaskResponse. # noqa: E501 - :rtype: list[TaskResponseTags] - """ - return self._tags - - @tags.setter - def tags(self, tags): - """Sets the tags of this TaskResponse. - - Array of tags associated with this task. In order to change tags on an existing task use `addTag` and `removeTag`. # noqa: E501 - - :param tags: The tags of this TaskResponse. # noqa: E501 - :type: list[TaskResponseTags] - """ - - self._tags = tags - - @property - def workspace(self): - """Gets the workspace of this TaskResponse. # noqa: E501 - - - :return: The workspace of this TaskResponse. # noqa: E501 - :rtype: TaskResponseWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this TaskResponse. - - - :param workspace: The workspace of this TaskResponse. # noqa: E501 - :type: TaskResponseWorkspace - """ - - self._workspace = workspace - - @property - def permalink_url(self): - """Gets the permalink_url of this TaskResponse. # noqa: E501 - - A url that points directly to the object within Asana. # noqa: E501 - - :return: The permalink_url of this TaskResponse. # noqa: E501 - :rtype: str - """ - return self._permalink_url - - @permalink_url.setter - def permalink_url(self, permalink_url): - """Sets the permalink_url of this TaskResponse. - - A url that points directly to the object within Asana. # noqa: E501 - - :param permalink_url: The permalink_url of this TaskResponse. # noqa: E501 - :type: str - """ - - self._permalink_url = permalink_url - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_response_array.py b/asana/models/task_response_array.py deleted file mode 100644 index 4b9d3723..00000000 --- a/asana/models/task_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[TaskResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """TaskResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this TaskResponseArray. # noqa: E501 - - - :return: The data of this TaskResponseArray. # noqa: E501 - :rtype: list[TaskResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskResponseArray. - - - :param data: The data of this TaskResponseArray. # noqa: E501 - :type: list[TaskResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this TaskResponseArray. # noqa: E501 - - - :return: The next_page of this TaskResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this TaskResponseArray. - - - :param next_page: The next_page of this TaskResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_response_assignee_section.py b/asana/models/task_response_assignee_section.py deleted file mode 100644 index e0069ea4..00000000 --- a/asana/models/task_response_assignee_section.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskResponseAssigneeSection(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """TaskResponseAssigneeSection - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this TaskResponseAssigneeSection. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskResponseAssigneeSection. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskResponseAssigneeSection. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskResponseAssigneeSection. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskResponseAssigneeSection. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskResponseAssigneeSection. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskResponseAssigneeSection. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskResponseAssigneeSection. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskResponseAssigneeSection. # noqa: E501 - - The name of the section (i.e. the text displayed as the section header). # noqa: E501 - - :return: The name of this TaskResponseAssigneeSection. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskResponseAssigneeSection. - - The name of the section (i.e. the text displayed as the section header). # noqa: E501 - - :param name: The name of this TaskResponseAssigneeSection. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskResponseAssigneeSection, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskResponseAssigneeSection): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_response_custom_fields.py b/asana/models/task_response_custom_fields.py deleted file mode 100644 index 94799bcb..00000000 --- a/asana/models/task_response_custom_fields.py +++ /dev/null @@ -1,836 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskResponseCustomFields(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'type': 'str', - 'enum_options': 'list[CustomFieldBaseEnumOptions]', - 'enabled': 'bool', - 'is_formula_field': 'bool', - 'date_value': 'CustomFieldBaseDateValue', - 'enum_value': 'CustomFieldBaseEnumValue', - 'multi_enum_values': 'list[CustomFieldBaseEnumOptions]', - 'number_value': 'float', - 'text_value': 'str', - 'display_value': 'str', - 'description': 'str', - 'precision': 'int', - 'format': 'str', - 'currency_code': 'str', - 'custom_label': 'str', - 'custom_label_position': 'str', - 'is_global_to_workspace': 'bool', - 'has_notifications_enabled': 'bool', - 'asana_created_field': 'str', - 'is_value_read_only': 'bool', - 'created_by': 'CustomFieldResponseCreatedBy', - 'people_value': 'list[CustomFieldResponsePeopleValue]' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'type': 'type', - 'enum_options': 'enum_options', - 'enabled': 'enabled', - 'is_formula_field': 'is_formula_field', - 'date_value': 'date_value', - 'enum_value': 'enum_value', - 'multi_enum_values': 'multi_enum_values', - 'number_value': 'number_value', - 'text_value': 'text_value', - 'display_value': 'display_value', - 'description': 'description', - 'precision': 'precision', - 'format': 'format', - 'currency_code': 'currency_code', - 'custom_label': 'custom_label', - 'custom_label_position': 'custom_label_position', - 'is_global_to_workspace': 'is_global_to_workspace', - 'has_notifications_enabled': 'has_notifications_enabled', - 'asana_created_field': 'asana_created_field', - 'is_value_read_only': 'is_value_read_only', - 'created_by': 'created_by', - 'people_value': 'people_value' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, type=None, enum_options=None, enabled=None, is_formula_field=None, date_value=None, enum_value=None, multi_enum_values=None, number_value=None, text_value=None, display_value=None, description=None, precision=None, format=None, currency_code=None, custom_label=None, custom_label_position=None, is_global_to_workspace=None, has_notifications_enabled=None, asana_created_field=None, is_value_read_only=None, created_by=None, people_value=None): # noqa: E501 - """TaskResponseCustomFields - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._type = None - self._enum_options = None - self._enabled = None - self._is_formula_field = None - self._date_value = None - self._enum_value = None - self._multi_enum_values = None - self._number_value = None - self._text_value = None - self._display_value = None - self._description = None - self._precision = None - self._format = None - self._currency_code = None - self._custom_label = None - self._custom_label_position = None - self._is_global_to_workspace = None - self._has_notifications_enabled = None - self._asana_created_field = None - self._is_value_read_only = None - self._created_by = None - self._people_value = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if type is not None: - self.type = type - if enum_options is not None: - self.enum_options = enum_options - if enabled is not None: - self.enabled = enabled - if is_formula_field is not None: - self.is_formula_field = is_formula_field - if date_value is not None: - self.date_value = date_value - if enum_value is not None: - self.enum_value = enum_value - if multi_enum_values is not None: - self.multi_enum_values = multi_enum_values - if number_value is not None: - self.number_value = number_value - if text_value is not None: - self.text_value = text_value - if display_value is not None: - self.display_value = display_value - if description is not None: - self.description = description - if precision is not None: - self.precision = precision - if format is not None: - self.format = format - if currency_code is not None: - self.currency_code = currency_code - if custom_label is not None: - self.custom_label = custom_label - if custom_label_position is not None: - self.custom_label_position = custom_label_position - if is_global_to_workspace is not None: - self.is_global_to_workspace = is_global_to_workspace - if has_notifications_enabled is not None: - self.has_notifications_enabled = has_notifications_enabled - if asana_created_field is not None: - self.asana_created_field = asana_created_field - if is_value_read_only is not None: - self.is_value_read_only = is_value_read_only - if created_by is not None: - self.created_by = created_by - if people_value is not None: - self.people_value = people_value - - @property - def gid(self): - """Gets the gid of this TaskResponseCustomFields. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskResponseCustomFields. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskResponseCustomFields. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskResponseCustomFields. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskResponseCustomFields. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskResponseCustomFields. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskResponseCustomFields. # noqa: E501 - - The name of the custom field. # noqa: E501 - - :return: The name of this TaskResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskResponseCustomFields. - - The name of the custom field. # noqa: E501 - - :param name: The name of this TaskResponseCustomFields. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this TaskResponseCustomFields. # noqa: E501 - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The resource_subtype of this TaskResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this TaskResponseCustomFields. - - The type of the custom field. Must be one of the given values. # noqa: E501 - - :param resource_subtype: The resource_subtype of this TaskResponseCustomFields. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def type(self): - """Gets the type of this TaskResponseCustomFields. # noqa: E501 - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :return: The type of this TaskResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._type - - @type.setter - def type(self, type): - """Sets the type of this TaskResponseCustomFields. - - *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. # noqa: E501 - - :param type: The type of this TaskResponseCustomFields. # noqa: E501 - :type: str - """ - allowed_values = ["text", "enum", "multi_enum", "number", "date", "people"] # noqa: E501 - if type not in allowed_values: - raise ValueError( - "Invalid value for `type` ({0}), must be one of {1}" # noqa: E501 - .format(type, allowed_values) - ) - - self._type = type - - @property - def enum_options(self): - """Gets the enum_options of this TaskResponseCustomFields. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :return: The enum_options of this TaskResponseCustomFields. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._enum_options - - @enum_options.setter - def enum_options(self, enum_options): - """Sets the enum_options of this TaskResponseCustomFields. - - *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). # noqa: E501 - - :param enum_options: The enum_options of this TaskResponseCustomFields. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._enum_options = enum_options - - @property - def enabled(self): - """Gets the enabled of this TaskResponseCustomFields. # noqa: E501 - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :return: The enabled of this TaskResponseCustomFields. # noqa: E501 - :rtype: bool - """ - return self._enabled - - @enabled.setter - def enabled(self, enabled): - """Sets the enabled of this TaskResponseCustomFields. - - *Conditional*. Determines if the custom field is enabled or not. # noqa: E501 - - :param enabled: The enabled of this TaskResponseCustomFields. # noqa: E501 - :type: bool - """ - - self._enabled = enabled - - @property - def is_formula_field(self): - """Gets the is_formula_field of this TaskResponseCustomFields. # noqa: E501 - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :return: The is_formula_field of this TaskResponseCustomFields. # noqa: E501 - :rtype: bool - """ - return self._is_formula_field - - @is_formula_field.setter - def is_formula_field(self, is_formula_field): - """Sets the is_formula_field of this TaskResponseCustomFields. - - *Conditional*. This flag describes whether a custom field is a formula custom field. # noqa: E501 - - :param is_formula_field: The is_formula_field of this TaskResponseCustomFields. # noqa: E501 - :type: bool - """ - - self._is_formula_field = is_formula_field - - @property - def date_value(self): - """Gets the date_value of this TaskResponseCustomFields. # noqa: E501 - - - :return: The date_value of this TaskResponseCustomFields. # noqa: E501 - :rtype: CustomFieldBaseDateValue - """ - return self._date_value - - @date_value.setter - def date_value(self, date_value): - """Sets the date_value of this TaskResponseCustomFields. - - - :param date_value: The date_value of this TaskResponseCustomFields. # noqa: E501 - :type: CustomFieldBaseDateValue - """ - - self._date_value = date_value - - @property - def enum_value(self): - """Gets the enum_value of this TaskResponseCustomFields. # noqa: E501 - - - :return: The enum_value of this TaskResponseCustomFields. # noqa: E501 - :rtype: CustomFieldBaseEnumValue - """ - return self._enum_value - - @enum_value.setter - def enum_value(self, enum_value): - """Sets the enum_value of this TaskResponseCustomFields. - - - :param enum_value: The enum_value of this TaskResponseCustomFields. # noqa: E501 - :type: CustomFieldBaseEnumValue - """ - - self._enum_value = enum_value - - @property - def multi_enum_values(self): - """Gets the multi_enum_values of this TaskResponseCustomFields. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :return: The multi_enum_values of this TaskResponseCustomFields. # noqa: E501 - :rtype: list[CustomFieldBaseEnumOptions] - """ - return self._multi_enum_values - - @multi_enum_values.setter - def multi_enum_values(self, multi_enum_values): - """Sets the multi_enum_values of this TaskResponseCustomFields. - - *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. # noqa: E501 - - :param multi_enum_values: The multi_enum_values of this TaskResponseCustomFields. # noqa: E501 - :type: list[CustomFieldBaseEnumOptions] - """ - - self._multi_enum_values = multi_enum_values - - @property - def number_value(self): - """Gets the number_value of this TaskResponseCustomFields. # noqa: E501 - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :return: The number_value of this TaskResponseCustomFields. # noqa: E501 - :rtype: float - """ - return self._number_value - - @number_value.setter - def number_value(self, number_value): - """Sets the number_value of this TaskResponseCustomFields. - - *Conditional*. This number is the value of a `number` custom field. # noqa: E501 - - :param number_value: The number_value of this TaskResponseCustomFields. # noqa: E501 - :type: float - """ - - self._number_value = number_value - - @property - def text_value(self): - """Gets the text_value of this TaskResponseCustomFields. # noqa: E501 - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :return: The text_value of this TaskResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._text_value - - @text_value.setter - def text_value(self, text_value): - """Sets the text_value of this TaskResponseCustomFields. - - *Conditional*. This string is the value of a `text` custom field. # noqa: E501 - - :param text_value: The text_value of this TaskResponseCustomFields. # noqa: E501 - :type: str - """ - - self._text_value = text_value - - @property - def display_value(self): - """Gets the display_value of this TaskResponseCustomFields. # noqa: E501 - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :return: The display_value of this TaskResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._display_value - - @display_value.setter - def display_value(self, display_value): - """Sets the display_value of this TaskResponseCustomFields. - - A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. # noqa: E501 - - :param display_value: The display_value of this TaskResponseCustomFields. # noqa: E501 - :type: str - """ - - self._display_value = display_value - - @property - def description(self): - """Gets the description of this TaskResponseCustomFields. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The description of the custom field. # noqa: E501 - - :return: The description of this TaskResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._description - - @description.setter - def description(self, description): - """Sets the description of this TaskResponseCustomFields. - - [Opt In](/docs/inputoutput-options). The description of the custom field. # noqa: E501 - - :param description: The description of this TaskResponseCustomFields. # noqa: E501 - :type: str - """ - - self._description = description - - @property - def precision(self): - """Gets the precision of this TaskResponseCustomFields. # noqa: E501 - - Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. # noqa: E501 - - :return: The precision of this TaskResponseCustomFields. # noqa: E501 - :rtype: int - """ - return self._precision - - @precision.setter - def precision(self, precision): - """Sets the precision of this TaskResponseCustomFields. - - Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. # noqa: E501 - - :param precision: The precision of this TaskResponseCustomFields. # noqa: E501 - :type: int - """ - - self._precision = precision - - @property - def format(self): - """Gets the format of this TaskResponseCustomFields. # noqa: E501 - - The format of this custom field. # noqa: E501 - - :return: The format of this TaskResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._format - - @format.setter - def format(self, format): - """Sets the format of this TaskResponseCustomFields. - - The format of this custom field. # noqa: E501 - - :param format: The format of this TaskResponseCustomFields. # noqa: E501 - :type: str - """ - allowed_values = ["currency", "identifier", "percentage", "custom", "duration", "none"] # noqa: E501 - if format not in allowed_values: - raise ValueError( - "Invalid value for `format` ({0}), must be one of {1}" # noqa: E501 - .format(format, allowed_values) - ) - - self._format = format - - @property - def currency_code(self): - """Gets the currency_code of this TaskResponseCustomFields. # noqa: E501 - - ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. # noqa: E501 - - :return: The currency_code of this TaskResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._currency_code - - @currency_code.setter - def currency_code(self, currency_code): - """Sets the currency_code of this TaskResponseCustomFields. - - ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. # noqa: E501 - - :param currency_code: The currency_code of this TaskResponseCustomFields. # noqa: E501 - :type: str - """ - - self._currency_code = currency_code - - @property - def custom_label(self): - """Gets the custom_label of this TaskResponseCustomFields. # noqa: E501 - - This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. # noqa: E501 - - :return: The custom_label of this TaskResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._custom_label - - @custom_label.setter - def custom_label(self, custom_label): - """Sets the custom_label of this TaskResponseCustomFields. - - This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. # noqa: E501 - - :param custom_label: The custom_label of this TaskResponseCustomFields. # noqa: E501 - :type: str - """ - - self._custom_label = custom_label - - @property - def custom_label_position(self): - """Gets the custom_label_position of this TaskResponseCustomFields. # noqa: E501 - - Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. # noqa: E501 - - :return: The custom_label_position of this TaskResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._custom_label_position - - @custom_label_position.setter - def custom_label_position(self, custom_label_position): - """Sets the custom_label_position of this TaskResponseCustomFields. - - Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. # noqa: E501 - - :param custom_label_position: The custom_label_position of this TaskResponseCustomFields. # noqa: E501 - :type: str - """ - allowed_values = ["prefix", "suffix", ""] # noqa: E501 - if custom_label_position not in allowed_values: - raise ValueError( - "Invalid value for `custom_label_position` ({0}), must be one of {1}" # noqa: E501 - .format(custom_label_position, allowed_values) - ) - - self._custom_label_position = custom_label_position - - @property - def is_global_to_workspace(self): - """Gets the is_global_to_workspace of this TaskResponseCustomFields. # noqa: E501 - - This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. # noqa: E501 - - :return: The is_global_to_workspace of this TaskResponseCustomFields. # noqa: E501 - :rtype: bool - """ - return self._is_global_to_workspace - - @is_global_to_workspace.setter - def is_global_to_workspace(self, is_global_to_workspace): - """Sets the is_global_to_workspace of this TaskResponseCustomFields. - - This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. # noqa: E501 - - :param is_global_to_workspace: The is_global_to_workspace of this TaskResponseCustomFields. # noqa: E501 - :type: bool - """ - - self._is_global_to_workspace = is_global_to_workspace - - @property - def has_notifications_enabled(self): - """Gets the has_notifications_enabled of this TaskResponseCustomFields. # noqa: E501 - - *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. # noqa: E501 - - :return: The has_notifications_enabled of this TaskResponseCustomFields. # noqa: E501 - :rtype: bool - """ - return self._has_notifications_enabled - - @has_notifications_enabled.setter - def has_notifications_enabled(self, has_notifications_enabled): - """Sets the has_notifications_enabled of this TaskResponseCustomFields. - - *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. # noqa: E501 - - :param has_notifications_enabled: The has_notifications_enabled of this TaskResponseCustomFields. # noqa: E501 - :type: bool - """ - - self._has_notifications_enabled = has_notifications_enabled - - @property - def asana_created_field(self): - """Gets the asana_created_field of this TaskResponseCustomFields. # noqa: E501 - - *Conditional*. A unique identifier to associate this field with the template source of truth. # noqa: E501 - - :return: The asana_created_field of this TaskResponseCustomFields. # noqa: E501 - :rtype: str - """ - return self._asana_created_field - - @asana_created_field.setter - def asana_created_field(self, asana_created_field): - """Sets the asana_created_field of this TaskResponseCustomFields. - - *Conditional*. A unique identifier to associate this field with the template source of truth. # noqa: E501 - - :param asana_created_field: The asana_created_field of this TaskResponseCustomFields. # noqa: E501 - :type: str - """ - allowed_values = ["a_v_requirements", "account_name", "actionable", "align_shipping_link", "align_status", "allotted_time", "appointment", "approval_stage", "approved", "article_series", "board_committee", "browser", "campaign_audience", "campaign_project_status", "campaign_regions", "channel_primary", "client_topic_type", "complete_by", "contact", "contact_email_address", "content_channels", "content_channels_needed", "content_stage", "content_type", "contract", "contract_status", "cost", "creation_stage", "creative_channel", "creative_needed", "creative_needs", "data_sensitivity", "deal_size", "delivery_appt", "delivery_appt_date", "department", "department_responsible", "design_request_needed", "design_request_type", "discussion_category", "do_this_task", "editorial_content_status", "editorial_content_tag", "editorial_content_type", "effort", "effort_level", "est_completion_date", "estimated_time", "estimated_value", "expected_cost", "external_steps_needed", "favorite_idea", "feedback_type", "financial", "funding_amount", "grant_application_process", "hiring_candidate_status", "idea_status", "ids_link", "ids_patient_link", "implementation_stage", "insurance", "interview_area", "interview_question_score", "itero_scan_link", "job_s_applied_to", "lab", "launch_status", "lead_status", "localization_language", "localization_market_team", "localization_status", "meeting_minutes", "meeting_needed", "minutes", "mrr", "must_localize", "name_of_foundation", "need_to_follow_up", "next_appointment", "next_steps_sales", "num_people", "number_of_user_reports", "office_location", "onboarding_activity", "owner", "participants_needed", "patient_date_of_birth", "patient_email", "patient_phone", "patient_status", "phone_number", "planning_category", "point_of_contact", "position", "post_format", "prescription", "priority", "priority_level", "product", "product_stage", "progress", "project_size", "project_status", "proposed_budget", "publish_status", "reason_for_scan", "referral", "request_type", "research_status", "responsible_department", "responsible_team", "risk_assessment_status", "room_name", "sales_counterpart", "sentiment", "shipping_link", "social_channels", "stage", "status", "status_design", "status_of_initiative", "system_setup", "task_progress", "team", "team_marketing", "team_responsible", "time_it_takes_to_complete_tasks", "timeframe", "treatment_type", "type_work_requests_it", "use_agency", "user_name", "vendor_category", "vendor_type", "word_count", ""] # noqa: E501 - if asana_created_field not in allowed_values: - raise ValueError( - "Invalid value for `asana_created_field` ({0}), must be one of {1}" # noqa: E501 - .format(asana_created_field, allowed_values) - ) - - self._asana_created_field = asana_created_field - - @property - def is_value_read_only(self): - """Gets the is_value_read_only of this TaskResponseCustomFields. # noqa: E501 - - *Conditional*. This flag describes whether a custom field is read only. # noqa: E501 - - :return: The is_value_read_only of this TaskResponseCustomFields. # noqa: E501 - :rtype: bool - """ - return self._is_value_read_only - - @is_value_read_only.setter - def is_value_read_only(self, is_value_read_only): - """Sets the is_value_read_only of this TaskResponseCustomFields. - - *Conditional*. This flag describes whether a custom field is read only. # noqa: E501 - - :param is_value_read_only: The is_value_read_only of this TaskResponseCustomFields. # noqa: E501 - :type: bool - """ - - self._is_value_read_only = is_value_read_only - - @property - def created_by(self): - """Gets the created_by of this TaskResponseCustomFields. # noqa: E501 - - - :return: The created_by of this TaskResponseCustomFields. # noqa: E501 - :rtype: CustomFieldResponseCreatedBy - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this TaskResponseCustomFields. - - - :param created_by: The created_by of this TaskResponseCustomFields. # noqa: E501 - :type: CustomFieldResponseCreatedBy - """ - - self._created_by = created_by - - @property - def people_value(self): - """Gets the people_value of this TaskResponseCustomFields. # noqa: E501 - - *Conditional*. Only relevant for custom fields of type `people`. This array of [compact user](/reference/users) objects reflects the values of a `people` custom field. # noqa: E501 - - :return: The people_value of this TaskResponseCustomFields. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._people_value - - @people_value.setter - def people_value(self, people_value): - """Sets the people_value of this TaskResponseCustomFields. - - *Conditional*. Only relevant for custom fields of type `people`. This array of [compact user](/reference/users) objects reflects the values of a `people` custom field. # noqa: E501 - - :param people_value: The people_value of this TaskResponseCustomFields. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._people_value = people_value - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskResponseCustomFields, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskResponseCustomFields): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_response_data.py b/asana/models/task_response_data.py deleted file mode 100644 index d860463a..00000000 --- a/asana/models/task_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this TaskResponseData. # noqa: E501 - - - :return: The data of this TaskResponseData. # noqa: E501 - :rtype: TaskResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskResponseData. - - - :param data: The data of this TaskResponseData. # noqa: E501 - :type: TaskResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_response_parent.py b/asana/models/task_response_parent.py deleted file mode 100644 index 5efc68f7..00000000 --- a/asana/models/task_response_parent.py +++ /dev/null @@ -1,228 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskResponseParent(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str', - 'created_by': 'AttachmentResponseParentCreatedBy' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype', - 'created_by': 'created_by' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None, created_by=None): # noqa: E501 - """TaskResponseParent - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self._created_by = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if created_by is not None: - self.created_by = created_by - - @property - def gid(self): - """Gets the gid of this TaskResponseParent. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskResponseParent. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskResponseParent. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskResponseParent. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskResponseParent. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskResponseParent. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskResponseParent. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskResponseParent. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskResponseParent. # noqa: E501 - - The name of the task. # noqa: E501 - - :return: The name of this TaskResponseParent. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskResponseParent. - - The name of the task. # noqa: E501 - - :param name: The name of this TaskResponseParent. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this TaskResponseParent. # noqa: E501 - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :return: The resource_subtype of this TaskResponseParent. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this TaskResponseParent. - - The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. # noqa: E501 - - :param resource_subtype: The resource_subtype of this TaskResponseParent. # noqa: E501 - :type: str - """ - allowed_values = ["default_task", "milestone", "section", "approval"] # noqa: E501 - if resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(resource_subtype, allowed_values) - ) - - self._resource_subtype = resource_subtype - - @property - def created_by(self): - """Gets the created_by of this TaskResponseParent. # noqa: E501 - - - :return: The created_by of this TaskResponseParent. # noqa: E501 - :rtype: AttachmentResponseParentCreatedBy - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this TaskResponseParent. - - - :param created_by: The created_by of this TaskResponseParent. # noqa: E501 - :type: AttachmentResponseParentCreatedBy - """ - - self._created_by = created_by - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskResponseParent, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskResponseParent): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_response_tags.py b/asana/models/task_response_tags.py deleted file mode 100644 index 53dd467d..00000000 --- a/asana/models/task_response_tags.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskResponseTags(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """TaskResponseTags - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this TaskResponseTags. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskResponseTags. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskResponseTags. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskResponseTags. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskResponseTags. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskResponseTags. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskResponseTags. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskResponseTags. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskResponseTags. # noqa: E501 - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :return: The name of this TaskResponseTags. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskResponseTags. - - Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. # noqa: E501 - - :param name: The name of this TaskResponseTags. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskResponseTags, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskResponseTags): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_response_workspace.py b/asana/models/task_response_workspace.py deleted file mode 100644 index 3dfbacd4..00000000 --- a/asana/models/task_response_workspace.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskResponseWorkspace(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """TaskResponseWorkspace - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this TaskResponseWorkspace. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskResponseWorkspace. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskResponseWorkspace. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskResponseWorkspace. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskResponseWorkspace. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskResponseWorkspace. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskResponseWorkspace. # noqa: E501 - - The name of the workspace. # noqa: E501 - - :return: The name of this TaskResponseWorkspace. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskResponseWorkspace. - - The name of the workspace. # noqa: E501 - - :param name: The name of this TaskResponseWorkspace. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskResponseWorkspace, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskResponseWorkspace): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_set_parent_request.py b/asana/models/task_set_parent_request.py deleted file mode 100644 index fe0cb3d6..00000000 --- a/asana/models/task_set_parent_request.py +++ /dev/null @@ -1,169 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskSetParentRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'parent': 'str', - 'insert_after': 'str', - 'insert_before': 'str' - } - - attribute_map = { - 'parent': 'parent', - 'insert_after': 'insert_after', - 'insert_before': 'insert_before' - } - - def __init__(self, parent=None, insert_after=None, insert_before=None): # noqa: E501 - """TaskSetParentRequest - a model defined in Swagger""" # noqa: E501 - self._parent = None - self._insert_after = None - self._insert_before = None - self.discriminator = None - self.parent = parent - if insert_after is not None: - self.insert_after = insert_after - if insert_before is not None: - self.insert_before = insert_before - - @property - def parent(self): - """Gets the parent of this TaskSetParentRequest. # noqa: E501 - - The new parent of the task, or `null` for no parent. # noqa: E501 - - :return: The parent of this TaskSetParentRequest. # noqa: E501 - :rtype: str - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this TaskSetParentRequest. - - The new parent of the task, or `null` for no parent. # noqa: E501 - - :param parent: The parent of this TaskSetParentRequest. # noqa: E501 - :type: str - """ - if parent is None: - raise ValueError("Invalid value for `parent`, must not be `None`") # noqa: E501 - - self._parent = parent - - @property - def insert_after(self): - """Gets the insert_after of this TaskSetParentRequest. # noqa: E501 - - A subtask of the parent to insert the task after, or `null` to insert at the beginning of the list. # noqa: E501 - - :return: The insert_after of this TaskSetParentRequest. # noqa: E501 - :rtype: str - """ - return self._insert_after - - @insert_after.setter - def insert_after(self, insert_after): - """Sets the insert_after of this TaskSetParentRequest. - - A subtask of the parent to insert the task after, or `null` to insert at the beginning of the list. # noqa: E501 - - :param insert_after: The insert_after of this TaskSetParentRequest. # noqa: E501 - :type: str - """ - - self._insert_after = insert_after - - @property - def insert_before(self): - """Gets the insert_before of this TaskSetParentRequest. # noqa: E501 - - A subtask of the parent to insert the task before, or `null` to insert at the end of the list. # noqa: E501 - - :return: The insert_before of this TaskSetParentRequest. # noqa: E501 - :rtype: str - """ - return self._insert_before - - @insert_before.setter - def insert_before(self, insert_before): - """Sets the insert_before of this TaskSetParentRequest. - - A subtask of the parent to insert the task before, or `null` to insert at the end of the list. # noqa: E501 - - :param insert_before: The insert_before of this TaskSetParentRequest. # noqa: E501 - :type: str - """ - - self._insert_before = insert_before - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskSetParentRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskSetParentRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_template_base.py b/asana/models/task_template_base.py deleted file mode 100644 index d408eb07..00000000 --- a/asana/models/task_template_base.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskTemplateBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """TaskTemplateBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this TaskTemplateBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskTemplateBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskTemplateBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskTemplateBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskTemplateBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskTemplateBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskTemplateBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskTemplateBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskTemplateBase. # noqa: E501 - - Name of the task template. # noqa: E501 - - :return: The name of this TaskTemplateBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskTemplateBase. - - Name of the task template. # noqa: E501 - - :param name: The name of this TaskTemplateBase. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskTemplateBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskTemplateBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_template_compact.py b/asana/models/task_template_compact.py deleted file mode 100644 index 65fc467d..00000000 --- a/asana/models/task_template_compact.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskTemplateCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """TaskTemplateCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this TaskTemplateCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskTemplateCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskTemplateCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskTemplateCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskTemplateCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskTemplateCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskTemplateCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskTemplateCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskTemplateCompact. # noqa: E501 - - Name of the task template. # noqa: E501 - - :return: The name of this TaskTemplateCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskTemplateCompact. - - Name of the task template. # noqa: E501 - - :param name: The name of this TaskTemplateCompact. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskTemplateCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskTemplateCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_template_gid_instantiate_task_body.py b/asana/models/task_template_gid_instantiate_task_body.py deleted file mode 100644 index 6ab01d1b..00000000 --- a/asana/models/task_template_gid_instantiate_task_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskTemplateGidInstantiateTaskBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskTemplateInstantiateTaskRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskTemplateGidInstantiateTaskBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TaskTemplateGidInstantiateTaskBody. # noqa: E501 - - - :return: The data of this TaskTemplateGidInstantiateTaskBody. # noqa: E501 - :rtype: TaskTemplateInstantiateTaskRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskTemplateGidInstantiateTaskBody. - - - :param data: The data of this TaskTemplateGidInstantiateTaskBody. # noqa: E501 - :type: TaskTemplateInstantiateTaskRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskTemplateGidInstantiateTaskBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskTemplateGidInstantiateTaskBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_template_instantiate_task_request.py b/asana/models/task_template_instantiate_task_request.py deleted file mode 100644 index ae592132..00000000 --- a/asana/models/task_template_instantiate_task_request.py +++ /dev/null @@ -1,112 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskTemplateInstantiateTaskRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'name': 'str' - } - - attribute_map = { - 'name': 'name' - } - - def __init__(self, name=None): # noqa: E501 - """TaskTemplateInstantiateTaskRequest - a model defined in Swagger""" # noqa: E501 - self._name = None - self.discriminator = None - if name is not None: - self.name = name - - @property - def name(self): - """Gets the name of this TaskTemplateInstantiateTaskRequest. # noqa: E501 - - The name of the new task. If not provided, the name of the task template will be used. # noqa: E501 - - :return: The name of this TaskTemplateInstantiateTaskRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskTemplateInstantiateTaskRequest. - - The name of the new task. If not provided, the name of the task template will be used. # noqa: E501 - - :param name: The name of this TaskTemplateInstantiateTaskRequest. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskTemplateInstantiateTaskRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskTemplateInstantiateTaskRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_template_recipe.py b/asana/models/task_template_recipe.py deleted file mode 100644 index 8d09a833..00000000 --- a/asana/models/task_template_recipe.py +++ /dev/null @@ -1,482 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskTemplateRecipe(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'name': 'str', - 'task_resource_subtype': 'str', - 'description': 'str', - 'html_description': 'str', - 'memberships': 'list[JobBaseNewProject]', - 'relative_start_on': 'int', - 'relative_due_on': 'int', - 'due_time': 'str', - 'dependencies': 'list[TaskTemplateRecipeDependencies]', - 'dependents': 'list[TaskTemplateRecipeDependencies]', - 'followers': 'list[CustomFieldResponsePeopleValue]', - 'attachments': 'list[TaskTemplateRecipeAttachments]', - 'subtasks': 'list[TaskTemplateRecipeDependencies]', - 'custom_fields': 'list[PortfolioResponseCustomFields]' - } - - attribute_map = { - 'name': 'name', - 'task_resource_subtype': 'task_resource_subtype', - 'description': 'description', - 'html_description': 'html_description', - 'memberships': 'memberships', - 'relative_start_on': 'relative_start_on', - 'relative_due_on': 'relative_due_on', - 'due_time': 'due_time', - 'dependencies': 'dependencies', - 'dependents': 'dependents', - 'followers': 'followers', - 'attachments': 'attachments', - 'subtasks': 'subtasks', - 'custom_fields': 'custom_fields' - } - - def __init__(self, name=None, task_resource_subtype=None, description=None, html_description=None, memberships=None, relative_start_on=None, relative_due_on=None, due_time=None, dependencies=None, dependents=None, followers=None, attachments=None, subtasks=None, custom_fields=None): # noqa: E501 - """TaskTemplateRecipe - a model defined in Swagger""" # noqa: E501 - self._name = None - self._task_resource_subtype = None - self._description = None - self._html_description = None - self._memberships = None - self._relative_start_on = None - self._relative_due_on = None - self._due_time = None - self._dependencies = None - self._dependents = None - self._followers = None - self._attachments = None - self._subtasks = None - self._custom_fields = None - self.discriminator = None - if name is not None: - self.name = name - if task_resource_subtype is not None: - self.task_resource_subtype = task_resource_subtype - if description is not None: - self.description = description - if html_description is not None: - self.html_description = html_description - if memberships is not None: - self.memberships = memberships - if relative_start_on is not None: - self.relative_start_on = relative_start_on - if relative_due_on is not None: - self.relative_due_on = relative_due_on - if due_time is not None: - self.due_time = due_time - if dependencies is not None: - self.dependencies = dependencies - if dependents is not None: - self.dependents = dependents - if followers is not None: - self.followers = followers - if attachments is not None: - self.attachments = attachments - if subtasks is not None: - self.subtasks = subtasks - if custom_fields is not None: - self.custom_fields = custom_fields - - @property - def name(self): - """Gets the name of this TaskTemplateRecipe. # noqa: E501 - - Name of the task that will be created from this template. # noqa: E501 - - :return: The name of this TaskTemplateRecipe. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskTemplateRecipe. - - Name of the task that will be created from this template. # noqa: E501 - - :param name: The name of this TaskTemplateRecipe. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def task_resource_subtype(self): - """Gets the task_resource_subtype of this TaskTemplateRecipe. # noqa: E501 - - The subtype of the task that will be created from this template. # noqa: E501 - - :return: The task_resource_subtype of this TaskTemplateRecipe. # noqa: E501 - :rtype: str - """ - return self._task_resource_subtype - - @task_resource_subtype.setter - def task_resource_subtype(self, task_resource_subtype): - """Sets the task_resource_subtype of this TaskTemplateRecipe. - - The subtype of the task that will be created from this template. # noqa: E501 - - :param task_resource_subtype: The task_resource_subtype of this TaskTemplateRecipe. # noqa: E501 - :type: str - """ - allowed_values = ["default_task", "milestone_task", "approval_task"] # noqa: E501 - if task_resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `task_resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(task_resource_subtype, allowed_values) - ) - - self._task_resource_subtype = task_resource_subtype - - @property - def description(self): - """Gets the description of this TaskTemplateRecipe. # noqa: E501 - - Description of the task that will be created from this template. # noqa: E501 - - :return: The description of this TaskTemplateRecipe. # noqa: E501 - :rtype: str - """ - return self._description - - @description.setter - def description(self, description): - """Sets the description of this TaskTemplateRecipe. - - Description of the task that will be created from this template. # noqa: E501 - - :param description: The description of this TaskTemplateRecipe. # noqa: E501 - :type: str - """ - - self._description = description - - @property - def html_description(self): - """Gets the html_description of this TaskTemplateRecipe. # noqa: E501 - - HTML description of the task that will be created from this template. # noqa: E501 - - :return: The html_description of this TaskTemplateRecipe. # noqa: E501 - :rtype: str - """ - return self._html_description - - @html_description.setter - def html_description(self, html_description): - """Sets the html_description of this TaskTemplateRecipe. - - HTML description of the task that will be created from this template. # noqa: E501 - - :param html_description: The html_description of this TaskTemplateRecipe. # noqa: E501 - :type: str - """ - - self._html_description = html_description - - @property - def memberships(self): - """Gets the memberships of this TaskTemplateRecipe. # noqa: E501 - - Array of projects that the task created from this template will be added to # noqa: E501 - - :return: The memberships of this TaskTemplateRecipe. # noqa: E501 - :rtype: list[JobBaseNewProject] - """ - return self._memberships - - @memberships.setter - def memberships(self, memberships): - """Sets the memberships of this TaskTemplateRecipe. - - Array of projects that the task created from this template will be added to # noqa: E501 - - :param memberships: The memberships of this TaskTemplateRecipe. # noqa: E501 - :type: list[JobBaseNewProject] - """ - - self._memberships = memberships - - @property - def relative_start_on(self): - """Gets the relative_start_on of this TaskTemplateRecipe. # noqa: E501 - - The number of days after the task has been instantiated on which that the task will start # noqa: E501 - - :return: The relative_start_on of this TaskTemplateRecipe. # noqa: E501 - :rtype: int - """ - return self._relative_start_on - - @relative_start_on.setter - def relative_start_on(self, relative_start_on): - """Sets the relative_start_on of this TaskTemplateRecipe. - - The number of days after the task has been instantiated on which that the task will start # noqa: E501 - - :param relative_start_on: The relative_start_on of this TaskTemplateRecipe. # noqa: E501 - :type: int - """ - - self._relative_start_on = relative_start_on - - @property - def relative_due_on(self): - """Gets the relative_due_on of this TaskTemplateRecipe. # noqa: E501 - - The number of days after the task has been instantiated on which that the task will be due # noqa: E501 - - :return: The relative_due_on of this TaskTemplateRecipe. # noqa: E501 - :rtype: int - """ - return self._relative_due_on - - @relative_due_on.setter - def relative_due_on(self, relative_due_on): - """Sets the relative_due_on of this TaskTemplateRecipe. - - The number of days after the task has been instantiated on which that the task will be due # noqa: E501 - - :param relative_due_on: The relative_due_on of this TaskTemplateRecipe. # noqa: E501 - :type: int - """ - - self._relative_due_on = relative_due_on - - @property - def due_time(self): - """Gets the due_time of this TaskTemplateRecipe. # noqa: E501 - - The time of day that the task will be due # noqa: E501 - - :return: The due_time of this TaskTemplateRecipe. # noqa: E501 - :rtype: str - """ - return self._due_time - - @due_time.setter - def due_time(self, due_time): - """Sets the due_time of this TaskTemplateRecipe. - - The time of day that the task will be due # noqa: E501 - - :param due_time: The due_time of this TaskTemplateRecipe. # noqa: E501 - :type: str - """ - - self._due_time = due_time - - @property - def dependencies(self): - """Gets the dependencies of this TaskTemplateRecipe. # noqa: E501 - - Array of task templates that the task created from this template will depend on # noqa: E501 - - :return: The dependencies of this TaskTemplateRecipe. # noqa: E501 - :rtype: list[TaskTemplateRecipeDependencies] - """ - return self._dependencies - - @dependencies.setter - def dependencies(self, dependencies): - """Sets the dependencies of this TaskTemplateRecipe. - - Array of task templates that the task created from this template will depend on # noqa: E501 - - :param dependencies: The dependencies of this TaskTemplateRecipe. # noqa: E501 - :type: list[TaskTemplateRecipeDependencies] - """ - - self._dependencies = dependencies - - @property - def dependents(self): - """Gets the dependents of this TaskTemplateRecipe. # noqa: E501 - - Array of task templates that will depend on the task created from this template # noqa: E501 - - :return: The dependents of this TaskTemplateRecipe. # noqa: E501 - :rtype: list[TaskTemplateRecipeDependencies] - """ - return self._dependents - - @dependents.setter - def dependents(self, dependents): - """Sets the dependents of this TaskTemplateRecipe. - - Array of task templates that will depend on the task created from this template # noqa: E501 - - :param dependents: The dependents of this TaskTemplateRecipe. # noqa: E501 - :type: list[TaskTemplateRecipeDependencies] - """ - - self._dependents = dependents - - @property - def followers(self): - """Gets the followers of this TaskTemplateRecipe. # noqa: E501 - - Array of users that will be added as followers to the task created from this template # noqa: E501 - - :return: The followers of this TaskTemplateRecipe. # noqa: E501 - :rtype: list[CustomFieldResponsePeopleValue] - """ - return self._followers - - @followers.setter - def followers(self, followers): - """Sets the followers of this TaskTemplateRecipe. - - Array of users that will be added as followers to the task created from this template # noqa: E501 - - :param followers: The followers of this TaskTemplateRecipe. # noqa: E501 - :type: list[CustomFieldResponsePeopleValue] - """ - - self._followers = followers - - @property - def attachments(self): - """Gets the attachments of this TaskTemplateRecipe. # noqa: E501 - - Array of attachments that will be added to the task created from this template # noqa: E501 - - :return: The attachments of this TaskTemplateRecipe. # noqa: E501 - :rtype: list[TaskTemplateRecipeAttachments] - """ - return self._attachments - - @attachments.setter - def attachments(self, attachments): - """Sets the attachments of this TaskTemplateRecipe. - - Array of attachments that will be added to the task created from this template # noqa: E501 - - :param attachments: The attachments of this TaskTemplateRecipe. # noqa: E501 - :type: list[TaskTemplateRecipeAttachments] - """ - - self._attachments = attachments - - @property - def subtasks(self): - """Gets the subtasks of this TaskTemplateRecipe. # noqa: E501 - - Array of subtasks that will be added to the task created from this template # noqa: E501 - - :return: The subtasks of this TaskTemplateRecipe. # noqa: E501 - :rtype: list[TaskTemplateRecipeDependencies] - """ - return self._subtasks - - @subtasks.setter - def subtasks(self, subtasks): - """Sets the subtasks of this TaskTemplateRecipe. - - Array of subtasks that will be added to the task created from this template # noqa: E501 - - :param subtasks: The subtasks of this TaskTemplateRecipe. # noqa: E501 - :type: list[TaskTemplateRecipeDependencies] - """ - - self._subtasks = subtasks - - @property - def custom_fields(self): - """Gets the custom_fields of this TaskTemplateRecipe. # noqa: E501 - - Array of custom fields that will be added to the task created from this template # noqa: E501 - - :return: The custom_fields of this TaskTemplateRecipe. # noqa: E501 - :rtype: list[PortfolioResponseCustomFields] - """ - return self._custom_fields - - @custom_fields.setter - def custom_fields(self, custom_fields): - """Sets the custom_fields of this TaskTemplateRecipe. - - Array of custom fields that will be added to the task created from this template # noqa: E501 - - :param custom_fields: The custom_fields of this TaskTemplateRecipe. # noqa: E501 - :type: list[PortfolioResponseCustomFields] - """ - - self._custom_fields = custom_fields - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskTemplateRecipe, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskTemplateRecipe): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_template_recipe_attachments.py b/asana/models/task_template_recipe_attachments.py deleted file mode 100644 index fcebf04e..00000000 --- a/asana/models/task_template_recipe_attachments.py +++ /dev/null @@ -1,196 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskTemplateRecipeAttachments(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'resource_subtype': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'resource_subtype': 'resource_subtype' - } - - def __init__(self, gid=None, resource_type=None, name=None, resource_subtype=None): # noqa: E501 - """TaskTemplateRecipeAttachments - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._resource_subtype = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if resource_subtype is not None: - self.resource_subtype = resource_subtype - - @property - def gid(self): - """Gets the gid of this TaskTemplateRecipeAttachments. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskTemplateRecipeAttachments. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskTemplateRecipeAttachments. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskTemplateRecipeAttachments. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskTemplateRecipeAttachments. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskTemplateRecipeAttachments. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskTemplateRecipeAttachments. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskTemplateRecipeAttachments. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskTemplateRecipeAttachments. # noqa: E501 - - The name of the file. # noqa: E501 - - :return: The name of this TaskTemplateRecipeAttachments. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskTemplateRecipeAttachments. - - The name of the file. # noqa: E501 - - :param name: The name of this TaskTemplateRecipeAttachments. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def resource_subtype(self): - """Gets the resource_subtype of this TaskTemplateRecipeAttachments. # noqa: E501 - - The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `onedrive`, `box`, `vimeo`, and `external`. # noqa: E501 - - :return: The resource_subtype of this TaskTemplateRecipeAttachments. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this TaskTemplateRecipeAttachments. - - The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `onedrive`, `box`, `vimeo`, and `external`. # noqa: E501 - - :param resource_subtype: The resource_subtype of this TaskTemplateRecipeAttachments. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskTemplateRecipeAttachments, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskTemplateRecipeAttachments): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_template_recipe_compact.py b/asana/models/task_template_recipe_compact.py deleted file mode 100644 index ede50f2b..00000000 --- a/asana/models/task_template_recipe_compact.py +++ /dev/null @@ -1,146 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskTemplateRecipeCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'name': 'str', - 'task_resource_subtype': 'str' - } - - attribute_map = { - 'name': 'name', - 'task_resource_subtype': 'task_resource_subtype' - } - - def __init__(self, name=None, task_resource_subtype=None): # noqa: E501 - """TaskTemplateRecipeCompact - a model defined in Swagger""" # noqa: E501 - self._name = None - self._task_resource_subtype = None - self.discriminator = None - if name is not None: - self.name = name - if task_resource_subtype is not None: - self.task_resource_subtype = task_resource_subtype - - @property - def name(self): - """Gets the name of this TaskTemplateRecipeCompact. # noqa: E501 - - Name of the task that will be created from this template. # noqa: E501 - - :return: The name of this TaskTemplateRecipeCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskTemplateRecipeCompact. - - Name of the task that will be created from this template. # noqa: E501 - - :param name: The name of this TaskTemplateRecipeCompact. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def task_resource_subtype(self): - """Gets the task_resource_subtype of this TaskTemplateRecipeCompact. # noqa: E501 - - The subtype of the task that will be created from this template. # noqa: E501 - - :return: The task_resource_subtype of this TaskTemplateRecipeCompact. # noqa: E501 - :rtype: str - """ - return self._task_resource_subtype - - @task_resource_subtype.setter - def task_resource_subtype(self, task_resource_subtype): - """Sets the task_resource_subtype of this TaskTemplateRecipeCompact. - - The subtype of the task that will be created from this template. # noqa: E501 - - :param task_resource_subtype: The task_resource_subtype of this TaskTemplateRecipeCompact. # noqa: E501 - :type: str - """ - allowed_values = ["default_task", "milestone_task", "approval_task"] # noqa: E501 - if task_resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `task_resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(task_resource_subtype, allowed_values) - ) - - self._task_resource_subtype = task_resource_subtype - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskTemplateRecipeCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskTemplateRecipeCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_template_recipe_dependencies.py b/asana/models/task_template_recipe_dependencies.py deleted file mode 100644 index 6c1759cc..00000000 --- a/asana/models/task_template_recipe_dependencies.py +++ /dev/null @@ -1,146 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskTemplateRecipeDependencies(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'name': 'str', - 'task_resource_subtype': 'str' - } - - attribute_map = { - 'name': 'name', - 'task_resource_subtype': 'task_resource_subtype' - } - - def __init__(self, name=None, task_resource_subtype=None): # noqa: E501 - """TaskTemplateRecipeDependencies - a model defined in Swagger""" # noqa: E501 - self._name = None - self._task_resource_subtype = None - self.discriminator = None - if name is not None: - self.name = name - if task_resource_subtype is not None: - self.task_resource_subtype = task_resource_subtype - - @property - def name(self): - """Gets the name of this TaskTemplateRecipeDependencies. # noqa: E501 - - Name of the task that will be created from this template. # noqa: E501 - - :return: The name of this TaskTemplateRecipeDependencies. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskTemplateRecipeDependencies. - - Name of the task that will be created from this template. # noqa: E501 - - :param name: The name of this TaskTemplateRecipeDependencies. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def task_resource_subtype(self): - """Gets the task_resource_subtype of this TaskTemplateRecipeDependencies. # noqa: E501 - - The subtype of the task that will be created from this template. # noqa: E501 - - :return: The task_resource_subtype of this TaskTemplateRecipeDependencies. # noqa: E501 - :rtype: str - """ - return self._task_resource_subtype - - @task_resource_subtype.setter - def task_resource_subtype(self, task_resource_subtype): - """Sets the task_resource_subtype of this TaskTemplateRecipeDependencies. - - The subtype of the task that will be created from this template. # noqa: E501 - - :param task_resource_subtype: The task_resource_subtype of this TaskTemplateRecipeDependencies. # noqa: E501 - :type: str - """ - allowed_values = ["default_task", "milestone_task", "approval_task"] # noqa: E501 - if task_resource_subtype not in allowed_values: - raise ValueError( - "Invalid value for `task_resource_subtype` ({0}), must be one of {1}" # noqa: E501 - .format(task_resource_subtype, allowed_values) - ) - - self._task_resource_subtype = task_resource_subtype - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskTemplateRecipeDependencies, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskTemplateRecipeDependencies): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_template_response.py b/asana/models/task_template_response.py deleted file mode 100644 index 7c646a97..00000000 --- a/asana/models/task_template_response.py +++ /dev/null @@ -1,280 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskTemplateResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'project': 'AllOfTaskTemplateResponseProject', - 'template': 'AllOfTaskTemplateResponseTemplate', - 'created_by': 'AllOfTaskTemplateResponseCreatedBy', - 'created_at': 'datetime' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'project': 'project', - 'template': 'template', - 'created_by': 'created_by', - 'created_at': 'created_at' - } - - def __init__(self, gid=None, resource_type=None, name=None, project=None, template=None, created_by=None, created_at=None): # noqa: E501 - """TaskTemplateResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._project = None - self._template = None - self._created_by = None - self._created_at = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if project is not None: - self.project = project - if template is not None: - self.template = template - if created_by is not None: - self.created_by = created_by - if created_at is not None: - self.created_at = created_at - - @property - def gid(self): - """Gets the gid of this TaskTemplateResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TaskTemplateResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TaskTemplateResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TaskTemplateResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TaskTemplateResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TaskTemplateResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TaskTemplateResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TaskTemplateResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TaskTemplateResponse. # noqa: E501 - - Name of the task template. # noqa: E501 - - :return: The name of this TaskTemplateResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TaskTemplateResponse. - - Name of the task template. # noqa: E501 - - :param name: The name of this TaskTemplateResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def project(self): - """Gets the project of this TaskTemplateResponse. # noqa: E501 - - The project that this task template belongs to. # noqa: E501 - - :return: The project of this TaskTemplateResponse. # noqa: E501 - :rtype: AllOfTaskTemplateResponseProject - """ - return self._project - - @project.setter - def project(self, project): - """Sets the project of this TaskTemplateResponse. - - The project that this task template belongs to. # noqa: E501 - - :param project: The project of this TaskTemplateResponse. # noqa: E501 - :type: AllOfTaskTemplateResponseProject - """ - - self._project = project - - @property - def template(self): - """Gets the template of this TaskTemplateResponse. # noqa: E501 - - The configuration for the task that will be created from this template. # noqa: E501 - - :return: The template of this TaskTemplateResponse. # noqa: E501 - :rtype: AllOfTaskTemplateResponseTemplate - """ - return self._template - - @template.setter - def template(self, template): - """Sets the template of this TaskTemplateResponse. - - The configuration for the task that will be created from this template. # noqa: E501 - - :param template: The template of this TaskTemplateResponse. # noqa: E501 - :type: AllOfTaskTemplateResponseTemplate - """ - - self._template = template - - @property - def created_by(self): - """Gets the created_by of this TaskTemplateResponse. # noqa: E501 - - The user who created this task template. # noqa: E501 - - :return: The created_by of this TaskTemplateResponse. # noqa: E501 - :rtype: AllOfTaskTemplateResponseCreatedBy - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this TaskTemplateResponse. - - The user who created this task template. # noqa: E501 - - :param created_by: The created_by of this TaskTemplateResponse. # noqa: E501 - :type: AllOfTaskTemplateResponseCreatedBy - """ - - self._created_by = created_by - - @property - def created_at(self): - """Gets the created_at of this TaskTemplateResponse. # noqa: E501 - - The time at which this task template was created. # noqa: E501 - - :return: The created_at of this TaskTemplateResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this TaskTemplateResponse. - - The time at which this task template was created. # noqa: E501 - - :param created_at: The created_at of this TaskTemplateResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskTemplateResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskTemplateResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_template_response_array.py b/asana/models/task_template_response_array.py deleted file mode 100644 index cec9b95b..00000000 --- a/asana/models/task_template_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskTemplateResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[TaskTemplateResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """TaskTemplateResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this TaskTemplateResponseArray. # noqa: E501 - - - :return: The data of this TaskTemplateResponseArray. # noqa: E501 - :rtype: list[TaskTemplateResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskTemplateResponseArray. - - - :param data: The data of this TaskTemplateResponseArray. # noqa: E501 - :type: list[TaskTemplateResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this TaskTemplateResponseArray. # noqa: E501 - - - :return: The next_page of this TaskTemplateResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this TaskTemplateResponseArray. - - - :param next_page: The next_page of this TaskTemplateResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskTemplateResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskTemplateResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/task_template_response_data.py b/asana/models/task_template_response_data.py deleted file mode 100644 index 55d2de6b..00000000 --- a/asana/models/task_template_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TaskTemplateResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskTemplateResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TaskTemplateResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this TaskTemplateResponseData. # noqa: E501 - - - :return: The data of this TaskTemplateResponseData. # noqa: E501 - :rtype: TaskTemplateResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TaskTemplateResponseData. - - - :param data: The data of this TaskTemplateResponseData. # noqa: E501 - :type: TaskTemplateResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TaskTemplateResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TaskTemplateResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/tasks_body.py b/asana/models/tasks_body.py deleted file mode 100644 index 80472845..00000000 --- a/asana/models/tasks_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TasksBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TasksBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TasksBody. # noqa: E501 - - - :return: The data of this TasksBody. # noqa: E501 - :rtype: TaskRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TasksBody. - - - :param data: The data of this TasksBody. # noqa: E501 - :type: TaskRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TasksBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TasksBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/tasks_task_gid_body.py b/asana/models/tasks_task_gid_body.py deleted file mode 100644 index c2f505a7..00000000 --- a/asana/models/tasks_task_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TasksTaskGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TaskRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TasksTaskGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TasksTaskGidBody. # noqa: E501 - - - :return: The data of this TasksTaskGidBody. # noqa: E501 - :rtype: TaskRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TasksTaskGidBody. - - - :param data: The data of this TasksTaskGidBody. # noqa: E501 - :type: TaskRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TasksTaskGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TasksTaskGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_add_user_request.py b/asana/models/team_add_user_request.py deleted file mode 100644 index c897dbdb..00000000 --- a/asana/models/team_add_user_request.py +++ /dev/null @@ -1,112 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamAddUserRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'user': 'str' - } - - attribute_map = { - 'user': 'user' - } - - def __init__(self, user=None): # noqa: E501 - """TeamAddUserRequest - a model defined in Swagger""" # noqa: E501 - self._user = None - self.discriminator = None - if user is not None: - self.user = user - - @property - def user(self): - """Gets the user of this TeamAddUserRequest. # noqa: E501 - - A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :return: The user of this TeamAddUserRequest. # noqa: E501 - :rtype: str - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this TeamAddUserRequest. - - A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :param user: The user of this TeamAddUserRequest. # noqa: E501 - :type: str - """ - - self._user = user - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamAddUserRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamAddUserRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_base.py b/asana/models/team_base.py deleted file mode 100644 index ed931b84..00000000 --- a/asana/models/team_base.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """TeamBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this TeamBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TeamBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TeamBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TeamBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TeamBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TeamBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TeamBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TeamBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TeamBase. # noqa: E501 - - The name of the team. # noqa: E501 - - :return: The name of this TeamBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TeamBase. - - The name of the team. # noqa: E501 - - :param name: The name of this TeamBase. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_compact.py b/asana/models/team_compact.py deleted file mode 100644 index 13a47e71..00000000 --- a/asana/models/team_compact.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """TeamCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this TeamCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TeamCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TeamCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TeamCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TeamCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TeamCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TeamCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TeamCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TeamCompact. # noqa: E501 - - The name of the team. # noqa: E501 - - :return: The name of this TeamCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TeamCompact. - - The name of the team. # noqa: E501 - - :param name: The name of this TeamCompact. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_gid_add_user_body.py b/asana/models/team_gid_add_user_body.py deleted file mode 100644 index 5be369c9..00000000 --- a/asana/models/team_gid_add_user_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamGidAddUserBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TeamAddUserRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TeamGidAddUserBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TeamGidAddUserBody. # noqa: E501 - - - :return: The data of this TeamGidAddUserBody. # noqa: E501 - :rtype: TeamAddUserRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TeamGidAddUserBody. - - - :param data: The data of this TeamGidAddUserBody. # noqa: E501 - :type: TeamAddUserRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamGidAddUserBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamGidAddUserBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_gid_projects_body.py b/asana/models/team_gid_projects_body.py deleted file mode 100644 index 66ca4c65..00000000 --- a/asana/models/team_gid_projects_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamGidProjectsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TeamGidProjectsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TeamGidProjectsBody. # noqa: E501 - - - :return: The data of this TeamGidProjectsBody. # noqa: E501 - :rtype: ProjectRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TeamGidProjectsBody. - - - :param data: The data of this TeamGidProjectsBody. # noqa: E501 - :type: ProjectRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamGidProjectsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamGidProjectsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_gid_remove_user_body.py b/asana/models/team_gid_remove_user_body.py deleted file mode 100644 index be8f94fd..00000000 --- a/asana/models/team_gid_remove_user_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamGidRemoveUserBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TeamRemoveUserRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TeamGidRemoveUserBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TeamGidRemoveUserBody. # noqa: E501 - - - :return: The data of this TeamGidRemoveUserBody. # noqa: E501 - :rtype: TeamRemoveUserRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TeamGidRemoveUserBody. - - - :param data: The data of this TeamGidRemoveUserBody. # noqa: E501 - :type: TeamRemoveUserRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamGidRemoveUserBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamGidRemoveUserBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_membership_base.py b/asana/models/team_membership_base.py deleted file mode 100644 index 62bc28f4..00000000 --- a/asana/models/team_membership_base.py +++ /dev/null @@ -1,276 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamMembershipBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'user': 'CustomFieldResponsePeopleValue', - 'team': 'ProjectTemplateBaseTeam', - 'is_guest': 'bool', - 'is_limited_access': 'bool', - 'is_admin': 'bool' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'user': 'user', - 'team': 'team', - 'is_guest': 'is_guest', - 'is_limited_access': 'is_limited_access', - 'is_admin': 'is_admin' - } - - def __init__(self, gid=None, resource_type=None, user=None, team=None, is_guest=None, is_limited_access=None, is_admin=None): # noqa: E501 - """TeamMembershipBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._user = None - self._team = None - self._is_guest = None - self._is_limited_access = None - self._is_admin = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if user is not None: - self.user = user - if team is not None: - self.team = team - if is_guest is not None: - self.is_guest = is_guest - if is_limited_access is not None: - self.is_limited_access = is_limited_access - if is_admin is not None: - self.is_admin = is_admin - - @property - def gid(self): - """Gets the gid of this TeamMembershipBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TeamMembershipBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TeamMembershipBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TeamMembershipBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TeamMembershipBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TeamMembershipBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TeamMembershipBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TeamMembershipBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def user(self): - """Gets the user of this TeamMembershipBase. # noqa: E501 - - - :return: The user of this TeamMembershipBase. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this TeamMembershipBase. - - - :param user: The user of this TeamMembershipBase. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - @property - def team(self): - """Gets the team of this TeamMembershipBase. # noqa: E501 - - - :return: The team of this TeamMembershipBase. # noqa: E501 - :rtype: ProjectTemplateBaseTeam - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this TeamMembershipBase. - - - :param team: The team of this TeamMembershipBase. # noqa: E501 - :type: ProjectTemplateBaseTeam - """ - - self._team = team - - @property - def is_guest(self): - """Gets the is_guest of this TeamMembershipBase. # noqa: E501 - - Describes if the user is a guest in the team. # noqa: E501 - - :return: The is_guest of this TeamMembershipBase. # noqa: E501 - :rtype: bool - """ - return self._is_guest - - @is_guest.setter - def is_guest(self, is_guest): - """Sets the is_guest of this TeamMembershipBase. - - Describes if the user is a guest in the team. # noqa: E501 - - :param is_guest: The is_guest of this TeamMembershipBase. # noqa: E501 - :type: bool - """ - - self._is_guest = is_guest - - @property - def is_limited_access(self): - """Gets the is_limited_access of this TeamMembershipBase. # noqa: E501 - - Describes if the user has limited access to the team. # noqa: E501 - - :return: The is_limited_access of this TeamMembershipBase. # noqa: E501 - :rtype: bool - """ - return self._is_limited_access - - @is_limited_access.setter - def is_limited_access(self, is_limited_access): - """Sets the is_limited_access of this TeamMembershipBase. - - Describes if the user has limited access to the team. # noqa: E501 - - :param is_limited_access: The is_limited_access of this TeamMembershipBase. # noqa: E501 - :type: bool - """ - - self._is_limited_access = is_limited_access - - @property - def is_admin(self): - """Gets the is_admin of this TeamMembershipBase. # noqa: E501 - - Describes if the user is a team admin. # noqa: E501 - - :return: The is_admin of this TeamMembershipBase. # noqa: E501 - :rtype: bool - """ - return self._is_admin - - @is_admin.setter - def is_admin(self, is_admin): - """Sets the is_admin of this TeamMembershipBase. - - Describes if the user is a team admin. # noqa: E501 - - :param is_admin: The is_admin of this TeamMembershipBase. # noqa: E501 - :type: bool - """ - - self._is_admin = is_admin - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamMembershipBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamMembershipBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_membership_compact.py b/asana/models/team_membership_compact.py deleted file mode 100644 index 8b17d585..00000000 --- a/asana/models/team_membership_compact.py +++ /dev/null @@ -1,276 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamMembershipCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'user': 'CustomFieldResponsePeopleValue', - 'team': 'ProjectTemplateBaseTeam', - 'is_guest': 'bool', - 'is_limited_access': 'bool', - 'is_admin': 'bool' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'user': 'user', - 'team': 'team', - 'is_guest': 'is_guest', - 'is_limited_access': 'is_limited_access', - 'is_admin': 'is_admin' - } - - def __init__(self, gid=None, resource_type=None, user=None, team=None, is_guest=None, is_limited_access=None, is_admin=None): # noqa: E501 - """TeamMembershipCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._user = None - self._team = None - self._is_guest = None - self._is_limited_access = None - self._is_admin = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if user is not None: - self.user = user - if team is not None: - self.team = team - if is_guest is not None: - self.is_guest = is_guest - if is_limited_access is not None: - self.is_limited_access = is_limited_access - if is_admin is not None: - self.is_admin = is_admin - - @property - def gid(self): - """Gets the gid of this TeamMembershipCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TeamMembershipCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TeamMembershipCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TeamMembershipCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TeamMembershipCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TeamMembershipCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TeamMembershipCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TeamMembershipCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def user(self): - """Gets the user of this TeamMembershipCompact. # noqa: E501 - - - :return: The user of this TeamMembershipCompact. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this TeamMembershipCompact. - - - :param user: The user of this TeamMembershipCompact. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - @property - def team(self): - """Gets the team of this TeamMembershipCompact. # noqa: E501 - - - :return: The team of this TeamMembershipCompact. # noqa: E501 - :rtype: ProjectTemplateBaseTeam - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this TeamMembershipCompact. - - - :param team: The team of this TeamMembershipCompact. # noqa: E501 - :type: ProjectTemplateBaseTeam - """ - - self._team = team - - @property - def is_guest(self): - """Gets the is_guest of this TeamMembershipCompact. # noqa: E501 - - Describes if the user is a guest in the team. # noqa: E501 - - :return: The is_guest of this TeamMembershipCompact. # noqa: E501 - :rtype: bool - """ - return self._is_guest - - @is_guest.setter - def is_guest(self, is_guest): - """Sets the is_guest of this TeamMembershipCompact. - - Describes if the user is a guest in the team. # noqa: E501 - - :param is_guest: The is_guest of this TeamMembershipCompact. # noqa: E501 - :type: bool - """ - - self._is_guest = is_guest - - @property - def is_limited_access(self): - """Gets the is_limited_access of this TeamMembershipCompact. # noqa: E501 - - Describes if the user has limited access to the team. # noqa: E501 - - :return: The is_limited_access of this TeamMembershipCompact. # noqa: E501 - :rtype: bool - """ - return self._is_limited_access - - @is_limited_access.setter - def is_limited_access(self, is_limited_access): - """Sets the is_limited_access of this TeamMembershipCompact. - - Describes if the user has limited access to the team. # noqa: E501 - - :param is_limited_access: The is_limited_access of this TeamMembershipCompact. # noqa: E501 - :type: bool - """ - - self._is_limited_access = is_limited_access - - @property - def is_admin(self): - """Gets the is_admin of this TeamMembershipCompact. # noqa: E501 - - Describes if the user is a team admin. # noqa: E501 - - :return: The is_admin of this TeamMembershipCompact. # noqa: E501 - :rtype: bool - """ - return self._is_admin - - @is_admin.setter - def is_admin(self, is_admin): - """Sets the is_admin of this TeamMembershipCompact. - - Describes if the user is a team admin. # noqa: E501 - - :param is_admin: The is_admin of this TeamMembershipCompact. # noqa: E501 - :type: bool - """ - - self._is_admin = is_admin - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamMembershipCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamMembershipCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_membership_response.py b/asana/models/team_membership_response.py deleted file mode 100644 index 16b5f5e7..00000000 --- a/asana/models/team_membership_response.py +++ /dev/null @@ -1,276 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamMembershipResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'user': 'CustomFieldResponsePeopleValue', - 'team': 'ProjectTemplateBaseTeam', - 'is_guest': 'bool', - 'is_limited_access': 'bool', - 'is_admin': 'bool' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'user': 'user', - 'team': 'team', - 'is_guest': 'is_guest', - 'is_limited_access': 'is_limited_access', - 'is_admin': 'is_admin' - } - - def __init__(self, gid=None, resource_type=None, user=None, team=None, is_guest=None, is_limited_access=None, is_admin=None): # noqa: E501 - """TeamMembershipResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._user = None - self._team = None - self._is_guest = None - self._is_limited_access = None - self._is_admin = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if user is not None: - self.user = user - if team is not None: - self.team = team - if is_guest is not None: - self.is_guest = is_guest - if is_limited_access is not None: - self.is_limited_access = is_limited_access - if is_admin is not None: - self.is_admin = is_admin - - @property - def gid(self): - """Gets the gid of this TeamMembershipResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TeamMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TeamMembershipResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TeamMembershipResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TeamMembershipResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TeamMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TeamMembershipResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TeamMembershipResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def user(self): - """Gets the user of this TeamMembershipResponse. # noqa: E501 - - - :return: The user of this TeamMembershipResponse. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this TeamMembershipResponse. - - - :param user: The user of this TeamMembershipResponse. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - @property - def team(self): - """Gets the team of this TeamMembershipResponse. # noqa: E501 - - - :return: The team of this TeamMembershipResponse. # noqa: E501 - :rtype: ProjectTemplateBaseTeam - """ - return self._team - - @team.setter - def team(self, team): - """Sets the team of this TeamMembershipResponse. - - - :param team: The team of this TeamMembershipResponse. # noqa: E501 - :type: ProjectTemplateBaseTeam - """ - - self._team = team - - @property - def is_guest(self): - """Gets the is_guest of this TeamMembershipResponse. # noqa: E501 - - Describes if the user is a guest in the team. # noqa: E501 - - :return: The is_guest of this TeamMembershipResponse. # noqa: E501 - :rtype: bool - """ - return self._is_guest - - @is_guest.setter - def is_guest(self, is_guest): - """Sets the is_guest of this TeamMembershipResponse. - - Describes if the user is a guest in the team. # noqa: E501 - - :param is_guest: The is_guest of this TeamMembershipResponse. # noqa: E501 - :type: bool - """ - - self._is_guest = is_guest - - @property - def is_limited_access(self): - """Gets the is_limited_access of this TeamMembershipResponse. # noqa: E501 - - Describes if the user has limited access to the team. # noqa: E501 - - :return: The is_limited_access of this TeamMembershipResponse. # noqa: E501 - :rtype: bool - """ - return self._is_limited_access - - @is_limited_access.setter - def is_limited_access(self, is_limited_access): - """Sets the is_limited_access of this TeamMembershipResponse. - - Describes if the user has limited access to the team. # noqa: E501 - - :param is_limited_access: The is_limited_access of this TeamMembershipResponse. # noqa: E501 - :type: bool - """ - - self._is_limited_access = is_limited_access - - @property - def is_admin(self): - """Gets the is_admin of this TeamMembershipResponse. # noqa: E501 - - Describes if the user is a team admin. # noqa: E501 - - :return: The is_admin of this TeamMembershipResponse. # noqa: E501 - :rtype: bool - """ - return self._is_admin - - @is_admin.setter - def is_admin(self, is_admin): - """Sets the is_admin of this TeamMembershipResponse. - - Describes if the user is a team admin. # noqa: E501 - - :param is_admin: The is_admin of this TeamMembershipResponse. # noqa: E501 - :type: bool - """ - - self._is_admin = is_admin - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamMembershipResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamMembershipResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_membership_response_array.py b/asana/models/team_membership_response_array.py deleted file mode 100644 index 4c19c827..00000000 --- a/asana/models/team_membership_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamMembershipResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[TeamMembershipResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """TeamMembershipResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this TeamMembershipResponseArray. # noqa: E501 - - - :return: The data of this TeamMembershipResponseArray. # noqa: E501 - :rtype: list[TeamMembershipResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TeamMembershipResponseArray. - - - :param data: The data of this TeamMembershipResponseArray. # noqa: E501 - :type: list[TeamMembershipResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this TeamMembershipResponseArray. # noqa: E501 - - - :return: The next_page of this TeamMembershipResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this TeamMembershipResponseArray. - - - :param next_page: The next_page of this TeamMembershipResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamMembershipResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamMembershipResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_membership_response_data.py b/asana/models/team_membership_response_data.py deleted file mode 100644 index 2364e148..00000000 --- a/asana/models/team_membership_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamMembershipResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TeamMembershipResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TeamMembershipResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this TeamMembershipResponseData. # noqa: E501 - - - :return: The data of this TeamMembershipResponseData. # noqa: E501 - :rtype: TeamMembershipResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TeamMembershipResponseData. - - - :param data: The data of this TeamMembershipResponseData. # noqa: E501 - :type: TeamMembershipResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamMembershipResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamMembershipResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_remove_user_request.py b/asana/models/team_remove_user_request.py deleted file mode 100644 index 30e24f68..00000000 --- a/asana/models/team_remove_user_request.py +++ /dev/null @@ -1,112 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamRemoveUserRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'user': 'str' - } - - attribute_map = { - 'user': 'user' - } - - def __init__(self, user=None): # noqa: E501 - """TeamRemoveUserRequest - a model defined in Swagger""" # noqa: E501 - self._user = None - self.discriminator = None - if user is not None: - self.user = user - - @property - def user(self): - """Gets the user of this TeamRemoveUserRequest. # noqa: E501 - - A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :return: The user of this TeamRemoveUserRequest. # noqa: E501 - :rtype: str - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this TeamRemoveUserRequest. - - A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :param user: The user of this TeamRemoveUserRequest. # noqa: E501 - :type: str - """ - - self._user = user - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamRemoveUserRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamRemoveUserRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_request.py b/asana/models/team_request.py deleted file mode 100644 index f5778835..00000000 --- a/asana/models/team_request.py +++ /dev/null @@ -1,490 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'description': 'str', - 'html_description': 'str', - 'organization': 'str', - 'visibility': 'str', - 'edit_team_name_or_description_access_level': 'str', - 'edit_team_visibility_or_trash_team_access_level': 'str', - 'member_invite_management_access_level': 'str', - 'guest_invite_management_access_level': 'str', - 'join_request_management_access_level': 'str', - 'team_member_removal_access_level': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'description': 'description', - 'html_description': 'html_description', - 'organization': 'organization', - 'visibility': 'visibility', - 'edit_team_name_or_description_access_level': 'edit_team_name_or_description_access_level', - 'edit_team_visibility_or_trash_team_access_level': 'edit_team_visibility_or_trash_team_access_level', - 'member_invite_management_access_level': 'member_invite_management_access_level', - 'guest_invite_management_access_level': 'guest_invite_management_access_level', - 'join_request_management_access_level': 'join_request_management_access_level', - 'team_member_removal_access_level': 'team_member_removal_access_level' - } - - def __init__(self, gid=None, resource_type=None, name=None, description=None, html_description=None, organization=None, visibility=None, edit_team_name_or_description_access_level=None, edit_team_visibility_or_trash_team_access_level=None, member_invite_management_access_level=None, guest_invite_management_access_level=None, join_request_management_access_level=None, team_member_removal_access_level=None): # noqa: E501 - """TeamRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._description = None - self._html_description = None - self._organization = None - self._visibility = None - self._edit_team_name_or_description_access_level = None - self._edit_team_visibility_or_trash_team_access_level = None - self._member_invite_management_access_level = None - self._guest_invite_management_access_level = None - self._join_request_management_access_level = None - self._team_member_removal_access_level = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if description is not None: - self.description = description - if html_description is not None: - self.html_description = html_description - if organization is not None: - self.organization = organization - if visibility is not None: - self.visibility = visibility - if edit_team_name_or_description_access_level is not None: - self.edit_team_name_or_description_access_level = edit_team_name_or_description_access_level - if edit_team_visibility_or_trash_team_access_level is not None: - self.edit_team_visibility_or_trash_team_access_level = edit_team_visibility_or_trash_team_access_level - if member_invite_management_access_level is not None: - self.member_invite_management_access_level = member_invite_management_access_level - if guest_invite_management_access_level is not None: - self.guest_invite_management_access_level = guest_invite_management_access_level - if join_request_management_access_level is not None: - self.join_request_management_access_level = join_request_management_access_level - if team_member_removal_access_level is not None: - self.team_member_removal_access_level = team_member_removal_access_level - - @property - def gid(self): - """Gets the gid of this TeamRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TeamRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TeamRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TeamRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TeamRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TeamRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TeamRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TeamRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TeamRequest. # noqa: E501 - - The name of the team. # noqa: E501 - - :return: The name of this TeamRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TeamRequest. - - The name of the team. # noqa: E501 - - :param name: The name of this TeamRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def description(self): - """Gets the description of this TeamRequest. # noqa: E501 - - The description of the team. # noqa: E501 - - :return: The description of this TeamRequest. # noqa: E501 - :rtype: str - """ - return self._description - - @description.setter - def description(self, description): - """Sets the description of this TeamRequest. - - The description of the team. # noqa: E501 - - :param description: The description of this TeamRequest. # noqa: E501 - :type: str - """ - - self._description = description - - @property - def html_description(self): - """Gets the html_description of this TeamRequest. # noqa: E501 - - The description of the team with formatting as HTML. # noqa: E501 - - :return: The html_description of this TeamRequest. # noqa: E501 - :rtype: str - """ - return self._html_description - - @html_description.setter - def html_description(self, html_description): - """Sets the html_description of this TeamRequest. - - The description of the team with formatting as HTML. # noqa: E501 - - :param html_description: The html_description of this TeamRequest. # noqa: E501 - :type: str - """ - - self._html_description = html_description - - @property - def organization(self): - """Gets the organization of this TeamRequest. # noqa: E501 - - The organization/workspace the team belongs to. This must be the same organization you are in and cannot be changed once set. # noqa: E501 - - :return: The organization of this TeamRequest. # noqa: E501 - :rtype: str - """ - return self._organization - - @organization.setter - def organization(self, organization): - """Sets the organization of this TeamRequest. - - The organization/workspace the team belongs to. This must be the same organization you are in and cannot be changed once set. # noqa: E501 - - :param organization: The organization of this TeamRequest. # noqa: E501 - :type: str - """ - - self._organization = organization - - @property - def visibility(self): - """Gets the visibility of this TeamRequest. # noqa: E501 - - The visibility of the team to users in the same organization # noqa: E501 - - :return: The visibility of this TeamRequest. # noqa: E501 - :rtype: str - """ - return self._visibility - - @visibility.setter - def visibility(self, visibility): - """Sets the visibility of this TeamRequest. - - The visibility of the team to users in the same organization # noqa: E501 - - :param visibility: The visibility of this TeamRequest. # noqa: E501 - :type: str - """ - allowed_values = ["secret", "request_to_join", "public"] # noqa: E501 - if visibility not in allowed_values: - raise ValueError( - "Invalid value for `visibility` ({0}), must be one of {1}" # noqa: E501 - .format(visibility, allowed_values) - ) - - self._visibility = visibility - - @property - def edit_team_name_or_description_access_level(self): - """Gets the edit_team_name_or_description_access_level of this TeamRequest. # noqa: E501 - - Controls who can edit team name and description # noqa: E501 - - :return: The edit_team_name_or_description_access_level of this TeamRequest. # noqa: E501 - :rtype: str - """ - return self._edit_team_name_or_description_access_level - - @edit_team_name_or_description_access_level.setter - def edit_team_name_or_description_access_level(self, edit_team_name_or_description_access_level): - """Sets the edit_team_name_or_description_access_level of this TeamRequest. - - Controls who can edit team name and description # noqa: E501 - - :param edit_team_name_or_description_access_level: The edit_team_name_or_description_access_level of this TeamRequest. # noqa: E501 - :type: str - """ - allowed_values = ["all_team_members", "only_team_admins"] # noqa: E501 - if edit_team_name_or_description_access_level not in allowed_values: - raise ValueError( - "Invalid value for `edit_team_name_or_description_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(edit_team_name_or_description_access_level, allowed_values) - ) - - self._edit_team_name_or_description_access_level = edit_team_name_or_description_access_level - - @property - def edit_team_visibility_or_trash_team_access_level(self): - """Gets the edit_team_visibility_or_trash_team_access_level of this TeamRequest. # noqa: E501 - - Controls who can edit team visibility and trash teams # noqa: E501 - - :return: The edit_team_visibility_or_trash_team_access_level of this TeamRequest. # noqa: E501 - :rtype: str - """ - return self._edit_team_visibility_or_trash_team_access_level - - @edit_team_visibility_or_trash_team_access_level.setter - def edit_team_visibility_or_trash_team_access_level(self, edit_team_visibility_or_trash_team_access_level): - """Sets the edit_team_visibility_or_trash_team_access_level of this TeamRequest. - - Controls who can edit team visibility and trash teams # noqa: E501 - - :param edit_team_visibility_or_trash_team_access_level: The edit_team_visibility_or_trash_team_access_level of this TeamRequest. # noqa: E501 - :type: str - """ - allowed_values = ["all_team_members", "only_team_admins"] # noqa: E501 - if edit_team_visibility_or_trash_team_access_level not in allowed_values: - raise ValueError( - "Invalid value for `edit_team_visibility_or_trash_team_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(edit_team_visibility_or_trash_team_access_level, allowed_values) - ) - - self._edit_team_visibility_or_trash_team_access_level = edit_team_visibility_or_trash_team_access_level - - @property - def member_invite_management_access_level(self): - """Gets the member_invite_management_access_level of this TeamRequest. # noqa: E501 - - Controls who can accept or deny member invites for a given team # noqa: E501 - - :return: The member_invite_management_access_level of this TeamRequest. # noqa: E501 - :rtype: str - """ - return self._member_invite_management_access_level - - @member_invite_management_access_level.setter - def member_invite_management_access_level(self, member_invite_management_access_level): - """Sets the member_invite_management_access_level of this TeamRequest. - - Controls who can accept or deny member invites for a given team # noqa: E501 - - :param member_invite_management_access_level: The member_invite_management_access_level of this TeamRequest. # noqa: E501 - :type: str - """ - allowed_values = ["all_team_members", "only_team_admins"] # noqa: E501 - if member_invite_management_access_level not in allowed_values: - raise ValueError( - "Invalid value for `member_invite_management_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(member_invite_management_access_level, allowed_values) - ) - - self._member_invite_management_access_level = member_invite_management_access_level - - @property - def guest_invite_management_access_level(self): - """Gets the guest_invite_management_access_level of this TeamRequest. # noqa: E501 - - Controls who can accept or deny guest invites for a given team # noqa: E501 - - :return: The guest_invite_management_access_level of this TeamRequest. # noqa: E501 - :rtype: str - """ - return self._guest_invite_management_access_level - - @guest_invite_management_access_level.setter - def guest_invite_management_access_level(self, guest_invite_management_access_level): - """Sets the guest_invite_management_access_level of this TeamRequest. - - Controls who can accept or deny guest invites for a given team # noqa: E501 - - :param guest_invite_management_access_level: The guest_invite_management_access_level of this TeamRequest. # noqa: E501 - :type: str - """ - allowed_values = ["all_team_members", "only_team_admins"] # noqa: E501 - if guest_invite_management_access_level not in allowed_values: - raise ValueError( - "Invalid value for `guest_invite_management_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(guest_invite_management_access_level, allowed_values) - ) - - self._guest_invite_management_access_level = guest_invite_management_access_level - - @property - def join_request_management_access_level(self): - """Gets the join_request_management_access_level of this TeamRequest. # noqa: E501 - - Controls who can accept or deny join team requests for a Membership by Request team # noqa: E501 - - :return: The join_request_management_access_level of this TeamRequest. # noqa: E501 - :rtype: str - """ - return self._join_request_management_access_level - - @join_request_management_access_level.setter - def join_request_management_access_level(self, join_request_management_access_level): - """Sets the join_request_management_access_level of this TeamRequest. - - Controls who can accept or deny join team requests for a Membership by Request team # noqa: E501 - - :param join_request_management_access_level: The join_request_management_access_level of this TeamRequest. # noqa: E501 - :type: str - """ - allowed_values = ["all_team_members", "only_team_admins"] # noqa: E501 - if join_request_management_access_level not in allowed_values: - raise ValueError( - "Invalid value for `join_request_management_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(join_request_management_access_level, allowed_values) - ) - - self._join_request_management_access_level = join_request_management_access_level - - @property - def team_member_removal_access_level(self): - """Gets the team_member_removal_access_level of this TeamRequest. # noqa: E501 - - Controls who can remove team members # noqa: E501 - - :return: The team_member_removal_access_level of this TeamRequest. # noqa: E501 - :rtype: str - """ - return self._team_member_removal_access_level - - @team_member_removal_access_level.setter - def team_member_removal_access_level(self, team_member_removal_access_level): - """Sets the team_member_removal_access_level of this TeamRequest. - - Controls who can remove team members # noqa: E501 - - :param team_member_removal_access_level: The team_member_removal_access_level of this TeamRequest. # noqa: E501 - :type: str - """ - allowed_values = ["all_team_members", "only_team_admins"] # noqa: E501 - if team_member_removal_access_level not in allowed_values: - raise ValueError( - "Invalid value for `team_member_removal_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(team_member_removal_access_level, allowed_values) - ) - - self._team_member_removal_access_level = team_member_removal_access_level - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_response.py b/asana/models/team_response.py deleted file mode 100644 index 0a761e64..00000000 --- a/asana/models/team_response.py +++ /dev/null @@ -1,516 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'description': 'str', - 'html_description': 'str', - 'organization': 'TeamResponseOrganization', - 'permalink_url': 'str', - 'visibility': 'str', - 'edit_team_name_or_description_access_level': 'str', - 'edit_team_visibility_or_trash_team_access_level': 'str', - 'member_invite_management_access_level': 'str', - 'guest_invite_management_access_level': 'str', - 'join_request_management_access_level': 'str', - 'team_member_removal_access_level': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'description': 'description', - 'html_description': 'html_description', - 'organization': 'organization', - 'permalink_url': 'permalink_url', - 'visibility': 'visibility', - 'edit_team_name_or_description_access_level': 'edit_team_name_or_description_access_level', - 'edit_team_visibility_or_trash_team_access_level': 'edit_team_visibility_or_trash_team_access_level', - 'member_invite_management_access_level': 'member_invite_management_access_level', - 'guest_invite_management_access_level': 'guest_invite_management_access_level', - 'join_request_management_access_level': 'join_request_management_access_level', - 'team_member_removal_access_level': 'team_member_removal_access_level' - } - - def __init__(self, gid=None, resource_type=None, name=None, description=None, html_description=None, organization=None, permalink_url=None, visibility=None, edit_team_name_or_description_access_level=None, edit_team_visibility_or_trash_team_access_level=None, member_invite_management_access_level=None, guest_invite_management_access_level=None, join_request_management_access_level=None, team_member_removal_access_level=None): # noqa: E501 - """TeamResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._description = None - self._html_description = None - self._organization = None - self._permalink_url = None - self._visibility = None - self._edit_team_name_or_description_access_level = None - self._edit_team_visibility_or_trash_team_access_level = None - self._member_invite_management_access_level = None - self._guest_invite_management_access_level = None - self._join_request_management_access_level = None - self._team_member_removal_access_level = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if description is not None: - self.description = description - if html_description is not None: - self.html_description = html_description - if organization is not None: - self.organization = organization - if permalink_url is not None: - self.permalink_url = permalink_url - if visibility is not None: - self.visibility = visibility - if edit_team_name_or_description_access_level is not None: - self.edit_team_name_or_description_access_level = edit_team_name_or_description_access_level - if edit_team_visibility_or_trash_team_access_level is not None: - self.edit_team_visibility_or_trash_team_access_level = edit_team_visibility_or_trash_team_access_level - if member_invite_management_access_level is not None: - self.member_invite_management_access_level = member_invite_management_access_level - if guest_invite_management_access_level is not None: - self.guest_invite_management_access_level = guest_invite_management_access_level - if join_request_management_access_level is not None: - self.join_request_management_access_level = join_request_management_access_level - if team_member_removal_access_level is not None: - self.team_member_removal_access_level = team_member_removal_access_level - - @property - def gid(self): - """Gets the gid of this TeamResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TeamResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TeamResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TeamResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TeamResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TeamResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TeamResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TeamResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TeamResponse. # noqa: E501 - - The name of the team. # noqa: E501 - - :return: The name of this TeamResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TeamResponse. - - The name of the team. # noqa: E501 - - :param name: The name of this TeamResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def description(self): - """Gets the description of this TeamResponse. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The description of the team. # noqa: E501 - - :return: The description of this TeamResponse. # noqa: E501 - :rtype: str - """ - return self._description - - @description.setter - def description(self, description): - """Sets the description of this TeamResponse. - - [Opt In](/docs/inputoutput-options). The description of the team. # noqa: E501 - - :param description: The description of this TeamResponse. # noqa: E501 - :type: str - """ - - self._description = description - - @property - def html_description(self): - """Gets the html_description of this TeamResponse. # noqa: E501 - - [Opt In](/docs/inputoutput-options). The description of the team with formatting as HTML. # noqa: E501 - - :return: The html_description of this TeamResponse. # noqa: E501 - :rtype: str - """ - return self._html_description - - @html_description.setter - def html_description(self, html_description): - """Sets the html_description of this TeamResponse. - - [Opt In](/docs/inputoutput-options). The description of the team with formatting as HTML. # noqa: E501 - - :param html_description: The html_description of this TeamResponse. # noqa: E501 - :type: str - """ - - self._html_description = html_description - - @property - def organization(self): - """Gets the organization of this TeamResponse. # noqa: E501 - - - :return: The organization of this TeamResponse. # noqa: E501 - :rtype: TeamResponseOrganization - """ - return self._organization - - @organization.setter - def organization(self, organization): - """Sets the organization of this TeamResponse. - - - :param organization: The organization of this TeamResponse. # noqa: E501 - :type: TeamResponseOrganization - """ - - self._organization = organization - - @property - def permalink_url(self): - """Gets the permalink_url of this TeamResponse. # noqa: E501 - - A url that points directly to the object within Asana. # noqa: E501 - - :return: The permalink_url of this TeamResponse. # noqa: E501 - :rtype: str - """ - return self._permalink_url - - @permalink_url.setter - def permalink_url(self, permalink_url): - """Sets the permalink_url of this TeamResponse. - - A url that points directly to the object within Asana. # noqa: E501 - - :param permalink_url: The permalink_url of this TeamResponse. # noqa: E501 - :type: str - """ - - self._permalink_url = permalink_url - - @property - def visibility(self): - """Gets the visibility of this TeamResponse. # noqa: E501 - - The visibility of the team to users in the same organization # noqa: E501 - - :return: The visibility of this TeamResponse. # noqa: E501 - :rtype: str - """ - return self._visibility - - @visibility.setter - def visibility(self, visibility): - """Sets the visibility of this TeamResponse. - - The visibility of the team to users in the same organization # noqa: E501 - - :param visibility: The visibility of this TeamResponse. # noqa: E501 - :type: str - """ - allowed_values = ["secret", "request_to_join", "public"] # noqa: E501 - if visibility not in allowed_values: - raise ValueError( - "Invalid value for `visibility` ({0}), must be one of {1}" # noqa: E501 - .format(visibility, allowed_values) - ) - - self._visibility = visibility - - @property - def edit_team_name_or_description_access_level(self): - """Gets the edit_team_name_or_description_access_level of this TeamResponse. # noqa: E501 - - Controls who can edit team name and description # noqa: E501 - - :return: The edit_team_name_or_description_access_level of this TeamResponse. # noqa: E501 - :rtype: str - """ - return self._edit_team_name_or_description_access_level - - @edit_team_name_or_description_access_level.setter - def edit_team_name_or_description_access_level(self, edit_team_name_or_description_access_level): - """Sets the edit_team_name_or_description_access_level of this TeamResponse. - - Controls who can edit team name and description # noqa: E501 - - :param edit_team_name_or_description_access_level: The edit_team_name_or_description_access_level of this TeamResponse. # noqa: E501 - :type: str - """ - allowed_values = ["all_team_members", "only_team_admins"] # noqa: E501 - if edit_team_name_or_description_access_level not in allowed_values: - raise ValueError( - "Invalid value for `edit_team_name_or_description_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(edit_team_name_or_description_access_level, allowed_values) - ) - - self._edit_team_name_or_description_access_level = edit_team_name_or_description_access_level - - @property - def edit_team_visibility_or_trash_team_access_level(self): - """Gets the edit_team_visibility_or_trash_team_access_level of this TeamResponse. # noqa: E501 - - Controls who can edit team visibility and trash teams # noqa: E501 - - :return: The edit_team_visibility_or_trash_team_access_level of this TeamResponse. # noqa: E501 - :rtype: str - """ - return self._edit_team_visibility_or_trash_team_access_level - - @edit_team_visibility_or_trash_team_access_level.setter - def edit_team_visibility_or_trash_team_access_level(self, edit_team_visibility_or_trash_team_access_level): - """Sets the edit_team_visibility_or_trash_team_access_level of this TeamResponse. - - Controls who can edit team visibility and trash teams # noqa: E501 - - :param edit_team_visibility_or_trash_team_access_level: The edit_team_visibility_or_trash_team_access_level of this TeamResponse. # noqa: E501 - :type: str - """ - allowed_values = ["all_team_members", "only_team_admins"] # noqa: E501 - if edit_team_visibility_or_trash_team_access_level not in allowed_values: - raise ValueError( - "Invalid value for `edit_team_visibility_or_trash_team_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(edit_team_visibility_or_trash_team_access_level, allowed_values) - ) - - self._edit_team_visibility_or_trash_team_access_level = edit_team_visibility_or_trash_team_access_level - - @property - def member_invite_management_access_level(self): - """Gets the member_invite_management_access_level of this TeamResponse. # noqa: E501 - - Controls who can accept or deny member invites for a given team # noqa: E501 - - :return: The member_invite_management_access_level of this TeamResponse. # noqa: E501 - :rtype: str - """ - return self._member_invite_management_access_level - - @member_invite_management_access_level.setter - def member_invite_management_access_level(self, member_invite_management_access_level): - """Sets the member_invite_management_access_level of this TeamResponse. - - Controls who can accept or deny member invites for a given team # noqa: E501 - - :param member_invite_management_access_level: The member_invite_management_access_level of this TeamResponse. # noqa: E501 - :type: str - """ - allowed_values = ["all_team_members", "only_team_admins"] # noqa: E501 - if member_invite_management_access_level not in allowed_values: - raise ValueError( - "Invalid value for `member_invite_management_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(member_invite_management_access_level, allowed_values) - ) - - self._member_invite_management_access_level = member_invite_management_access_level - - @property - def guest_invite_management_access_level(self): - """Gets the guest_invite_management_access_level of this TeamResponse. # noqa: E501 - - Controls who can accept or deny guest invites for a given team # noqa: E501 - - :return: The guest_invite_management_access_level of this TeamResponse. # noqa: E501 - :rtype: str - """ - return self._guest_invite_management_access_level - - @guest_invite_management_access_level.setter - def guest_invite_management_access_level(self, guest_invite_management_access_level): - """Sets the guest_invite_management_access_level of this TeamResponse. - - Controls who can accept or deny guest invites for a given team # noqa: E501 - - :param guest_invite_management_access_level: The guest_invite_management_access_level of this TeamResponse. # noqa: E501 - :type: str - """ - allowed_values = ["all_team_members", "only_team_admins"] # noqa: E501 - if guest_invite_management_access_level not in allowed_values: - raise ValueError( - "Invalid value for `guest_invite_management_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(guest_invite_management_access_level, allowed_values) - ) - - self._guest_invite_management_access_level = guest_invite_management_access_level - - @property - def join_request_management_access_level(self): - """Gets the join_request_management_access_level of this TeamResponse. # noqa: E501 - - Controls who can accept or deny join team requests for a Membership by Request team # noqa: E501 - - :return: The join_request_management_access_level of this TeamResponse. # noqa: E501 - :rtype: str - """ - return self._join_request_management_access_level - - @join_request_management_access_level.setter - def join_request_management_access_level(self, join_request_management_access_level): - """Sets the join_request_management_access_level of this TeamResponse. - - Controls who can accept or deny join team requests for a Membership by Request team # noqa: E501 - - :param join_request_management_access_level: The join_request_management_access_level of this TeamResponse. # noqa: E501 - :type: str - """ - allowed_values = ["all_team_members", "only_team_admins"] # noqa: E501 - if join_request_management_access_level not in allowed_values: - raise ValueError( - "Invalid value for `join_request_management_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(join_request_management_access_level, allowed_values) - ) - - self._join_request_management_access_level = join_request_management_access_level - - @property - def team_member_removal_access_level(self): - """Gets the team_member_removal_access_level of this TeamResponse. # noqa: E501 - - Controls who can remove team members # noqa: E501 - - :return: The team_member_removal_access_level of this TeamResponse. # noqa: E501 - :rtype: str - """ - return self._team_member_removal_access_level - - @team_member_removal_access_level.setter - def team_member_removal_access_level(self, team_member_removal_access_level): - """Sets the team_member_removal_access_level of this TeamResponse. - - Controls who can remove team members # noqa: E501 - - :param team_member_removal_access_level: The team_member_removal_access_level of this TeamResponse. # noqa: E501 - :type: str - """ - allowed_values = ["all_team_members", "only_team_admins"] # noqa: E501 - if team_member_removal_access_level not in allowed_values: - raise ValueError( - "Invalid value for `team_member_removal_access_level` ({0}), must be one of {1}" # noqa: E501 - .format(team_member_removal_access_level, allowed_values) - ) - - self._team_member_removal_access_level = team_member_removal_access_level - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_response_array.py b/asana/models/team_response_array.py deleted file mode 100644 index a00dee6b..00000000 --- a/asana/models/team_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[TeamResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """TeamResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this TeamResponseArray. # noqa: E501 - - - :return: The data of this TeamResponseArray. # noqa: E501 - :rtype: list[TeamResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TeamResponseArray. - - - :param data: The data of this TeamResponseArray. # noqa: E501 - :type: list[TeamResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this TeamResponseArray. # noqa: E501 - - - :return: The next_page of this TeamResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this TeamResponseArray. - - - :param next_page: The next_page of this TeamResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_response_data.py b/asana/models/team_response_data.py deleted file mode 100644 index 20c51b37..00000000 --- a/asana/models/team_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TeamResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TeamResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this TeamResponseData. # noqa: E501 - - - :return: The data of this TeamResponseData. # noqa: E501 - :rtype: TeamResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TeamResponseData. - - - :param data: The data of this TeamResponseData. # noqa: E501 - :type: TeamResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/team_response_organization.py b/asana/models/team_response_organization.py deleted file mode 100644 index 8a279d67..00000000 --- a/asana/models/team_response_organization.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamResponseOrganization(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """TeamResponseOrganization - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this TeamResponseOrganization. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TeamResponseOrganization. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TeamResponseOrganization. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TeamResponseOrganization. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TeamResponseOrganization. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TeamResponseOrganization. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TeamResponseOrganization. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TeamResponseOrganization. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TeamResponseOrganization. # noqa: E501 - - The name of the workspace. # noqa: E501 - - :return: The name of this TeamResponseOrganization. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TeamResponseOrganization. - - The name of the workspace. # noqa: E501 - - :param name: The name of this TeamResponseOrganization. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamResponseOrganization, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamResponseOrganization): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/teams_body.py b/asana/models/teams_body.py deleted file mode 100644 index 1de83684..00000000 --- a/asana/models/teams_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TeamRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TeamsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TeamsBody. # noqa: E501 - - - :return: The data of this TeamsBody. # noqa: E501 - :rtype: TeamRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TeamsBody. - - - :param data: The data of this TeamsBody. # noqa: E501 - :type: TeamRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/teams_team_gid_body.py b/asana/models/teams_team_gid_body.py deleted file mode 100644 index 8a48054b..00000000 --- a/asana/models/teams_team_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TeamsTeamGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TeamRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TeamsTeamGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TeamsTeamGidBody. # noqa: E501 - - - :return: The data of this TeamsTeamGidBody. # noqa: E501 - :rtype: TeamRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TeamsTeamGidBody. - - - :param data: The data of this TeamsTeamGidBody. # noqa: E501 - :type: TeamRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TeamsTeamGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TeamsTeamGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/template_role.py b/asana/models/template_role.py deleted file mode 100644 index 38dfdeb2..00000000 --- a/asana/models/template_role.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TemplateRole(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """TemplateRole - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this TemplateRole. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TemplateRole. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TemplateRole. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TemplateRole. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TemplateRole. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TemplateRole. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TemplateRole. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TemplateRole. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this TemplateRole. # noqa: E501 - - Name of the template role. # noqa: E501 - - :return: The name of this TemplateRole. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this TemplateRole. - - Name of the template role. # noqa: E501 - - :param name: The name of this TemplateRole. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TemplateRole, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TemplateRole): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/time_period_base.py b/asana/models/time_period_base.py deleted file mode 100644 index 6f179193..00000000 --- a/asana/models/time_period_base.py +++ /dev/null @@ -1,284 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TimePeriodBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'end_on': 'str', - 'start_on': 'str', - 'period': 'str', - 'display_name': 'str', - 'parent': 'GoalResponseTimePeriod' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'end_on': 'end_on', - 'start_on': 'start_on', - 'period': 'period', - 'display_name': 'display_name', - 'parent': 'parent' - } - - def __init__(self, gid=None, resource_type=None, end_on=None, start_on=None, period=None, display_name=None, parent=None): # noqa: E501 - """TimePeriodBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._end_on = None - self._start_on = None - self._period = None - self._display_name = None - self._parent = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if end_on is not None: - self.end_on = end_on - if start_on is not None: - self.start_on = start_on - if period is not None: - self.period = period - if display_name is not None: - self.display_name = display_name - if parent is not None: - self.parent = parent - - @property - def gid(self): - """Gets the gid of this TimePeriodBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TimePeriodBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TimePeriodBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TimePeriodBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TimePeriodBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TimePeriodBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TimePeriodBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TimePeriodBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def end_on(self): - """Gets the end_on of this TimePeriodBase. # noqa: E501 - - The localized end date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :return: The end_on of this TimePeriodBase. # noqa: E501 - :rtype: str - """ - return self._end_on - - @end_on.setter - def end_on(self, end_on): - """Sets the end_on of this TimePeriodBase. - - The localized end date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :param end_on: The end_on of this TimePeriodBase. # noqa: E501 - :type: str - """ - - self._end_on = end_on - - @property - def start_on(self): - """Gets the start_on of this TimePeriodBase. # noqa: E501 - - The localized start date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :return: The start_on of this TimePeriodBase. # noqa: E501 - :rtype: str - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this TimePeriodBase. - - The localized start date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :param start_on: The start_on of this TimePeriodBase. # noqa: E501 - :type: str - """ - - self._start_on = start_on - - @property - def period(self): - """Gets the period of this TimePeriodBase. # noqa: E501 - - The cadence and index of the time period. The value is one of: `FY`, `H1`, `H2`, `Q1`, `Q2`, `Q3`, or `Q4`. # noqa: E501 - - :return: The period of this TimePeriodBase. # noqa: E501 - :rtype: str - """ - return self._period - - @period.setter - def period(self, period): - """Sets the period of this TimePeriodBase. - - The cadence and index of the time period. The value is one of: `FY`, `H1`, `H2`, `Q1`, `Q2`, `Q3`, or `Q4`. # noqa: E501 - - :param period: The period of this TimePeriodBase. # noqa: E501 - :type: str - """ - allowed_values = ["FY", "H1", "H2", "Q1", "Q2", "Q3", "Q4"] # noqa: E501 - if period not in allowed_values: - raise ValueError( - "Invalid value for `period` ({0}), must be one of {1}" # noqa: E501 - .format(period, allowed_values) - ) - - self._period = period - - @property - def display_name(self): - """Gets the display_name of this TimePeriodBase. # noqa: E501 - - A string representing the cadence code and the fiscal year. # noqa: E501 - - :return: The display_name of this TimePeriodBase. # noqa: E501 - :rtype: str - """ - return self._display_name - - @display_name.setter - def display_name(self, display_name): - """Sets the display_name of this TimePeriodBase. - - A string representing the cadence code and the fiscal year. # noqa: E501 - - :param display_name: The display_name of this TimePeriodBase. # noqa: E501 - :type: str - """ - - self._display_name = display_name - - @property - def parent(self): - """Gets the parent of this TimePeriodBase. # noqa: E501 - - - :return: The parent of this TimePeriodBase. # noqa: E501 - :rtype: GoalResponseTimePeriod - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this TimePeriodBase. - - - :param parent: The parent of this TimePeriodBase. # noqa: E501 - :type: GoalResponseTimePeriod - """ - - self._parent = parent - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TimePeriodBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TimePeriodBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/time_period_compact.py b/asana/models/time_period_compact.py deleted file mode 100644 index 09f8ea66..00000000 --- a/asana/models/time_period_compact.py +++ /dev/null @@ -1,258 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TimePeriodCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'end_on': 'str', - 'start_on': 'str', - 'period': 'str', - 'display_name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'end_on': 'end_on', - 'start_on': 'start_on', - 'period': 'period', - 'display_name': 'display_name' - } - - def __init__(self, gid=None, resource_type=None, end_on=None, start_on=None, period=None, display_name=None): # noqa: E501 - """TimePeriodCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._end_on = None - self._start_on = None - self._period = None - self._display_name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if end_on is not None: - self.end_on = end_on - if start_on is not None: - self.start_on = start_on - if period is not None: - self.period = period - if display_name is not None: - self.display_name = display_name - - @property - def gid(self): - """Gets the gid of this TimePeriodCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TimePeriodCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TimePeriodCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TimePeriodCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TimePeriodCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TimePeriodCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TimePeriodCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TimePeriodCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def end_on(self): - """Gets the end_on of this TimePeriodCompact. # noqa: E501 - - The localized end date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :return: The end_on of this TimePeriodCompact. # noqa: E501 - :rtype: str - """ - return self._end_on - - @end_on.setter - def end_on(self, end_on): - """Sets the end_on of this TimePeriodCompact. - - The localized end date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :param end_on: The end_on of this TimePeriodCompact. # noqa: E501 - :type: str - """ - - self._end_on = end_on - - @property - def start_on(self): - """Gets the start_on of this TimePeriodCompact. # noqa: E501 - - The localized start date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :return: The start_on of this TimePeriodCompact. # noqa: E501 - :rtype: str - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this TimePeriodCompact. - - The localized start date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :param start_on: The start_on of this TimePeriodCompact. # noqa: E501 - :type: str - """ - - self._start_on = start_on - - @property - def period(self): - """Gets the period of this TimePeriodCompact. # noqa: E501 - - The cadence and index of the time period. The value is one of: `FY`, `H1`, `H2`, `Q1`, `Q2`, `Q3`, or `Q4`. # noqa: E501 - - :return: The period of this TimePeriodCompact. # noqa: E501 - :rtype: str - """ - return self._period - - @period.setter - def period(self, period): - """Sets the period of this TimePeriodCompact. - - The cadence and index of the time period. The value is one of: `FY`, `H1`, `H2`, `Q1`, `Q2`, `Q3`, or `Q4`. # noqa: E501 - - :param period: The period of this TimePeriodCompact. # noqa: E501 - :type: str - """ - allowed_values = ["FY", "H1", "H2", "Q1", "Q2", "Q3", "Q4"] # noqa: E501 - if period not in allowed_values: - raise ValueError( - "Invalid value for `period` ({0}), must be one of {1}" # noqa: E501 - .format(period, allowed_values) - ) - - self._period = period - - @property - def display_name(self): - """Gets the display_name of this TimePeriodCompact. # noqa: E501 - - A string representing the cadence code and the fiscal year. # noqa: E501 - - :return: The display_name of this TimePeriodCompact. # noqa: E501 - :rtype: str - """ - return self._display_name - - @display_name.setter - def display_name(self, display_name): - """Sets the display_name of this TimePeriodCompact. - - A string representing the cadence code and the fiscal year. # noqa: E501 - - :param display_name: The display_name of this TimePeriodCompact. # noqa: E501 - :type: str - """ - - self._display_name = display_name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TimePeriodCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TimePeriodCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/time_period_response.py b/asana/models/time_period_response.py deleted file mode 100644 index c704fef6..00000000 --- a/asana/models/time_period_response.py +++ /dev/null @@ -1,284 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TimePeriodResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'end_on': 'str', - 'start_on': 'str', - 'period': 'str', - 'display_name': 'str', - 'parent': 'GoalResponseTimePeriod' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'end_on': 'end_on', - 'start_on': 'start_on', - 'period': 'period', - 'display_name': 'display_name', - 'parent': 'parent' - } - - def __init__(self, gid=None, resource_type=None, end_on=None, start_on=None, period=None, display_name=None, parent=None): # noqa: E501 - """TimePeriodResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._end_on = None - self._start_on = None - self._period = None - self._display_name = None - self._parent = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if end_on is not None: - self.end_on = end_on - if start_on is not None: - self.start_on = start_on - if period is not None: - self.period = period - if display_name is not None: - self.display_name = display_name - if parent is not None: - self.parent = parent - - @property - def gid(self): - """Gets the gid of this TimePeriodResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TimePeriodResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TimePeriodResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TimePeriodResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TimePeriodResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TimePeriodResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TimePeriodResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TimePeriodResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def end_on(self): - """Gets the end_on of this TimePeriodResponse. # noqa: E501 - - The localized end date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :return: The end_on of this TimePeriodResponse. # noqa: E501 - :rtype: str - """ - return self._end_on - - @end_on.setter - def end_on(self, end_on): - """Sets the end_on of this TimePeriodResponse. - - The localized end date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :param end_on: The end_on of this TimePeriodResponse. # noqa: E501 - :type: str - """ - - self._end_on = end_on - - @property - def start_on(self): - """Gets the start_on of this TimePeriodResponse. # noqa: E501 - - The localized start date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :return: The start_on of this TimePeriodResponse. # noqa: E501 - :rtype: str - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this TimePeriodResponse. - - The localized start date of the time period in `YYYY-MM-DD` format. # noqa: E501 - - :param start_on: The start_on of this TimePeriodResponse. # noqa: E501 - :type: str - """ - - self._start_on = start_on - - @property - def period(self): - """Gets the period of this TimePeriodResponse. # noqa: E501 - - The cadence and index of the time period. The value is one of: `FY`, `H1`, `H2`, `Q1`, `Q2`, `Q3`, or `Q4`. # noqa: E501 - - :return: The period of this TimePeriodResponse. # noqa: E501 - :rtype: str - """ - return self._period - - @period.setter - def period(self, period): - """Sets the period of this TimePeriodResponse. - - The cadence and index of the time period. The value is one of: `FY`, `H1`, `H2`, `Q1`, `Q2`, `Q3`, or `Q4`. # noqa: E501 - - :param period: The period of this TimePeriodResponse. # noqa: E501 - :type: str - """ - allowed_values = ["FY", "H1", "H2", "Q1", "Q2", "Q3", "Q4"] # noqa: E501 - if period not in allowed_values: - raise ValueError( - "Invalid value for `period` ({0}), must be one of {1}" # noqa: E501 - .format(period, allowed_values) - ) - - self._period = period - - @property - def display_name(self): - """Gets the display_name of this TimePeriodResponse. # noqa: E501 - - A string representing the cadence code and the fiscal year. # noqa: E501 - - :return: The display_name of this TimePeriodResponse. # noqa: E501 - :rtype: str - """ - return self._display_name - - @display_name.setter - def display_name(self, display_name): - """Sets the display_name of this TimePeriodResponse. - - A string representing the cadence code and the fiscal year. # noqa: E501 - - :param display_name: The display_name of this TimePeriodResponse. # noqa: E501 - :type: str - """ - - self._display_name = display_name - - @property - def parent(self): - """Gets the parent of this TimePeriodResponse. # noqa: E501 - - - :return: The parent of this TimePeriodResponse. # noqa: E501 - :rtype: GoalResponseTimePeriod - """ - return self._parent - - @parent.setter - def parent(self, parent): - """Sets the parent of this TimePeriodResponse. - - - :param parent: The parent of this TimePeriodResponse. # noqa: E501 - :type: GoalResponseTimePeriod - """ - - self._parent = parent - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TimePeriodResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TimePeriodResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/time_period_response_array.py b/asana/models/time_period_response_array.py deleted file mode 100644 index 8af51aa2..00000000 --- a/asana/models/time_period_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TimePeriodResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[TimePeriodResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """TimePeriodResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this TimePeriodResponseArray. # noqa: E501 - - - :return: The data of this TimePeriodResponseArray. # noqa: E501 - :rtype: list[TimePeriodResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TimePeriodResponseArray. - - - :param data: The data of this TimePeriodResponseArray. # noqa: E501 - :type: list[TimePeriodResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this TimePeriodResponseArray. # noqa: E501 - - - :return: The next_page of this TimePeriodResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this TimePeriodResponseArray. - - - :param next_page: The next_page of this TimePeriodResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TimePeriodResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TimePeriodResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/time_period_response_data.py b/asana/models/time_period_response_data.py deleted file mode 100644 index 4537cffe..00000000 --- a/asana/models/time_period_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TimePeriodResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TimePeriodResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TimePeriodResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this TimePeriodResponseData. # noqa: E501 - - - :return: The data of this TimePeriodResponseData. # noqa: E501 - :rtype: TimePeriodResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TimePeriodResponseData. - - - :param data: The data of this TimePeriodResponseData. # noqa: E501 - :type: TimePeriodResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TimePeriodResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TimePeriodResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/time_tracking_entries_time_tracking_entry_gid_body.py b/asana/models/time_tracking_entries_time_tracking_entry_gid_body.py deleted file mode 100644 index 7671f89b..00000000 --- a/asana/models/time_tracking_entries_time_tracking_entry_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TimeTrackingEntriesTimeTrackingEntryGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'UpdateTimeTrackingEntryRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TimeTrackingEntriesTimeTrackingEntryGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this TimeTrackingEntriesTimeTrackingEntryGidBody. # noqa: E501 - - - :return: The data of this TimeTrackingEntriesTimeTrackingEntryGidBody. # noqa: E501 - :rtype: UpdateTimeTrackingEntryRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TimeTrackingEntriesTimeTrackingEntryGidBody. - - - :param data: The data of this TimeTrackingEntriesTimeTrackingEntryGidBody. # noqa: E501 - :type: UpdateTimeTrackingEntryRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TimeTrackingEntriesTimeTrackingEntryGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TimeTrackingEntriesTimeTrackingEntryGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/time_tracking_entry_base.py b/asana/models/time_tracking_entry_base.py deleted file mode 100644 index d15af2a1..00000000 --- a/asana/models/time_tracking_entry_base.py +++ /dev/null @@ -1,276 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TimeTrackingEntryBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'duration_minutes': 'int', - 'entered_on': 'date', - 'created_by': 'StoryResponseAssignee', - 'task': 'StoryResponseTask', - 'created_at': 'datetime' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'duration_minutes': 'duration_minutes', - 'entered_on': 'entered_on', - 'created_by': 'created_by', - 'task': 'task', - 'created_at': 'created_at' - } - - def __init__(self, gid=None, resource_type=None, duration_minutes=None, entered_on=None, created_by=None, task=None, created_at=None): # noqa: E501 - """TimeTrackingEntryBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._duration_minutes = None - self._entered_on = None - self._created_by = None - self._task = None - self._created_at = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if duration_minutes is not None: - self.duration_minutes = duration_minutes - if entered_on is not None: - self.entered_on = entered_on - if created_by is not None: - self.created_by = created_by - if task is not None: - self.task = task - if created_at is not None: - self.created_at = created_at - - @property - def gid(self): - """Gets the gid of this TimeTrackingEntryBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TimeTrackingEntryBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TimeTrackingEntryBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TimeTrackingEntryBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TimeTrackingEntryBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TimeTrackingEntryBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TimeTrackingEntryBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TimeTrackingEntryBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def duration_minutes(self): - """Gets the duration_minutes of this TimeTrackingEntryBase. # noqa: E501 - - Time in minutes tracked by the entry. # noqa: E501 - - :return: The duration_minutes of this TimeTrackingEntryBase. # noqa: E501 - :rtype: int - """ - return self._duration_minutes - - @duration_minutes.setter - def duration_minutes(self, duration_minutes): - """Sets the duration_minutes of this TimeTrackingEntryBase. - - Time in minutes tracked by the entry. # noqa: E501 - - :param duration_minutes: The duration_minutes of this TimeTrackingEntryBase. # noqa: E501 - :type: int - """ - - self._duration_minutes = duration_minutes - - @property - def entered_on(self): - """Gets the entered_on of this TimeTrackingEntryBase. # noqa: E501 - - The day that this entry is logged on. # noqa: E501 - - :return: The entered_on of this TimeTrackingEntryBase. # noqa: E501 - :rtype: date - """ - return self._entered_on - - @entered_on.setter - def entered_on(self, entered_on): - """Sets the entered_on of this TimeTrackingEntryBase. - - The day that this entry is logged on. # noqa: E501 - - :param entered_on: The entered_on of this TimeTrackingEntryBase. # noqa: E501 - :type: date - """ - - self._entered_on = entered_on - - @property - def created_by(self): - """Gets the created_by of this TimeTrackingEntryBase. # noqa: E501 - - - :return: The created_by of this TimeTrackingEntryBase. # noqa: E501 - :rtype: StoryResponseAssignee - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this TimeTrackingEntryBase. - - - :param created_by: The created_by of this TimeTrackingEntryBase. # noqa: E501 - :type: StoryResponseAssignee - """ - - self._created_by = created_by - - @property - def task(self): - """Gets the task of this TimeTrackingEntryBase. # noqa: E501 - - - :return: The task of this TimeTrackingEntryBase. # noqa: E501 - :rtype: StoryResponseTask - """ - return self._task - - @task.setter - def task(self, task): - """Sets the task of this TimeTrackingEntryBase. - - - :param task: The task of this TimeTrackingEntryBase. # noqa: E501 - :type: StoryResponseTask - """ - - self._task = task - - @property - def created_at(self): - """Gets the created_at of this TimeTrackingEntryBase. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this TimeTrackingEntryBase. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this TimeTrackingEntryBase. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this TimeTrackingEntryBase. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TimeTrackingEntryBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TimeTrackingEntryBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/time_tracking_entry_base_data.py b/asana/models/time_tracking_entry_base_data.py deleted file mode 100644 index 690204ae..00000000 --- a/asana/models/time_tracking_entry_base_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TimeTrackingEntryBaseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TimeTrackingEntryBase' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """TimeTrackingEntryBaseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this TimeTrackingEntryBaseData. # noqa: E501 - - - :return: The data of this TimeTrackingEntryBaseData. # noqa: E501 - :rtype: TimeTrackingEntryBase - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TimeTrackingEntryBaseData. - - - :param data: The data of this TimeTrackingEntryBaseData. # noqa: E501 - :type: TimeTrackingEntryBase - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TimeTrackingEntryBaseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TimeTrackingEntryBaseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/time_tracking_entry_compact.py b/asana/models/time_tracking_entry_compact.py deleted file mode 100644 index 45c88443..00000000 --- a/asana/models/time_tracking_entry_compact.py +++ /dev/null @@ -1,222 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TimeTrackingEntryCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'duration_minutes': 'int', - 'entered_on': 'date', - 'created_by': 'StoryResponseAssignee' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'duration_minutes': 'duration_minutes', - 'entered_on': 'entered_on', - 'created_by': 'created_by' - } - - def __init__(self, gid=None, resource_type=None, duration_minutes=None, entered_on=None, created_by=None): # noqa: E501 - """TimeTrackingEntryCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._duration_minutes = None - self._entered_on = None - self._created_by = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if duration_minutes is not None: - self.duration_minutes = duration_minutes - if entered_on is not None: - self.entered_on = entered_on - if created_by is not None: - self.created_by = created_by - - @property - def gid(self): - """Gets the gid of this TimeTrackingEntryCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this TimeTrackingEntryCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this TimeTrackingEntryCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this TimeTrackingEntryCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this TimeTrackingEntryCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this TimeTrackingEntryCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this TimeTrackingEntryCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this TimeTrackingEntryCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def duration_minutes(self): - """Gets the duration_minutes of this TimeTrackingEntryCompact. # noqa: E501 - - Time in minutes tracked by the entry. # noqa: E501 - - :return: The duration_minutes of this TimeTrackingEntryCompact. # noqa: E501 - :rtype: int - """ - return self._duration_minutes - - @duration_minutes.setter - def duration_minutes(self, duration_minutes): - """Sets the duration_minutes of this TimeTrackingEntryCompact. - - Time in minutes tracked by the entry. # noqa: E501 - - :param duration_minutes: The duration_minutes of this TimeTrackingEntryCompact. # noqa: E501 - :type: int - """ - - self._duration_minutes = duration_minutes - - @property - def entered_on(self): - """Gets the entered_on of this TimeTrackingEntryCompact. # noqa: E501 - - The day that this entry is logged on. # noqa: E501 - - :return: The entered_on of this TimeTrackingEntryCompact. # noqa: E501 - :rtype: date - """ - return self._entered_on - - @entered_on.setter - def entered_on(self, entered_on): - """Sets the entered_on of this TimeTrackingEntryCompact. - - The day that this entry is logged on. # noqa: E501 - - :param entered_on: The entered_on of this TimeTrackingEntryCompact. # noqa: E501 - :type: date - """ - - self._entered_on = entered_on - - @property - def created_by(self): - """Gets the created_by of this TimeTrackingEntryCompact. # noqa: E501 - - - :return: The created_by of this TimeTrackingEntryCompact. # noqa: E501 - :rtype: StoryResponseAssignee - """ - return self._created_by - - @created_by.setter - def created_by(self, created_by): - """Sets the created_by of this TimeTrackingEntryCompact. - - - :param created_by: The created_by of this TimeTrackingEntryCompact. # noqa: E501 - :type: StoryResponseAssignee - """ - - self._created_by = created_by - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TimeTrackingEntryCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TimeTrackingEntryCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/time_tracking_entry_compact_array.py b/asana/models/time_tracking_entry_compact_array.py deleted file mode 100644 index f16a9518..00000000 --- a/asana/models/time_tracking_entry_compact_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class TimeTrackingEntryCompactArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[TimeTrackingEntryCompact]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """TimeTrackingEntryCompactArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this TimeTrackingEntryCompactArray. # noqa: E501 - - - :return: The data of this TimeTrackingEntryCompactArray. # noqa: E501 - :rtype: list[TimeTrackingEntryCompact] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this TimeTrackingEntryCompactArray. - - - :param data: The data of this TimeTrackingEntryCompactArray. # noqa: E501 - :type: list[TimeTrackingEntryCompact] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this TimeTrackingEntryCompactArray. # noqa: E501 - - - :return: The next_page of this TimeTrackingEntryCompactArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this TimeTrackingEntryCompactArray. - - - :param next_page: The next_page of this TimeTrackingEntryCompactArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(TimeTrackingEntryCompactArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, TimeTrackingEntryCompactArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/update_time_tracking_entry_request.py b/asana/models/update_time_tracking_entry_request.py deleted file mode 100644 index bac36c29..00000000 --- a/asana/models/update_time_tracking_entry_request.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UpdateTimeTrackingEntryRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'duration_minutes': 'int', - 'entered_on': 'date' - } - - attribute_map = { - 'duration_minutes': 'duration_minutes', - 'entered_on': 'entered_on' - } - - def __init__(self, duration_minutes=None, entered_on=None): # noqa: E501 - """UpdateTimeTrackingEntryRequest - a model defined in Swagger""" # noqa: E501 - self._duration_minutes = None - self._entered_on = None - self.discriminator = None - if duration_minutes is not None: - self.duration_minutes = duration_minutes - if entered_on is not None: - self.entered_on = entered_on - - @property - def duration_minutes(self): - """Gets the duration_minutes of this UpdateTimeTrackingEntryRequest. # noqa: E501 - - *Optional*. Time in minutes tracked by the entry # noqa: E501 - - :return: The duration_minutes of this UpdateTimeTrackingEntryRequest. # noqa: E501 - :rtype: int - """ - return self._duration_minutes - - @duration_minutes.setter - def duration_minutes(self, duration_minutes): - """Sets the duration_minutes of this UpdateTimeTrackingEntryRequest. - - *Optional*. Time in minutes tracked by the entry # noqa: E501 - - :param duration_minutes: The duration_minutes of this UpdateTimeTrackingEntryRequest. # noqa: E501 - :type: int - """ - - self._duration_minutes = duration_minutes - - @property - def entered_on(self): - """Gets the entered_on of this UpdateTimeTrackingEntryRequest. # noqa: E501 - - *Optional*. The day that this entry is logged on. Defaults to today if no day specified # noqa: E501 - - :return: The entered_on of this UpdateTimeTrackingEntryRequest. # noqa: E501 - :rtype: date - """ - return self._entered_on - - @entered_on.setter - def entered_on(self, entered_on): - """Sets the entered_on of this UpdateTimeTrackingEntryRequest. - - *Optional*. The day that this entry is logged on. Defaults to today if no day specified # noqa: E501 - - :param entered_on: The entered_on of this UpdateTimeTrackingEntryRequest. # noqa: E501 - :type: date - """ - - self._entered_on = entered_on - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UpdateTimeTrackingEntryRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UpdateTimeTrackingEntryRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_base.py b/asana/models/user_base.py deleted file mode 100644 index 46c5cfdf..00000000 --- a/asana/models/user_base.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """UserBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this UserBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this UserBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this UserBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this UserBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this UserBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this UserBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this UserBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this UserBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this UserBase. # noqa: E501 - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :return: The name of this UserBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this UserBase. - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :param name: The name of this UserBase. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_base_response.py b/asana/models/user_base_response.py deleted file mode 100644 index 01f74841..00000000 --- a/asana/models/user_base_response.py +++ /dev/null @@ -1,222 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserBaseResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'email': 'str', - 'photo': 'UserBaseResponsePhoto' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'email': 'email', - 'photo': 'photo' - } - - def __init__(self, gid=None, resource_type=None, name=None, email=None, photo=None): # noqa: E501 - """UserBaseResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._email = None - self._photo = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if email is not None: - self.email = email - if photo is not None: - self.photo = photo - - @property - def gid(self): - """Gets the gid of this UserBaseResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this UserBaseResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this UserBaseResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this UserBaseResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this UserBaseResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this UserBaseResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this UserBaseResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this UserBaseResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this UserBaseResponse. # noqa: E501 - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :return: The name of this UserBaseResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this UserBaseResponse. - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :param name: The name of this UserBaseResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def email(self): - """Gets the email of this UserBaseResponse. # noqa: E501 - - The user's email address. # noqa: E501 - - :return: The email of this UserBaseResponse. # noqa: E501 - :rtype: str - """ - return self._email - - @email.setter - def email(self, email): - """Sets the email of this UserBaseResponse. - - The user's email address. # noqa: E501 - - :param email: The email of this UserBaseResponse. # noqa: E501 - :type: str - """ - - self._email = email - - @property - def photo(self): - """Gets the photo of this UserBaseResponse. # noqa: E501 - - - :return: The photo of this UserBaseResponse. # noqa: E501 - :rtype: UserBaseResponsePhoto - """ - return self._photo - - @photo.setter - def photo(self, photo): - """Sets the photo of this UserBaseResponse. - - - :param photo: The photo of this UserBaseResponse. # noqa: E501 - :type: UserBaseResponsePhoto - """ - - self._photo = photo - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserBaseResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserBaseResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_base_response_data.py b/asana/models/user_base_response_data.py deleted file mode 100644 index 5e3687be..00000000 --- a/asana/models/user_base_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserBaseResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'UserBaseResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """UserBaseResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this UserBaseResponseData. # noqa: E501 - - - :return: The data of this UserBaseResponseData. # noqa: E501 - :rtype: UserBaseResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this UserBaseResponseData. - - - :param data: The data of this UserBaseResponseData. # noqa: E501 - :type: UserBaseResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserBaseResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserBaseResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_base_response_photo.py b/asana/models/user_base_response_photo.py deleted file mode 100644 index a7bcb7f5..00000000 --- a/asana/models/user_base_response_photo.py +++ /dev/null @@ -1,240 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserBaseResponsePhoto(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'image_21x21': 'str', - 'image_27x27': 'str', - 'image_36x36': 'str', - 'image_60x60': 'str', - 'image_128x128': 'str', - 'image_1024x1024': 'str' - } - - attribute_map = { - 'image_21x21': 'image_21x21', - 'image_27x27': 'image_27x27', - 'image_36x36': 'image_36x36', - 'image_60x60': 'image_60x60', - 'image_128x128': 'image_128x128', - 'image_1024x1024': 'image_1024x1024' - } - - def __init__(self, image_21x21=None, image_27x27=None, image_36x36=None, image_60x60=None, image_128x128=None, image_1024x1024=None): # noqa: E501 - """UserBaseResponsePhoto - a model defined in Swagger""" # noqa: E501 - self._image_21x21 = None - self._image_27x27 = None - self._image_36x36 = None - self._image_60x60 = None - self._image_128x128 = None - self._image_1024x1024 = None - self.discriminator = None - if image_21x21 is not None: - self.image_21x21 = image_21x21 - if image_27x27 is not None: - self.image_27x27 = image_27x27 - if image_36x36 is not None: - self.image_36x36 = image_36x36 - if image_60x60 is not None: - self.image_60x60 = image_60x60 - if image_128x128 is not None: - self.image_128x128 = image_128x128 - if image_1024x1024 is not None: - self.image_1024x1024 = image_1024x1024 - - @property - def image_21x21(self): - """Gets the image_21x21 of this UserBaseResponsePhoto. # noqa: E501 - - - :return: The image_21x21 of this UserBaseResponsePhoto. # noqa: E501 - :rtype: str - """ - return self._image_21x21 - - @image_21x21.setter - def image_21x21(self, image_21x21): - """Sets the image_21x21 of this UserBaseResponsePhoto. - - - :param image_21x21: The image_21x21 of this UserBaseResponsePhoto. # noqa: E501 - :type: str - """ - - self._image_21x21 = image_21x21 - - @property - def image_27x27(self): - """Gets the image_27x27 of this UserBaseResponsePhoto. # noqa: E501 - - - :return: The image_27x27 of this UserBaseResponsePhoto. # noqa: E501 - :rtype: str - """ - return self._image_27x27 - - @image_27x27.setter - def image_27x27(self, image_27x27): - """Sets the image_27x27 of this UserBaseResponsePhoto. - - - :param image_27x27: The image_27x27 of this UserBaseResponsePhoto. # noqa: E501 - :type: str - """ - - self._image_27x27 = image_27x27 - - @property - def image_36x36(self): - """Gets the image_36x36 of this UserBaseResponsePhoto. # noqa: E501 - - - :return: The image_36x36 of this UserBaseResponsePhoto. # noqa: E501 - :rtype: str - """ - return self._image_36x36 - - @image_36x36.setter - def image_36x36(self, image_36x36): - """Sets the image_36x36 of this UserBaseResponsePhoto. - - - :param image_36x36: The image_36x36 of this UserBaseResponsePhoto. # noqa: E501 - :type: str - """ - - self._image_36x36 = image_36x36 - - @property - def image_60x60(self): - """Gets the image_60x60 of this UserBaseResponsePhoto. # noqa: E501 - - - :return: The image_60x60 of this UserBaseResponsePhoto. # noqa: E501 - :rtype: str - """ - return self._image_60x60 - - @image_60x60.setter - def image_60x60(self, image_60x60): - """Sets the image_60x60 of this UserBaseResponsePhoto. - - - :param image_60x60: The image_60x60 of this UserBaseResponsePhoto. # noqa: E501 - :type: str - """ - - self._image_60x60 = image_60x60 - - @property - def image_128x128(self): - """Gets the image_128x128 of this UserBaseResponsePhoto. # noqa: E501 - - - :return: The image_128x128 of this UserBaseResponsePhoto. # noqa: E501 - :rtype: str - """ - return self._image_128x128 - - @image_128x128.setter - def image_128x128(self, image_128x128): - """Sets the image_128x128 of this UserBaseResponsePhoto. - - - :param image_128x128: The image_128x128 of this UserBaseResponsePhoto. # noqa: E501 - :type: str - """ - - self._image_128x128 = image_128x128 - - @property - def image_1024x1024(self): - """Gets the image_1024x1024 of this UserBaseResponsePhoto. # noqa: E501 - - - :return: The image_1024x1024 of this UserBaseResponsePhoto. # noqa: E501 - :rtype: str - """ - return self._image_1024x1024 - - @image_1024x1024.setter - def image_1024x1024(self, image_1024x1024): - """Sets the image_1024x1024 of this UserBaseResponsePhoto. - - - :param image_1024x1024: The image_1024x1024 of this UserBaseResponsePhoto. # noqa: E501 - :type: str - """ - - self._image_1024x1024 = image_1024x1024 - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserBaseResponsePhoto, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserBaseResponsePhoto): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_compact.py b/asana/models/user_compact.py deleted file mode 100644 index 4f8a1103..00000000 --- a/asana/models/user_compact.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """UserCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this UserCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this UserCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this UserCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this UserCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this UserCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this UserCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this UserCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this UserCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this UserCompact. # noqa: E501 - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :return: The name of this UserCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this UserCompact. - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :param name: The name of this UserCompact. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_request.py b/asana/models/user_request.py deleted file mode 100644 index 1546e11f..00000000 --- a/asana/models/user_request.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """UserRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this UserRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this UserRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this UserRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this UserRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this UserRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this UserRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this UserRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this UserRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this UserRequest. # noqa: E501 - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :return: The name of this UserRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this UserRequest. - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :param name: The name of this UserRequest. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_response.py b/asana/models/user_response.py deleted file mode 100644 index 926023e8..00000000 --- a/asana/models/user_response.py +++ /dev/null @@ -1,250 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'email': 'str', - 'photo': 'UserBaseResponsePhoto', - 'workspaces': 'list[GoalResponseWorkspace]' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'email': 'email', - 'photo': 'photo', - 'workspaces': 'workspaces' - } - - def __init__(self, gid=None, resource_type=None, name=None, email=None, photo=None, workspaces=None): # noqa: E501 - """UserResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._email = None - self._photo = None - self._workspaces = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if email is not None: - self.email = email - if photo is not None: - self.photo = photo - if workspaces is not None: - self.workspaces = workspaces - - @property - def gid(self): - """Gets the gid of this UserResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this UserResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this UserResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this UserResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this UserResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this UserResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this UserResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this UserResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this UserResponse. # noqa: E501 - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :return: The name of this UserResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this UserResponse. - - *Read-only except when same user as requester*. The user’s name. # noqa: E501 - - :param name: The name of this UserResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def email(self): - """Gets the email of this UserResponse. # noqa: E501 - - The user's email address. # noqa: E501 - - :return: The email of this UserResponse. # noqa: E501 - :rtype: str - """ - return self._email - - @email.setter - def email(self, email): - """Sets the email of this UserResponse. - - The user's email address. # noqa: E501 - - :param email: The email of this UserResponse. # noqa: E501 - :type: str - """ - - self._email = email - - @property - def photo(self): - """Gets the photo of this UserResponse. # noqa: E501 - - - :return: The photo of this UserResponse. # noqa: E501 - :rtype: UserBaseResponsePhoto - """ - return self._photo - - @photo.setter - def photo(self, photo): - """Sets the photo of this UserResponse. - - - :param photo: The photo of this UserResponse. # noqa: E501 - :type: UserBaseResponsePhoto - """ - - self._photo = photo - - @property - def workspaces(self): - """Gets the workspaces of this UserResponse. # noqa: E501 - - Workspaces and organizations this user may access. Note\\: The API will only return workspaces and organizations that also contain the authenticated user. # noqa: E501 - - :return: The workspaces of this UserResponse. # noqa: E501 - :rtype: list[GoalResponseWorkspace] - """ - return self._workspaces - - @workspaces.setter - def workspaces(self, workspaces): - """Sets the workspaces of this UserResponse. - - Workspaces and organizations this user may access. Note\\: The API will only return workspaces and organizations that also contain the authenticated user. # noqa: E501 - - :param workspaces: The workspaces of this UserResponse. # noqa: E501 - :type: list[GoalResponseWorkspace] - """ - - self._workspaces = workspaces - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_response_array.py b/asana/models/user_response_array.py deleted file mode 100644 index f629103b..00000000 --- a/asana/models/user_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[UserResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """UserResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this UserResponseArray. # noqa: E501 - - - :return: The data of this UserResponseArray. # noqa: E501 - :rtype: list[UserResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this UserResponseArray. - - - :param data: The data of this UserResponseArray. # noqa: E501 - :type: list[UserResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this UserResponseArray. # noqa: E501 - - - :return: The next_page of this UserResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this UserResponseArray. - - - :param next_page: The next_page of this UserResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_response_data.py b/asana/models/user_response_data.py deleted file mode 100644 index 5088c871..00000000 --- a/asana/models/user_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'UserResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """UserResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this UserResponseData. # noqa: E501 - - - :return: The data of this UserResponseData. # noqa: E501 - :rtype: UserResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this UserResponseData. - - - :param data: The data of this UserResponseData. # noqa: E501 - :type: UserResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_task_list_base.py b/asana/models/user_task_list_base.py deleted file mode 100644 index f84848b9..00000000 --- a/asana/models/user_task_list_base.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserTaskListBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'owner': 'AllOfUserTaskListBaseOwner', - 'workspace': 'AllOfUserTaskListBaseWorkspace' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'owner': 'owner', - 'workspace': 'workspace' - } - - def __init__(self, gid=None, resource_type=None, name=None, owner=None, workspace=None): # noqa: E501 - """UserTaskListBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._owner = None - self._workspace = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if owner is not None: - self.owner = owner - if workspace is not None: - self.workspace = workspace - - @property - def gid(self): - """Gets the gid of this UserTaskListBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this UserTaskListBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this UserTaskListBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this UserTaskListBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this UserTaskListBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this UserTaskListBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this UserTaskListBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this UserTaskListBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this UserTaskListBase. # noqa: E501 - - The name of the user task list. # noqa: E501 - - :return: The name of this UserTaskListBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this UserTaskListBase. - - The name of the user task list. # noqa: E501 - - :param name: The name of this UserTaskListBase. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def owner(self): - """Gets the owner of this UserTaskListBase. # noqa: E501 - - The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. # noqa: E501 - - :return: The owner of this UserTaskListBase. # noqa: E501 - :rtype: AllOfUserTaskListBaseOwner - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this UserTaskListBase. - - The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. # noqa: E501 - - :param owner: The owner of this UserTaskListBase. # noqa: E501 - :type: AllOfUserTaskListBaseOwner - """ - - self._owner = owner - - @property - def workspace(self): - """Gets the workspace of this UserTaskListBase. # noqa: E501 - - The workspace in which the user task list is located. # noqa: E501 - - :return: The workspace of this UserTaskListBase. # noqa: E501 - :rtype: AllOfUserTaskListBaseWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this UserTaskListBase. - - The workspace in which the user task list is located. # noqa: E501 - - :param workspace: The workspace of this UserTaskListBase. # noqa: E501 - :type: AllOfUserTaskListBaseWorkspace - """ - - self._workspace = workspace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserTaskListBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserTaskListBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_task_list_compact.py b/asana/models/user_task_list_compact.py deleted file mode 100644 index f5befeb1..00000000 --- a/asana/models/user_task_list_compact.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserTaskListCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'owner': 'AllOfUserTaskListCompactOwner', - 'workspace': 'AllOfUserTaskListCompactWorkspace' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'owner': 'owner', - 'workspace': 'workspace' - } - - def __init__(self, gid=None, resource_type=None, name=None, owner=None, workspace=None): # noqa: E501 - """UserTaskListCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._owner = None - self._workspace = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if owner is not None: - self.owner = owner - if workspace is not None: - self.workspace = workspace - - @property - def gid(self): - """Gets the gid of this UserTaskListCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this UserTaskListCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this UserTaskListCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this UserTaskListCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this UserTaskListCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this UserTaskListCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this UserTaskListCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this UserTaskListCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this UserTaskListCompact. # noqa: E501 - - The name of the user task list. # noqa: E501 - - :return: The name of this UserTaskListCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this UserTaskListCompact. - - The name of the user task list. # noqa: E501 - - :param name: The name of this UserTaskListCompact. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def owner(self): - """Gets the owner of this UserTaskListCompact. # noqa: E501 - - The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. # noqa: E501 - - :return: The owner of this UserTaskListCompact. # noqa: E501 - :rtype: AllOfUserTaskListCompactOwner - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this UserTaskListCompact. - - The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. # noqa: E501 - - :param owner: The owner of this UserTaskListCompact. # noqa: E501 - :type: AllOfUserTaskListCompactOwner - """ - - self._owner = owner - - @property - def workspace(self): - """Gets the workspace of this UserTaskListCompact. # noqa: E501 - - The workspace in which the user task list is located. # noqa: E501 - - :return: The workspace of this UserTaskListCompact. # noqa: E501 - :rtype: AllOfUserTaskListCompactWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this UserTaskListCompact. - - The workspace in which the user task list is located. # noqa: E501 - - :param workspace: The workspace of this UserTaskListCompact. # noqa: E501 - :type: AllOfUserTaskListCompactWorkspace - """ - - self._workspace = workspace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserTaskListCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserTaskListCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_task_list_request.py b/asana/models/user_task_list_request.py deleted file mode 100644 index 7838e870..00000000 --- a/asana/models/user_task_list_request.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserTaskListRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'owner': 'AllOfUserTaskListRequestOwner', - 'workspace': 'AllOfUserTaskListRequestWorkspace' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'owner': 'owner', - 'workspace': 'workspace' - } - - def __init__(self, gid=None, resource_type=None, name=None, owner=None, workspace=None): # noqa: E501 - """UserTaskListRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._owner = None - self._workspace = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if owner is not None: - self.owner = owner - if workspace is not None: - self.workspace = workspace - - @property - def gid(self): - """Gets the gid of this UserTaskListRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this UserTaskListRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this UserTaskListRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this UserTaskListRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this UserTaskListRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this UserTaskListRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this UserTaskListRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this UserTaskListRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this UserTaskListRequest. # noqa: E501 - - The name of the user task list. # noqa: E501 - - :return: The name of this UserTaskListRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this UserTaskListRequest. - - The name of the user task list. # noqa: E501 - - :param name: The name of this UserTaskListRequest. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def owner(self): - """Gets the owner of this UserTaskListRequest. # noqa: E501 - - The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. # noqa: E501 - - :return: The owner of this UserTaskListRequest. # noqa: E501 - :rtype: AllOfUserTaskListRequestOwner - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this UserTaskListRequest. - - The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. # noqa: E501 - - :param owner: The owner of this UserTaskListRequest. # noqa: E501 - :type: AllOfUserTaskListRequestOwner - """ - - self._owner = owner - - @property - def workspace(self): - """Gets the workspace of this UserTaskListRequest. # noqa: E501 - - The workspace in which the user task list is located. # noqa: E501 - - :return: The workspace of this UserTaskListRequest. # noqa: E501 - :rtype: AllOfUserTaskListRequestWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this UserTaskListRequest. - - The workspace in which the user task list is located. # noqa: E501 - - :param workspace: The workspace of this UserTaskListRequest. # noqa: E501 - :type: AllOfUserTaskListRequestWorkspace - """ - - self._workspace = workspace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserTaskListRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserTaskListRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_task_list_response.py b/asana/models/user_task_list_response.py deleted file mode 100644 index 285b6411..00000000 --- a/asana/models/user_task_list_response.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserTaskListResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'owner': 'AllOfUserTaskListResponseOwner', - 'workspace': 'AllOfUserTaskListResponseWorkspace' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'owner': 'owner', - 'workspace': 'workspace' - } - - def __init__(self, gid=None, resource_type=None, name=None, owner=None, workspace=None): # noqa: E501 - """UserTaskListResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._owner = None - self._workspace = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if owner is not None: - self.owner = owner - if workspace is not None: - self.workspace = workspace - - @property - def gid(self): - """Gets the gid of this UserTaskListResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this UserTaskListResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this UserTaskListResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this UserTaskListResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this UserTaskListResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this UserTaskListResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this UserTaskListResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this UserTaskListResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this UserTaskListResponse. # noqa: E501 - - The name of the user task list. # noqa: E501 - - :return: The name of this UserTaskListResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this UserTaskListResponse. - - The name of the user task list. # noqa: E501 - - :param name: The name of this UserTaskListResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def owner(self): - """Gets the owner of this UserTaskListResponse. # noqa: E501 - - The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. # noqa: E501 - - :return: The owner of this UserTaskListResponse. # noqa: E501 - :rtype: AllOfUserTaskListResponseOwner - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this UserTaskListResponse. - - The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. # noqa: E501 - - :param owner: The owner of this UserTaskListResponse. # noqa: E501 - :type: AllOfUserTaskListResponseOwner - """ - - self._owner = owner - - @property - def workspace(self): - """Gets the workspace of this UserTaskListResponse. # noqa: E501 - - The workspace in which the user task list is located. # noqa: E501 - - :return: The workspace of this UserTaskListResponse. # noqa: E501 - :rtype: AllOfUserTaskListResponseWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this UserTaskListResponse. - - The workspace in which the user task list is located. # noqa: E501 - - :param workspace: The workspace of this UserTaskListResponse. # noqa: E501 - :type: AllOfUserTaskListResponseWorkspace - """ - - self._workspace = workspace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserTaskListResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserTaskListResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/user_task_list_response_data.py b/asana/models/user_task_list_response_data.py deleted file mode 100644 index 8275ae3d..00000000 --- a/asana/models/user_task_list_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class UserTaskListResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'UserTaskListResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """UserTaskListResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this UserTaskListResponseData. # noqa: E501 - - - :return: The data of this UserTaskListResponseData. # noqa: E501 - :rtype: UserTaskListResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this UserTaskListResponseData. - - - :param data: The data of this UserTaskListResponseData. # noqa: E501 - :type: UserTaskListResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(UserTaskListResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, UserTaskListResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/webhook_compact.py b/asana/models/webhook_compact.py deleted file mode 100644 index 7b52dc09..00000000 --- a/asana/models/webhook_compact.py +++ /dev/null @@ -1,222 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WebhookCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'active': 'bool', - 'resource': 'WebhookCompactResource', - 'target': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'active': 'active', - 'resource': 'resource', - 'target': 'target' - } - - def __init__(self, gid=None, resource_type=None, active=None, resource=None, target=None): # noqa: E501 - """WebhookCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._active = None - self._resource = None - self._target = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if active is not None: - self.active = active - if resource is not None: - self.resource = resource - if target is not None: - self.target = target - - @property - def gid(self): - """Gets the gid of this WebhookCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this WebhookCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this WebhookCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this WebhookCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this WebhookCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this WebhookCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WebhookCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this WebhookCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def active(self): - """Gets the active of this WebhookCompact. # noqa: E501 - - If true, the webhook will send events - if false it is considered inactive and will not generate events. # noqa: E501 - - :return: The active of this WebhookCompact. # noqa: E501 - :rtype: bool - """ - return self._active - - @active.setter - def active(self, active): - """Sets the active of this WebhookCompact. - - If true, the webhook will send events - if false it is considered inactive and will not generate events. # noqa: E501 - - :param active: The active of this WebhookCompact. # noqa: E501 - :type: bool - """ - - self._active = active - - @property - def resource(self): - """Gets the resource of this WebhookCompact. # noqa: E501 - - - :return: The resource of this WebhookCompact. # noqa: E501 - :rtype: WebhookCompactResource - """ - return self._resource - - @resource.setter - def resource(self, resource): - """Sets the resource of this WebhookCompact. - - - :param resource: The resource of this WebhookCompact. # noqa: E501 - :type: WebhookCompactResource - """ - - self._resource = resource - - @property - def target(self): - """Gets the target of this WebhookCompact. # noqa: E501 - - The URL to receive the HTTP POST. # noqa: E501 - - :return: The target of this WebhookCompact. # noqa: E501 - :rtype: str - """ - return self._target - - @target.setter - def target(self, target): - """Sets the target of this WebhookCompact. - - The URL to receive the HTTP POST. # noqa: E501 - - :param target: The target of this WebhookCompact. # noqa: E501 - :type: str - """ - - self._target = target - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WebhookCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WebhookCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/webhook_compact_resource.py b/asana/models/webhook_compact_resource.py deleted file mode 100644 index a5c3d147..00000000 --- a/asana/models/webhook_compact_resource.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WebhookCompactResource(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """WebhookCompactResource - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this WebhookCompactResource. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this WebhookCompactResource. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this WebhookCompactResource. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this WebhookCompactResource. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this WebhookCompactResource. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this WebhookCompactResource. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WebhookCompactResource. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this WebhookCompactResource. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this WebhookCompactResource. # noqa: E501 - - The name of the object. # noqa: E501 - - :return: The name of this WebhookCompactResource. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this WebhookCompactResource. - - The name of the object. # noqa: E501 - - :param name: The name of this WebhookCompactResource. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WebhookCompactResource, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WebhookCompactResource): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/webhook_filter.py b/asana/models/webhook_filter.py deleted file mode 100644 index f24d4b0c..00000000 --- a/asana/models/webhook_filter.py +++ /dev/null @@ -1,196 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WebhookFilter(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'resource_type': 'str', - 'resource_subtype': 'str', - 'action': 'str', - 'fields': 'list[str]' - } - - attribute_map = { - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'action': 'action', - 'fields': 'fields' - } - - def __init__(self, resource_type=None, resource_subtype=None, action=None, fields=None): # noqa: E501 - """WebhookFilter - a model defined in Swagger""" # noqa: E501 - self._resource_type = None - self._resource_subtype = None - self._action = None - self._fields = None - self.discriminator = None - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if action is not None: - self.action = action - if fields is not None: - self.fields = fields - - @property - def resource_type(self): - """Gets the resource_type of this WebhookFilter. # noqa: E501 - - The type of the resource which created the event when modified; for example, to filter to changes on regular tasks this field should be set to `task`. # noqa: E501 - - :return: The resource_type of this WebhookFilter. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WebhookFilter. - - The type of the resource which created the event when modified; for example, to filter to changes on regular tasks this field should be set to `task`. # noqa: E501 - - :param resource_type: The resource_type of this WebhookFilter. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this WebhookFilter. # noqa: E501 - - The resource subtype of the resource that the filter applies to. This should be set to the same value as is returned on the `resource_subtype` field on the resources themselves. # noqa: E501 - - :return: The resource_subtype of this WebhookFilter. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this WebhookFilter. - - The resource subtype of the resource that the filter applies to. This should be set to the same value as is returned on the `resource_subtype` field on the resources themselves. # noqa: E501 - - :param resource_subtype: The resource_subtype of this WebhookFilter. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def action(self): - """Gets the action of this WebhookFilter. # noqa: E501 - - The type of change on the **resource** to pass through the filter. For more information refer to `Event.action` in the [event](/reference/events) schema. This can be one of `changed`, `added`, `removed`, `deleted`, and `undeleted` depending on the nature of what has occurred on the resource. # noqa: E501 - - :return: The action of this WebhookFilter. # noqa: E501 - :rtype: str - """ - return self._action - - @action.setter - def action(self, action): - """Sets the action of this WebhookFilter. - - The type of change on the **resource** to pass through the filter. For more information refer to `Event.action` in the [event](/reference/events) schema. This can be one of `changed`, `added`, `removed`, `deleted`, and `undeleted` depending on the nature of what has occurred on the resource. # noqa: E501 - - :param action: The action of this WebhookFilter. # noqa: E501 - :type: str - """ - - self._action = action - - @property - def fields(self): - """Gets the fields of this WebhookFilter. # noqa: E501 - - *Conditional.* A whitelist of fields for events which will pass the filter when the resource is changed. These can be any combination of the fields on the resources themselves. This field is only valid for `action` of type `changed` # noqa: E501 - - :return: The fields of this WebhookFilter. # noqa: E501 - :rtype: list[str] - """ - return self._fields - - @fields.setter - def fields(self, fields): - """Sets the fields of this WebhookFilter. - - *Conditional.* A whitelist of fields for events which will pass the filter when the resource is changed. These can be any combination of the fields on the resources themselves. This field is only valid for `action` of type `changed` # noqa: E501 - - :param fields: The fields of this WebhookFilter. # noqa: E501 - :type: list[str] - """ - - self._fields = fields - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WebhookFilter, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WebhookFilter): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/webhook_request.py b/asana/models/webhook_request.py deleted file mode 100644 index 5f42e5d0..00000000 --- a/asana/models/webhook_request.py +++ /dev/null @@ -1,170 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WebhookRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'resource': 'str', - 'target': 'str', - 'filters': 'list[WebhookRequestFilters]' - } - - attribute_map = { - 'resource': 'resource', - 'target': 'target', - 'filters': 'filters' - } - - def __init__(self, resource=None, target=None, filters=None): # noqa: E501 - """WebhookRequest - a model defined in Swagger""" # noqa: E501 - self._resource = None - self._target = None - self._filters = None - self.discriminator = None - self.resource = resource - self.target = target - if filters is not None: - self.filters = filters - - @property - def resource(self): - """Gets the resource of this WebhookRequest. # noqa: E501 - - A resource ID to subscribe to. Many Asana resources are valid to create webhooks on, but higher-level resources require filters. # noqa: E501 - - :return: The resource of this WebhookRequest. # noqa: E501 - :rtype: str - """ - return self._resource - - @resource.setter - def resource(self, resource): - """Sets the resource of this WebhookRequest. - - A resource ID to subscribe to. Many Asana resources are valid to create webhooks on, but higher-level resources require filters. # noqa: E501 - - :param resource: The resource of this WebhookRequest. # noqa: E501 - :type: str - """ - if resource is None: - raise ValueError("Invalid value for `resource`, must not be `None`") # noqa: E501 - - self._resource = resource - - @property - def target(self): - """Gets the target of this WebhookRequest. # noqa: E501 - - The URL to receive the HTTP POST. The full URL will be used to deliver events from this webhook (including parameters) which allows encoding of application-specific state when the webhook is created. # noqa: E501 - - :return: The target of this WebhookRequest. # noqa: E501 - :rtype: str - """ - return self._target - - @target.setter - def target(self, target): - """Sets the target of this WebhookRequest. - - The URL to receive the HTTP POST. The full URL will be used to deliver events from this webhook (including parameters) which allows encoding of application-specific state when the webhook is created. # noqa: E501 - - :param target: The target of this WebhookRequest. # noqa: E501 - :type: str - """ - if target is None: - raise ValueError("Invalid value for `target`, must not be `None`") # noqa: E501 - - self._target = target - - @property - def filters(self): - """Gets the filters of this WebhookRequest. # noqa: E501 - - An array of WebhookFilter objects to specify a whitelist of filters to apply to events from this webhook. If a webhook event passes any of the filters the event will be delivered; otherwise no event will be sent to the receiving server. # noqa: E501 - - :return: The filters of this WebhookRequest. # noqa: E501 - :rtype: list[WebhookRequestFilters] - """ - return self._filters - - @filters.setter - def filters(self, filters): - """Sets the filters of this WebhookRequest. - - An array of WebhookFilter objects to specify a whitelist of filters to apply to events from this webhook. If a webhook event passes any of the filters the event will be delivered; otherwise no event will be sent to the receiving server. # noqa: E501 - - :param filters: The filters of this WebhookRequest. # noqa: E501 - :type: list[WebhookRequestFilters] - """ - - self._filters = filters - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WebhookRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WebhookRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/webhook_request_filters.py b/asana/models/webhook_request_filters.py deleted file mode 100644 index 56320839..00000000 --- a/asana/models/webhook_request_filters.py +++ /dev/null @@ -1,196 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WebhookRequestFilters(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'resource_type': 'str', - 'resource_subtype': 'str', - 'action': 'str', - 'fields': 'list[str]' - } - - attribute_map = { - 'resource_type': 'resource_type', - 'resource_subtype': 'resource_subtype', - 'action': 'action', - 'fields': 'fields' - } - - def __init__(self, resource_type=None, resource_subtype=None, action=None, fields=None): # noqa: E501 - """WebhookRequestFilters - a model defined in Swagger""" # noqa: E501 - self._resource_type = None - self._resource_subtype = None - self._action = None - self._fields = None - self.discriminator = None - if resource_type is not None: - self.resource_type = resource_type - if resource_subtype is not None: - self.resource_subtype = resource_subtype - if action is not None: - self.action = action - if fields is not None: - self.fields = fields - - @property - def resource_type(self): - """Gets the resource_type of this WebhookRequestFilters. # noqa: E501 - - The type of the resource which created the event when modified; for example, to filter to changes on regular tasks this field should be set to `task`. # noqa: E501 - - :return: The resource_type of this WebhookRequestFilters. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WebhookRequestFilters. - - The type of the resource which created the event when modified; for example, to filter to changes on regular tasks this field should be set to `task`. # noqa: E501 - - :param resource_type: The resource_type of this WebhookRequestFilters. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def resource_subtype(self): - """Gets the resource_subtype of this WebhookRequestFilters. # noqa: E501 - - The resource subtype of the resource that the filter applies to. This should be set to the same value as is returned on the `resource_subtype` field on the resources themselves. # noqa: E501 - - :return: The resource_subtype of this WebhookRequestFilters. # noqa: E501 - :rtype: str - """ - return self._resource_subtype - - @resource_subtype.setter - def resource_subtype(self, resource_subtype): - """Sets the resource_subtype of this WebhookRequestFilters. - - The resource subtype of the resource that the filter applies to. This should be set to the same value as is returned on the `resource_subtype` field on the resources themselves. # noqa: E501 - - :param resource_subtype: The resource_subtype of this WebhookRequestFilters. # noqa: E501 - :type: str - """ - - self._resource_subtype = resource_subtype - - @property - def action(self): - """Gets the action of this WebhookRequestFilters. # noqa: E501 - - The type of change on the **resource** to pass through the filter. For more information refer to `Event.action` in the [event](/reference/events) schema. This can be one of `changed`, `added`, `removed`, `deleted`, and `undeleted` depending on the nature of what has occurred on the resource. # noqa: E501 - - :return: The action of this WebhookRequestFilters. # noqa: E501 - :rtype: str - """ - return self._action - - @action.setter - def action(self, action): - """Sets the action of this WebhookRequestFilters. - - The type of change on the **resource** to pass through the filter. For more information refer to `Event.action` in the [event](/reference/events) schema. This can be one of `changed`, `added`, `removed`, `deleted`, and `undeleted` depending on the nature of what has occurred on the resource. # noqa: E501 - - :param action: The action of this WebhookRequestFilters. # noqa: E501 - :type: str - """ - - self._action = action - - @property - def fields(self): - """Gets the fields of this WebhookRequestFilters. # noqa: E501 - - *Conditional.* A whitelist of fields for events which will pass the filter when the resource is changed. These can be any combination of the fields on the resources themselves. This field is only valid for `action` of type `changed` # noqa: E501 - - :return: The fields of this WebhookRequestFilters. # noqa: E501 - :rtype: list[str] - """ - return self._fields - - @fields.setter - def fields(self, fields): - """Sets the fields of this WebhookRequestFilters. - - *Conditional.* A whitelist of fields for events which will pass the filter when the resource is changed. These can be any combination of the fields on the resources themselves. This field is only valid for `action` of type `changed` # noqa: E501 - - :param fields: The fields of this WebhookRequestFilters. # noqa: E501 - :type: list[str] - """ - - self._fields = fields - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WebhookRequestFilters, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WebhookRequestFilters): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/webhook_response.py b/asana/models/webhook_response.py deleted file mode 100644 index 84cf414e..00000000 --- a/asana/models/webhook_response.py +++ /dev/null @@ -1,362 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WebhookResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'active': 'bool', - 'resource': 'WebhookCompactResource', - 'target': 'str', - 'created_at': 'datetime', - 'last_failure_at': 'datetime', - 'last_failure_content': 'str', - 'last_success_at': 'datetime', - 'filters': 'list[WebhookRequestFilters]' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'active': 'active', - 'resource': 'resource', - 'target': 'target', - 'created_at': 'created_at', - 'last_failure_at': 'last_failure_at', - 'last_failure_content': 'last_failure_content', - 'last_success_at': 'last_success_at', - 'filters': 'filters' - } - - def __init__(self, gid=None, resource_type=None, active=None, resource=None, target=None, created_at=None, last_failure_at=None, last_failure_content=None, last_success_at=None, filters=None): # noqa: E501 - """WebhookResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._active = None - self._resource = None - self._target = None - self._created_at = None - self._last_failure_at = None - self._last_failure_content = None - self._last_success_at = None - self._filters = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if active is not None: - self.active = active - if resource is not None: - self.resource = resource - if target is not None: - self.target = target - if created_at is not None: - self.created_at = created_at - if last_failure_at is not None: - self.last_failure_at = last_failure_at - if last_failure_content is not None: - self.last_failure_content = last_failure_content - if last_success_at is not None: - self.last_success_at = last_success_at - if filters is not None: - self.filters = filters - - @property - def gid(self): - """Gets the gid of this WebhookResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this WebhookResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this WebhookResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this WebhookResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this WebhookResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this WebhookResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WebhookResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this WebhookResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def active(self): - """Gets the active of this WebhookResponse. # noqa: E501 - - If true, the webhook will send events - if false it is considered inactive and will not generate events. # noqa: E501 - - :return: The active of this WebhookResponse. # noqa: E501 - :rtype: bool - """ - return self._active - - @active.setter - def active(self, active): - """Sets the active of this WebhookResponse. - - If true, the webhook will send events - if false it is considered inactive and will not generate events. # noqa: E501 - - :param active: The active of this WebhookResponse. # noqa: E501 - :type: bool - """ - - self._active = active - - @property - def resource(self): - """Gets the resource of this WebhookResponse. # noqa: E501 - - - :return: The resource of this WebhookResponse. # noqa: E501 - :rtype: WebhookCompactResource - """ - return self._resource - - @resource.setter - def resource(self, resource): - """Sets the resource of this WebhookResponse. - - - :param resource: The resource of this WebhookResponse. # noqa: E501 - :type: WebhookCompactResource - """ - - self._resource = resource - - @property - def target(self): - """Gets the target of this WebhookResponse. # noqa: E501 - - The URL to receive the HTTP POST. # noqa: E501 - - :return: The target of this WebhookResponse. # noqa: E501 - :rtype: str - """ - return self._target - - @target.setter - def target(self, target): - """Sets the target of this WebhookResponse. - - The URL to receive the HTTP POST. # noqa: E501 - - :param target: The target of this WebhookResponse. # noqa: E501 - :type: str - """ - - self._target = target - - @property - def created_at(self): - """Gets the created_at of this WebhookResponse. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this WebhookResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this WebhookResponse. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this WebhookResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - @property - def last_failure_at(self): - """Gets the last_failure_at of this WebhookResponse. # noqa: E501 - - The timestamp when the webhook last received an error when sending an event to the target. # noqa: E501 - - :return: The last_failure_at of this WebhookResponse. # noqa: E501 - :rtype: datetime - """ - return self._last_failure_at - - @last_failure_at.setter - def last_failure_at(self, last_failure_at): - """Sets the last_failure_at of this WebhookResponse. - - The timestamp when the webhook last received an error when sending an event to the target. # noqa: E501 - - :param last_failure_at: The last_failure_at of this WebhookResponse. # noqa: E501 - :type: datetime - """ - - self._last_failure_at = last_failure_at - - @property - def last_failure_content(self): - """Gets the last_failure_content of this WebhookResponse. # noqa: E501 - - The contents of the last error response sent to the webhook when attempting to deliver events to the target. # noqa: E501 - - :return: The last_failure_content of this WebhookResponse. # noqa: E501 - :rtype: str - """ - return self._last_failure_content - - @last_failure_content.setter - def last_failure_content(self, last_failure_content): - """Sets the last_failure_content of this WebhookResponse. - - The contents of the last error response sent to the webhook when attempting to deliver events to the target. # noqa: E501 - - :param last_failure_content: The last_failure_content of this WebhookResponse. # noqa: E501 - :type: str - """ - - self._last_failure_content = last_failure_content - - @property - def last_success_at(self): - """Gets the last_success_at of this WebhookResponse. # noqa: E501 - - The timestamp when the webhook last successfully sent an event to the target. # noqa: E501 - - :return: The last_success_at of this WebhookResponse. # noqa: E501 - :rtype: datetime - """ - return self._last_success_at - - @last_success_at.setter - def last_success_at(self, last_success_at): - """Sets the last_success_at of this WebhookResponse. - - The timestamp when the webhook last successfully sent an event to the target. # noqa: E501 - - :param last_success_at: The last_success_at of this WebhookResponse. # noqa: E501 - :type: datetime - """ - - self._last_success_at = last_success_at - - @property - def filters(self): - """Gets the filters of this WebhookResponse. # noqa: E501 - - Whitelist of filters to apply to events from this webhook. If a webhook event passes any of the filters the event will be delivered; otherwise no event will be sent to the receiving server. # noqa: E501 - - :return: The filters of this WebhookResponse. # noqa: E501 - :rtype: list[WebhookRequestFilters] - """ - return self._filters - - @filters.setter - def filters(self, filters): - """Sets the filters of this WebhookResponse. - - Whitelist of filters to apply to events from this webhook. If a webhook event passes any of the filters the event will be delivered; otherwise no event will be sent to the receiving server. # noqa: E501 - - :param filters: The filters of this WebhookResponse. # noqa: E501 - :type: list[WebhookRequestFilters] - """ - - self._filters = filters - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WebhookResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WebhookResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/webhook_response_array.py b/asana/models/webhook_response_array.py deleted file mode 100644 index 36a18e7d..00000000 --- a/asana/models/webhook_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WebhookResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[WebhookResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """WebhookResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this WebhookResponseArray. # noqa: E501 - - - :return: The data of this WebhookResponseArray. # noqa: E501 - :rtype: list[WebhookResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this WebhookResponseArray. - - - :param data: The data of this WebhookResponseArray. # noqa: E501 - :type: list[WebhookResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this WebhookResponseArray. # noqa: E501 - - - :return: The next_page of this WebhookResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this WebhookResponseArray. - - - :param next_page: The next_page of this WebhookResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WebhookResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WebhookResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/webhook_response_data.py b/asana/models/webhook_response_data.py deleted file mode 100644 index 0dbc0843..00000000 --- a/asana/models/webhook_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WebhookResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'WebhookResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """WebhookResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this WebhookResponseData. # noqa: E501 - - - :return: The data of this WebhookResponseData. # noqa: E501 - :rtype: WebhookResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this WebhookResponseData. - - - :param data: The data of this WebhookResponseData. # noqa: E501 - :type: WebhookResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WebhookResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WebhookResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/webhook_update_request.py b/asana/models/webhook_update_request.py deleted file mode 100644 index 7368e49f..00000000 --- a/asana/models/webhook_update_request.py +++ /dev/null @@ -1,112 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WebhookUpdateRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'filters': 'list[WebhookRequestFilters]' - } - - attribute_map = { - 'filters': 'filters' - } - - def __init__(self, filters=None): # noqa: E501 - """WebhookUpdateRequest - a model defined in Swagger""" # noqa: E501 - self._filters = None - self.discriminator = None - if filters is not None: - self.filters = filters - - @property - def filters(self): - """Gets the filters of this WebhookUpdateRequest. # noqa: E501 - - An array of WebhookFilter objects to specify a whitelist of filters to apply to events from this webhook. If a webhook event passes any of the filters the event will be delivered; otherwise no event will be sent to the receiving server. # noqa: E501 - - :return: The filters of this WebhookUpdateRequest. # noqa: E501 - :rtype: list[WebhookRequestFilters] - """ - return self._filters - - @filters.setter - def filters(self, filters): - """Sets the filters of this WebhookUpdateRequest. - - An array of WebhookFilter objects to specify a whitelist of filters to apply to events from this webhook. If a webhook event passes any of the filters the event will be delivered; otherwise no event will be sent to the receiving server. # noqa: E501 - - :param filters: The filters of this WebhookUpdateRequest. # noqa: E501 - :type: list[WebhookRequestFilters] - """ - - self._filters = filters - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WebhookUpdateRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WebhookUpdateRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/webhooks_body.py b/asana/models/webhooks_body.py deleted file mode 100644 index b6bd8ae9..00000000 --- a/asana/models/webhooks_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WebhooksBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'WebhookRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """WebhooksBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this WebhooksBody. # noqa: E501 - - - :return: The data of this WebhooksBody. # noqa: E501 - :rtype: WebhookRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this WebhooksBody. - - - :param data: The data of this WebhooksBody. # noqa: E501 - :type: WebhookRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WebhooksBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WebhooksBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/webhooks_webhook_gid_body.py b/asana/models/webhooks_webhook_gid_body.py deleted file mode 100644 index 2f8a290c..00000000 --- a/asana/models/webhooks_webhook_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WebhooksWebhookGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'WebhookUpdateRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """WebhooksWebhookGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this WebhooksWebhookGidBody. # noqa: E501 - - - :return: The data of this WebhooksWebhookGidBody. # noqa: E501 - :rtype: WebhookUpdateRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this WebhooksWebhookGidBody. - - - :param data: The data of this WebhooksWebhookGidBody. # noqa: E501 - :type: WebhookUpdateRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WebhooksWebhookGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WebhooksWebhookGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_add_user_request.py b/asana/models/workspace_add_user_request.py deleted file mode 100644 index b9383ff8..00000000 --- a/asana/models/workspace_add_user_request.py +++ /dev/null @@ -1,112 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceAddUserRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'user': 'str' - } - - attribute_map = { - 'user': 'user' - } - - def __init__(self, user=None): # noqa: E501 - """WorkspaceAddUserRequest - a model defined in Swagger""" # noqa: E501 - self._user = None - self.discriminator = None - if user is not None: - self.user = user - - @property - def user(self): - """Gets the user of this WorkspaceAddUserRequest. # noqa: E501 - - A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :return: The user of this WorkspaceAddUserRequest. # noqa: E501 - :rtype: str - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this WorkspaceAddUserRequest. - - A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :param user: The user of this WorkspaceAddUserRequest. # noqa: E501 - :type: str - """ - - self._user = user - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceAddUserRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceAddUserRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_base.py b/asana/models/workspace_base.py deleted file mode 100644 index 38654b1b..00000000 --- a/asana/models/workspace_base.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """WorkspaceBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this WorkspaceBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this WorkspaceBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this WorkspaceBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this WorkspaceBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this WorkspaceBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this WorkspaceBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WorkspaceBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this WorkspaceBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this WorkspaceBase. # noqa: E501 - - The name of the workspace. # noqa: E501 - - :return: The name of this WorkspaceBase. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this WorkspaceBase. - - The name of the workspace. # noqa: E501 - - :param name: The name of this WorkspaceBase. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_compact.py b/asana/models/workspace_compact.py deleted file mode 100644 index 38201fce..00000000 --- a/asana/models/workspace_compact.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """WorkspaceCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this WorkspaceCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this WorkspaceCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this WorkspaceCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this WorkspaceCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this WorkspaceCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this WorkspaceCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WorkspaceCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this WorkspaceCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this WorkspaceCompact. # noqa: E501 - - The name of the workspace. # noqa: E501 - - :return: The name of this WorkspaceCompact. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this WorkspaceCompact. - - The name of the workspace. # noqa: E501 - - :param name: The name of this WorkspaceCompact. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_gid_add_user_body.py b/asana/models/workspace_gid_add_user_body.py deleted file mode 100644 index c589de19..00000000 --- a/asana/models/workspace_gid_add_user_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceGidAddUserBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'WorkspaceAddUserRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """WorkspaceGidAddUserBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this WorkspaceGidAddUserBody. # noqa: E501 - - - :return: The data of this WorkspaceGidAddUserBody. # noqa: E501 - :rtype: WorkspaceAddUserRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this WorkspaceGidAddUserBody. - - - :param data: The data of this WorkspaceGidAddUserBody. # noqa: E501 - :type: WorkspaceAddUserRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceGidAddUserBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceGidAddUserBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_gid_projects_body.py b/asana/models/workspace_gid_projects_body.py deleted file mode 100644 index 76d8de29..00000000 --- a/asana/models/workspace_gid_projects_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceGidProjectsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'ProjectRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """WorkspaceGidProjectsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this WorkspaceGidProjectsBody. # noqa: E501 - - - :return: The data of this WorkspaceGidProjectsBody. # noqa: E501 - :rtype: ProjectRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this WorkspaceGidProjectsBody. - - - :param data: The data of this WorkspaceGidProjectsBody. # noqa: E501 - :type: ProjectRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceGidProjectsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceGidProjectsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_gid_remove_user_body.py b/asana/models/workspace_gid_remove_user_body.py deleted file mode 100644 index d591bec4..00000000 --- a/asana/models/workspace_gid_remove_user_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceGidRemoveUserBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'WorkspaceRemoveUserRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """WorkspaceGidRemoveUserBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this WorkspaceGidRemoveUserBody. # noqa: E501 - - - :return: The data of this WorkspaceGidRemoveUserBody. # noqa: E501 - :rtype: WorkspaceRemoveUserRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this WorkspaceGidRemoveUserBody. - - - :param data: The data of this WorkspaceGidRemoveUserBody. # noqa: E501 - :type: WorkspaceRemoveUserRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceGidRemoveUserBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceGidRemoveUserBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_gid_tags_body.py b/asana/models/workspace_gid_tags_body.py deleted file mode 100644 index 26307cdb..00000000 --- a/asana/models/workspace_gid_tags_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceGidTagsBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'TagCreateTagForWorkspaceRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """WorkspaceGidTagsBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this WorkspaceGidTagsBody. # noqa: E501 - - - :return: The data of this WorkspaceGidTagsBody. # noqa: E501 - :rtype: TagCreateTagForWorkspaceRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this WorkspaceGidTagsBody. - - - :param data: The data of this WorkspaceGidTagsBody. # noqa: E501 - :type: TagCreateTagForWorkspaceRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceGidTagsBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceGidTagsBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_membership_base.py b/asana/models/workspace_membership_base.py deleted file mode 100644 index 5e19b578..00000000 --- a/asana/models/workspace_membership_base.py +++ /dev/null @@ -1,192 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceMembershipBase(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'user': 'CustomFieldResponsePeopleValue', - 'workspace': 'GoalResponseWorkspace' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'user': 'user', - 'workspace': 'workspace' - } - - def __init__(self, gid=None, resource_type=None, user=None, workspace=None): # noqa: E501 - """WorkspaceMembershipBase - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._user = None - self._workspace = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if user is not None: - self.user = user - if workspace is not None: - self.workspace = workspace - - @property - def gid(self): - """Gets the gid of this WorkspaceMembershipBase. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this WorkspaceMembershipBase. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this WorkspaceMembershipBase. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this WorkspaceMembershipBase. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this WorkspaceMembershipBase. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this WorkspaceMembershipBase. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WorkspaceMembershipBase. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this WorkspaceMembershipBase. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def user(self): - """Gets the user of this WorkspaceMembershipBase. # noqa: E501 - - - :return: The user of this WorkspaceMembershipBase. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this WorkspaceMembershipBase. - - - :param user: The user of this WorkspaceMembershipBase. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - @property - def workspace(self): - """Gets the workspace of this WorkspaceMembershipBase. # noqa: E501 - - - :return: The workspace of this WorkspaceMembershipBase. # noqa: E501 - :rtype: GoalResponseWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this WorkspaceMembershipBase. - - - :param workspace: The workspace of this WorkspaceMembershipBase. # noqa: E501 - :type: GoalResponseWorkspace - """ - - self._workspace = workspace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceMembershipBase, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceMembershipBase): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_membership_compact.py b/asana/models/workspace_membership_compact.py deleted file mode 100644 index c9fc6f5f..00000000 --- a/asana/models/workspace_membership_compact.py +++ /dev/null @@ -1,192 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceMembershipCompact(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'user': 'CustomFieldResponsePeopleValue', - 'workspace': 'GoalResponseWorkspace' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'user': 'user', - 'workspace': 'workspace' - } - - def __init__(self, gid=None, resource_type=None, user=None, workspace=None): # noqa: E501 - """WorkspaceMembershipCompact - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._user = None - self._workspace = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if user is not None: - self.user = user - if workspace is not None: - self.workspace = workspace - - @property - def gid(self): - """Gets the gid of this WorkspaceMembershipCompact. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this WorkspaceMembershipCompact. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this WorkspaceMembershipCompact. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this WorkspaceMembershipCompact. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this WorkspaceMembershipCompact. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this WorkspaceMembershipCompact. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WorkspaceMembershipCompact. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this WorkspaceMembershipCompact. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def user(self): - """Gets the user of this WorkspaceMembershipCompact. # noqa: E501 - - - :return: The user of this WorkspaceMembershipCompact. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this WorkspaceMembershipCompact. - - - :param user: The user of this WorkspaceMembershipCompact. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - @property - def workspace(self): - """Gets the workspace of this WorkspaceMembershipCompact. # noqa: E501 - - - :return: The workspace of this WorkspaceMembershipCompact. # noqa: E501 - :rtype: GoalResponseWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this WorkspaceMembershipCompact. - - - :param workspace: The workspace of this WorkspaceMembershipCompact. # noqa: E501 - :type: GoalResponseWorkspace - """ - - self._workspace = workspace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceMembershipCompact, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceMembershipCompact): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_membership_request.py b/asana/models/workspace_membership_request.py deleted file mode 100644 index a949a11d..00000000 --- a/asana/models/workspace_membership_request.py +++ /dev/null @@ -1,192 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceMembershipRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'user': 'CustomFieldResponsePeopleValue', - 'workspace': 'GoalResponseWorkspace' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'user': 'user', - 'workspace': 'workspace' - } - - def __init__(self, gid=None, resource_type=None, user=None, workspace=None): # noqa: E501 - """WorkspaceMembershipRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._user = None - self._workspace = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if user is not None: - self.user = user - if workspace is not None: - self.workspace = workspace - - @property - def gid(self): - """Gets the gid of this WorkspaceMembershipRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this WorkspaceMembershipRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this WorkspaceMembershipRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this WorkspaceMembershipRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this WorkspaceMembershipRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this WorkspaceMembershipRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WorkspaceMembershipRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this WorkspaceMembershipRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def user(self): - """Gets the user of this WorkspaceMembershipRequest. # noqa: E501 - - - :return: The user of this WorkspaceMembershipRequest. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this WorkspaceMembershipRequest. - - - :param user: The user of this WorkspaceMembershipRequest. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - @property - def workspace(self): - """Gets the workspace of this WorkspaceMembershipRequest. # noqa: E501 - - - :return: The workspace of this WorkspaceMembershipRequest. # noqa: E501 - :rtype: GoalResponseWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this WorkspaceMembershipRequest. - - - :param workspace: The workspace of this WorkspaceMembershipRequest. # noqa: E501 - :type: GoalResponseWorkspace - """ - - self._workspace = workspace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceMembershipRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceMembershipRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_membership_response.py b/asana/models/workspace_membership_response.py deleted file mode 100644 index 4cac506a..00000000 --- a/asana/models/workspace_membership_response.py +++ /dev/null @@ -1,356 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceMembershipResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'user': 'CustomFieldResponsePeopleValue', - 'workspace': 'GoalResponseWorkspace', - 'user_task_list': 'WorkspaceMembershipResponseUserTaskList', - 'is_active': 'bool', - 'is_admin': 'bool', - 'is_guest': 'bool', - 'vacation_dates': 'WorkspaceMembershipResponseVacationDates', - 'created_at': 'datetime' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'user': 'user', - 'workspace': 'workspace', - 'user_task_list': 'user_task_list', - 'is_active': 'is_active', - 'is_admin': 'is_admin', - 'is_guest': 'is_guest', - 'vacation_dates': 'vacation_dates', - 'created_at': 'created_at' - } - - def __init__(self, gid=None, resource_type=None, user=None, workspace=None, user_task_list=None, is_active=None, is_admin=None, is_guest=None, vacation_dates=None, created_at=None): # noqa: E501 - """WorkspaceMembershipResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._user = None - self._workspace = None - self._user_task_list = None - self._is_active = None - self._is_admin = None - self._is_guest = None - self._vacation_dates = None - self._created_at = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if user is not None: - self.user = user - if workspace is not None: - self.workspace = workspace - if user_task_list is not None: - self.user_task_list = user_task_list - if is_active is not None: - self.is_active = is_active - if is_admin is not None: - self.is_admin = is_admin - if is_guest is not None: - self.is_guest = is_guest - if vacation_dates is not None: - self.vacation_dates = vacation_dates - if created_at is not None: - self.created_at = created_at - - @property - def gid(self): - """Gets the gid of this WorkspaceMembershipResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this WorkspaceMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this WorkspaceMembershipResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this WorkspaceMembershipResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this WorkspaceMembershipResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this WorkspaceMembershipResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WorkspaceMembershipResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this WorkspaceMembershipResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def user(self): - """Gets the user of this WorkspaceMembershipResponse. # noqa: E501 - - - :return: The user of this WorkspaceMembershipResponse. # noqa: E501 - :rtype: CustomFieldResponsePeopleValue - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this WorkspaceMembershipResponse. - - - :param user: The user of this WorkspaceMembershipResponse. # noqa: E501 - :type: CustomFieldResponsePeopleValue - """ - - self._user = user - - @property - def workspace(self): - """Gets the workspace of this WorkspaceMembershipResponse. # noqa: E501 - - - :return: The workspace of this WorkspaceMembershipResponse. # noqa: E501 - :rtype: GoalResponseWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this WorkspaceMembershipResponse. - - - :param workspace: The workspace of this WorkspaceMembershipResponse. # noqa: E501 - :type: GoalResponseWorkspace - """ - - self._workspace = workspace - - @property - def user_task_list(self): - """Gets the user_task_list of this WorkspaceMembershipResponse. # noqa: E501 - - - :return: The user_task_list of this WorkspaceMembershipResponse. # noqa: E501 - :rtype: WorkspaceMembershipResponseUserTaskList - """ - return self._user_task_list - - @user_task_list.setter - def user_task_list(self, user_task_list): - """Sets the user_task_list of this WorkspaceMembershipResponse. - - - :param user_task_list: The user_task_list of this WorkspaceMembershipResponse. # noqa: E501 - :type: WorkspaceMembershipResponseUserTaskList - """ - - self._user_task_list = user_task_list - - @property - def is_active(self): - """Gets the is_active of this WorkspaceMembershipResponse. # noqa: E501 - - Reflects if this user still a member of the workspace. # noqa: E501 - - :return: The is_active of this WorkspaceMembershipResponse. # noqa: E501 - :rtype: bool - """ - return self._is_active - - @is_active.setter - def is_active(self, is_active): - """Sets the is_active of this WorkspaceMembershipResponse. - - Reflects if this user still a member of the workspace. # noqa: E501 - - :param is_active: The is_active of this WorkspaceMembershipResponse. # noqa: E501 - :type: bool - """ - - self._is_active = is_active - - @property - def is_admin(self): - """Gets the is_admin of this WorkspaceMembershipResponse. # noqa: E501 - - Reflects if this user is an admin of the workspace. # noqa: E501 - - :return: The is_admin of this WorkspaceMembershipResponse. # noqa: E501 - :rtype: bool - """ - return self._is_admin - - @is_admin.setter - def is_admin(self, is_admin): - """Sets the is_admin of this WorkspaceMembershipResponse. - - Reflects if this user is an admin of the workspace. # noqa: E501 - - :param is_admin: The is_admin of this WorkspaceMembershipResponse. # noqa: E501 - :type: bool - """ - - self._is_admin = is_admin - - @property - def is_guest(self): - """Gets the is_guest of this WorkspaceMembershipResponse. # noqa: E501 - - Reflects if this user is a guest of the workspace. # noqa: E501 - - :return: The is_guest of this WorkspaceMembershipResponse. # noqa: E501 - :rtype: bool - """ - return self._is_guest - - @is_guest.setter - def is_guest(self, is_guest): - """Sets the is_guest of this WorkspaceMembershipResponse. - - Reflects if this user is a guest of the workspace. # noqa: E501 - - :param is_guest: The is_guest of this WorkspaceMembershipResponse. # noqa: E501 - :type: bool - """ - - self._is_guest = is_guest - - @property - def vacation_dates(self): - """Gets the vacation_dates of this WorkspaceMembershipResponse. # noqa: E501 - - - :return: The vacation_dates of this WorkspaceMembershipResponse. # noqa: E501 - :rtype: WorkspaceMembershipResponseVacationDates - """ - return self._vacation_dates - - @vacation_dates.setter - def vacation_dates(self, vacation_dates): - """Sets the vacation_dates of this WorkspaceMembershipResponse. - - - :param vacation_dates: The vacation_dates of this WorkspaceMembershipResponse. # noqa: E501 - :type: WorkspaceMembershipResponseVacationDates - """ - - self._vacation_dates = vacation_dates - - @property - def created_at(self): - """Gets the created_at of this WorkspaceMembershipResponse. # noqa: E501 - - The time at which this resource was created. # noqa: E501 - - :return: The created_at of this WorkspaceMembershipResponse. # noqa: E501 - :rtype: datetime - """ - return self._created_at - - @created_at.setter - def created_at(self, created_at): - """Sets the created_at of this WorkspaceMembershipResponse. - - The time at which this resource was created. # noqa: E501 - - :param created_at: The created_at of this WorkspaceMembershipResponse. # noqa: E501 - :type: datetime - """ - - self._created_at = created_at - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceMembershipResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceMembershipResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_membership_response_array.py b/asana/models/workspace_membership_response_array.py deleted file mode 100644 index e512d15f..00000000 --- a/asana/models/workspace_membership_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceMembershipResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[WorkspaceMembershipResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """WorkspaceMembershipResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this WorkspaceMembershipResponseArray. # noqa: E501 - - - :return: The data of this WorkspaceMembershipResponseArray. # noqa: E501 - :rtype: list[WorkspaceMembershipResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this WorkspaceMembershipResponseArray. - - - :param data: The data of this WorkspaceMembershipResponseArray. # noqa: E501 - :type: list[WorkspaceMembershipResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this WorkspaceMembershipResponseArray. # noqa: E501 - - - :return: The next_page of this WorkspaceMembershipResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this WorkspaceMembershipResponseArray. - - - :param next_page: The next_page of this WorkspaceMembershipResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceMembershipResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceMembershipResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_membership_response_data.py b/asana/models/workspace_membership_response_data.py deleted file mode 100644 index 148cae3b..00000000 --- a/asana/models/workspace_membership_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceMembershipResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'WorkspaceMembershipResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """WorkspaceMembershipResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this WorkspaceMembershipResponseData. # noqa: E501 - - - :return: The data of this WorkspaceMembershipResponseData. # noqa: E501 - :rtype: WorkspaceMembershipResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this WorkspaceMembershipResponseData. - - - :param data: The data of this WorkspaceMembershipResponseData. # noqa: E501 - :type: WorkspaceMembershipResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceMembershipResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceMembershipResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_membership_response_user_task_list.py b/asana/models/workspace_membership_response_user_task_list.py deleted file mode 100644 index c8af3f51..00000000 --- a/asana/models/workspace_membership_response_user_task_list.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceMembershipResponseUserTaskList(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'owner': 'AllOfWorkspaceMembershipResponseUserTaskListOwner', - 'workspace': 'AllOfWorkspaceMembershipResponseUserTaskListWorkspace' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'owner': 'owner', - 'workspace': 'workspace' - } - - def __init__(self, gid=None, resource_type=None, name=None, owner=None, workspace=None): # noqa: E501 - """WorkspaceMembershipResponseUserTaskList - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._owner = None - self._workspace = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if owner is not None: - self.owner = owner - if workspace is not None: - self.workspace = workspace - - @property - def gid(self): - """Gets the gid of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this WorkspaceMembershipResponseUserTaskList. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WorkspaceMembershipResponseUserTaskList. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - - The name of the user task list. # noqa: E501 - - :return: The name of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this WorkspaceMembershipResponseUserTaskList. - - The name of the user task list. # noqa: E501 - - :param name: The name of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def owner(self): - """Gets the owner of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - - The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. # noqa: E501 - - :return: The owner of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - :rtype: AllOfWorkspaceMembershipResponseUserTaskListOwner - """ - return self._owner - - @owner.setter - def owner(self, owner): - """Sets the owner of this WorkspaceMembershipResponseUserTaskList. - - The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. # noqa: E501 - - :param owner: The owner of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - :type: AllOfWorkspaceMembershipResponseUserTaskListOwner - """ - - self._owner = owner - - @property - def workspace(self): - """Gets the workspace of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - - The workspace in which the user task list is located. # noqa: E501 - - :return: The workspace of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - :rtype: AllOfWorkspaceMembershipResponseUserTaskListWorkspace - """ - return self._workspace - - @workspace.setter - def workspace(self, workspace): - """Sets the workspace of this WorkspaceMembershipResponseUserTaskList. - - The workspace in which the user task list is located. # noqa: E501 - - :param workspace: The workspace of this WorkspaceMembershipResponseUserTaskList. # noqa: E501 - :type: AllOfWorkspaceMembershipResponseUserTaskListWorkspace - """ - - self._workspace = workspace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceMembershipResponseUserTaskList, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceMembershipResponseUserTaskList): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_membership_response_vacation_dates.py b/asana/models/workspace_membership_response_vacation_dates.py deleted file mode 100644 index bd911fe3..00000000 --- a/asana/models/workspace_membership_response_vacation_dates.py +++ /dev/null @@ -1,140 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceMembershipResponseVacationDates(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'start_on': 'str', - 'end_on': 'str' - } - - attribute_map = { - 'start_on': 'start_on', - 'end_on': 'end_on' - } - - def __init__(self, start_on=None, end_on=None): # noqa: E501 - """WorkspaceMembershipResponseVacationDates - a model defined in Swagger""" # noqa: E501 - self._start_on = None - self._end_on = None - self.discriminator = None - if start_on is not None: - self.start_on = start_on - if end_on is not None: - self.end_on = end_on - - @property - def start_on(self): - """Gets the start_on of this WorkspaceMembershipResponseVacationDates. # noqa: E501 - - The day on which the user's vacation in this workspace starts. This is a date with `YYYY-MM-DD` format. # noqa: E501 - - :return: The start_on of this WorkspaceMembershipResponseVacationDates. # noqa: E501 - :rtype: str - """ - return self._start_on - - @start_on.setter - def start_on(self, start_on): - """Sets the start_on of this WorkspaceMembershipResponseVacationDates. - - The day on which the user's vacation in this workspace starts. This is a date with `YYYY-MM-DD` format. # noqa: E501 - - :param start_on: The start_on of this WorkspaceMembershipResponseVacationDates. # noqa: E501 - :type: str - """ - - self._start_on = start_on - - @property - def end_on(self): - """Gets the end_on of this WorkspaceMembershipResponseVacationDates. # noqa: E501 - - The day on which the user's vacation in this workspace ends, or null if there is no end date. This is a date with `YYYY-MM-DD` format. # noqa: E501 - - :return: The end_on of this WorkspaceMembershipResponseVacationDates. # noqa: E501 - :rtype: str - """ - return self._end_on - - @end_on.setter - def end_on(self, end_on): - """Sets the end_on of this WorkspaceMembershipResponseVacationDates. - - The day on which the user's vacation in this workspace ends, or null if there is no end date. This is a date with `YYYY-MM-DD` format. # noqa: E501 - - :param end_on: The end_on of this WorkspaceMembershipResponseVacationDates. # noqa: E501 - :type: str - """ - - self._end_on = end_on - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceMembershipResponseVacationDates, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceMembershipResponseVacationDates): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_remove_user_request.py b/asana/models/workspace_remove_user_request.py deleted file mode 100644 index 6ee20782..00000000 --- a/asana/models/workspace_remove_user_request.py +++ /dev/null @@ -1,112 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceRemoveUserRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'user': 'str' - } - - attribute_map = { - 'user': 'user' - } - - def __init__(self, user=None): # noqa: E501 - """WorkspaceRemoveUserRequest - a model defined in Swagger""" # noqa: E501 - self._user = None - self.discriminator = None - if user is not None: - self.user = user - - @property - def user(self): - """Gets the user of this WorkspaceRemoveUserRequest. # noqa: E501 - - A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :return: The user of this WorkspaceRemoveUserRequest. # noqa: E501 - :rtype: str - """ - return self._user - - @user.setter - def user(self, user): - """Sets the user of this WorkspaceRemoveUserRequest. - - A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. # noqa: E501 - - :param user: The user of this WorkspaceRemoveUserRequest. # noqa: E501 - :type: str - """ - - self._user = user - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceRemoveUserRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceRemoveUserRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_request.py b/asana/models/workspace_request.py deleted file mode 100644 index adb7686e..00000000 --- a/asana/models/workspace_request.py +++ /dev/null @@ -1,168 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceRequest(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name' - } - - def __init__(self, gid=None, resource_type=None, name=None): # noqa: E501 - """WorkspaceRequest - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - - @property - def gid(self): - """Gets the gid of this WorkspaceRequest. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this WorkspaceRequest. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this WorkspaceRequest. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this WorkspaceRequest. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this WorkspaceRequest. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this WorkspaceRequest. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WorkspaceRequest. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this WorkspaceRequest. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this WorkspaceRequest. # noqa: E501 - - The name of the workspace. # noqa: E501 - - :return: The name of this WorkspaceRequest. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this WorkspaceRequest. - - The name of the workspace. # noqa: E501 - - :param name: The name of this WorkspaceRequest. # noqa: E501 - :type: str - """ - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceRequest, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceRequest): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_response.py b/asana/models/workspace_response.py deleted file mode 100644 index 0dd7a550..00000000 --- a/asana/models/workspace_response.py +++ /dev/null @@ -1,224 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceResponse(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'gid': 'str', - 'resource_type': 'str', - 'name': 'str', - 'email_domains': 'list[str]', - 'is_organization': 'bool' - } - - attribute_map = { - 'gid': 'gid', - 'resource_type': 'resource_type', - 'name': 'name', - 'email_domains': 'email_domains', - 'is_organization': 'is_organization' - } - - def __init__(self, gid=None, resource_type=None, name=None, email_domains=None, is_organization=None): # noqa: E501 - """WorkspaceResponse - a model defined in Swagger""" # noqa: E501 - self._gid = None - self._resource_type = None - self._name = None - self._email_domains = None - self._is_organization = None - self.discriminator = None - if gid is not None: - self.gid = gid - if resource_type is not None: - self.resource_type = resource_type - if name is not None: - self.name = name - if email_domains is not None: - self.email_domains = email_domains - if is_organization is not None: - self.is_organization = is_organization - - @property - def gid(self): - """Gets the gid of this WorkspaceResponse. # noqa: E501 - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :return: The gid of this WorkspaceResponse. # noqa: E501 - :rtype: str - """ - return self._gid - - @gid.setter - def gid(self, gid): - """Sets the gid of this WorkspaceResponse. - - Globally unique identifier of the resource, as a string. # noqa: E501 - - :param gid: The gid of this WorkspaceResponse. # noqa: E501 - :type: str - """ - - self._gid = gid - - @property - def resource_type(self): - """Gets the resource_type of this WorkspaceResponse. # noqa: E501 - - The base type of this resource. # noqa: E501 - - :return: The resource_type of this WorkspaceResponse. # noqa: E501 - :rtype: str - """ - return self._resource_type - - @resource_type.setter - def resource_type(self, resource_type): - """Sets the resource_type of this WorkspaceResponse. - - The base type of this resource. # noqa: E501 - - :param resource_type: The resource_type of this WorkspaceResponse. # noqa: E501 - :type: str - """ - - self._resource_type = resource_type - - @property - def name(self): - """Gets the name of this WorkspaceResponse. # noqa: E501 - - The name of the workspace. # noqa: E501 - - :return: The name of this WorkspaceResponse. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this WorkspaceResponse. - - The name of the workspace. # noqa: E501 - - :param name: The name of this WorkspaceResponse. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def email_domains(self): - """Gets the email_domains of this WorkspaceResponse. # noqa: E501 - - The email domains that are associated with this workspace. # noqa: E501 - - :return: The email_domains of this WorkspaceResponse. # noqa: E501 - :rtype: list[str] - """ - return self._email_domains - - @email_domains.setter - def email_domains(self, email_domains): - """Sets the email_domains of this WorkspaceResponse. - - The email domains that are associated with this workspace. # noqa: E501 - - :param email_domains: The email_domains of this WorkspaceResponse. # noqa: E501 - :type: list[str] - """ - - self._email_domains = email_domains - - @property - def is_organization(self): - """Gets the is_organization of this WorkspaceResponse. # noqa: E501 - - Whether the workspace is an *organization*. # noqa: E501 - - :return: The is_organization of this WorkspaceResponse. # noqa: E501 - :rtype: bool - """ - return self._is_organization - - @is_organization.setter - def is_organization(self, is_organization): - """Sets the is_organization of this WorkspaceResponse. - - Whether the workspace is an *organization*. # noqa: E501 - - :param is_organization: The is_organization of this WorkspaceResponse. # noqa: E501 - :type: bool - """ - - self._is_organization = is_organization - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceResponse, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceResponse): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_response_array.py b/asana/models/workspace_response_array.py deleted file mode 100644 index 9e4f59ec..00000000 --- a/asana/models/workspace_response_array.py +++ /dev/null @@ -1,137 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceResponseArray(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'list[WorkspaceResponse]', - 'next_page': 'NextPage' - } - - attribute_map = { - 'data': 'data', - 'next_page': 'next_page' - } - - def __init__(self, data=None, next_page=None): # noqa: E501 - """WorkspaceResponseArray - a model defined in Swagger""" # noqa: E501 - self._data = None - self._next_page = None - self.discriminator = None - self.data = data - if next_page is not None: - self.next_page = next_page - - @property - def data(self): - """Gets the data of this WorkspaceResponseArray. # noqa: E501 - - - :return: The data of this WorkspaceResponseArray. # noqa: E501 - :rtype: list[WorkspaceResponse] - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this WorkspaceResponseArray. - - - :param data: The data of this WorkspaceResponseArray. # noqa: E501 - :type: list[WorkspaceResponse] - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - @property - def next_page(self): - """Gets the next_page of this WorkspaceResponseArray. # noqa: E501 - - - :return: The next_page of this WorkspaceResponseArray. # noqa: E501 - :rtype: NextPage - """ - return self._next_page - - @next_page.setter - def next_page(self, next_page): - """Sets the next_page of this WorkspaceResponseArray. - - - :param next_page: The next_page of this WorkspaceResponseArray. # noqa: E501 - :type: NextPage - """ - - self._next_page = next_page - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceResponseArray, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceResponseArray): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspace_response_data.py b/asana/models/workspace_response_data.py deleted file mode 100644 index 87fa87d9..00000000 --- a/asana/models/workspace_response_data.py +++ /dev/null @@ -1,111 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspaceResponseData(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'WorkspaceResponse' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """WorkspaceResponseData - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - self.data = data - - @property - def data(self): - """Gets the data of this WorkspaceResponseData. # noqa: E501 - - - :return: The data of this WorkspaceResponseData. # noqa: E501 - :rtype: WorkspaceResponse - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this WorkspaceResponseData. - - - :param data: The data of this WorkspaceResponseData. # noqa: E501 - :type: WorkspaceResponse - """ - if data is None: - raise ValueError("Invalid value for `data`, must not be `None`") # noqa: E501 - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspaceResponseData, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspaceResponseData): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/models/workspaces_workspace_gid_body.py b/asana/models/workspaces_workspace_gid_body.py deleted file mode 100644 index 76840771..00000000 --- a/asana/models/workspaces_workspace_gid_body.py +++ /dev/null @@ -1,110 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -import pprint -import re # noqa: F401 - -import six - -class WorkspacesWorkspaceGidBody(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - """ - """ - Attributes: - swagger_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - swagger_types = { - 'data': 'WorkspaceRequest' - } - - attribute_map = { - 'data': 'data' - } - - def __init__(self, data=None): # noqa: E501 - """WorkspacesWorkspaceGidBody - a model defined in Swagger""" # noqa: E501 - self._data = None - self.discriminator = None - if data is not None: - self.data = data - - @property - def data(self): - """Gets the data of this WorkspacesWorkspaceGidBody. # noqa: E501 - - - :return: The data of this WorkspacesWorkspaceGidBody. # noqa: E501 - :rtype: WorkspaceRequest - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this WorkspacesWorkspaceGidBody. - - - :param data: The data of this WorkspacesWorkspaceGidBody. # noqa: E501 - :type: WorkspaceRequest - """ - - self._data = data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.swagger_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - if issubclass(WorkspacesWorkspaceGidBody, dict): - for key, value in self.items(): - result[key] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, WorkspacesWorkspaceGidBody): - return False - - return self.__dict__ == other.__dict__ - - def __ne__(self, other): - """Returns true if both objects are not equal""" - return not self == other diff --git a/asana/page_iterator.py b/asana/page_iterator.py new file mode 100644 index 00000000..313c1d33 --- /dev/null +++ b/asana/page_iterator.py @@ -0,0 +1,134 @@ + +from .error import InvalidTokenError +import time + +class PageIterator(object): + """Generic page iterator class, used for collections and events""" + + def __init__(self, client, path, query, options): + self.client = client + self.path = path + self.query = query + self.options = client._merge_options(options, { 'full_payload': True }) + + self.item_limit = float('inf') if self.options.get('item_limit', None) == None else self.options['item_limit'] + self.page_size = self.options['page_size'] + self.count = 0 + + self.continuation = False + + def __getattr__(self, name): + """Getter for the custom named 'continuation' object.""" + if name == self.CONTINUATION_KEY: + return self.continuation + raise AttributeError("%r object has no attribute %r" % (self.__class__, attr)) + + def __iter__(self): + """Iterator interface, self is an iterator""" + return self + + def __next__(self): + """Iterator interface, returns the next 'page'""" + + # Compute the limit from the page size, and remaining item limit + self.options['limit'] = min(self.page_size, self.item_limit - self.count) + # If there is no continuation value or computed limit is 0, we're done + if self.continuation == None or self.options['limit'] == 0: + raise StopIteration + # First call to __next__ + elif self.continuation == False: + result = self.get_initial() + # Subsequent calls to __next__ + else: + result = self.get_next() + # Extract the continuation from the response + self.continuation = result.get(self.CONTINUATION_KEY, None) + # Get the data, update the count, return the data + data = result.get('data', None) + if data != None: + self.count += len(data) + return data + + def next(self): + """Alias for __next__""" + return self.__next__() + + def items(self): + """Returns an iterator for each item in each page""" + for page in self: + for item in page: + yield item + + +class CollectionPageIterator(PageIterator): + """Iterator that returns one page of a collection at a time""" + + CONTINUATION_KEY = 'next_page' + + def get_initial(self): + return self.client.get(self.path, self.query, **self.options) + + def get_next(self): + self.options['offset'] = self.continuation['offset'] + return self.client.get(self.path, self.query, **self.options) + + +class EventsPageIterator(PageIterator): + """Iterator that returns the next page of events, polls until a non-empty page is returned""" + + CONTINUATION_KEY = 'sync' + + def get_initial(self): + # If no sync token was provided, make a request to get one + if 'sync' not in self.query: + try: + self.client.events.get(self.query, **self.options) + except InvalidTokenError as e: + # InvalidTokenError is expected to be thrown since we didn't provide a sync token + self.continuation = e.sync + else: + self.continuation = self.query['sync'] + return self.get_next() + + def get_next(self): + self.query['sync'] = self.continuation + return self.client.events.get(self.query, **self.options) + + def __next__(self): + # Override __next__ to continue polling until a non-empty page of events is returned + while True: + results = super(EventsPageIterator, self).__next__() + if len(results) > 0: + return results + else: + time.sleep(self.options['poll_interval']) + + +class AuditLogAPIIterator(CollectionPageIterator): + """Iterator that returns the next page of audit_log_api""" + + def __next__(self): + """Override __next__ to stop when there is no more data""" + + # Compute the limit from the page size, and remaining item limit + self.options['limit'] = min( + self.page_size, self.item_limit - self.count) + # If there is no continuation value or computed limit is 0, we're done + if self.continuation == None or self.options['limit'] == 0: + raise StopIteration + # First call to __next__ + elif self.continuation == False: + result = self.get_initial() + # Subsequent calls to __next__ + else: + result = self.get_next() + # Extract the continuation from the response + self.continuation = result.get(self.CONTINUATION_KEY, None) + # Get the data + data = result.get('data', None) + # If there is no more data we're done. Otherwise, we update the count and return the data + if not data: + raise StopIteration + else: + self.count += len(data) + return data diff --git a/asana/resources/__init__.py b/asana/resources/__init__.py new file mode 100644 index 00000000..58f3953f --- /dev/null +++ b/asana/resources/__init__.py @@ -0,0 +1,35 @@ +from . import ( + attachments, + audit_log_api, + batch_api, + custom_field_settings, + custom_fields, + events, + goal_relationships, + goals, + jobs, + memberships, + message, + organization_exports, + portfolios, + portfolio_memberships, + project_briefs, + project_memberships, + project_statuses, + project_templates, + projects, + sections, + status_updates, + stories, + tags, + tasks, + teams, + time_periods, + team_memberships, + typeahead, + users, + user_task_lists, + webhooks, + workspace_memberships, + workspaces +) diff --git a/asana/resources/attachments.py b/asana/resources/attachments.py new file mode 100644 index 00000000..9d44ddde --- /dev/null +++ b/asana/resources/attachments.py @@ -0,0 +1,36 @@ + +from .gen.attachments import _Attachments + +class Attachments(_Attachments): + """Attachments resource""" + + def create_attachment_for_task(self, task_id, file_content, file_name, file_content_type=None, **options): + """Upload an attachment for a task. Accepts a file object or string, file name, and optional file Content-Type""" + path = '/tasks/%s/attachments' % (task_id) + return self.client.request('post', path, files=[('file', (file_name, file_content, file_content_type))], **options) + + def create_on_task(self, task_id, file_content, file_name, file_content_type=None, **options): + path = '/tasks/%s/attachments' % (task_id) + return self.client.request('post', path, files=[('file', (file_name, file_content, file_content_type))], **options) + + def find_by_id(self, attachment, params={}, **options): + """Returns the full record for a single attachment. + + Parameters + ---------- + attachment : {Gid} Globally unique identifier for the attachment. + [params] : {Object} Parameters for the request + """ + path = "/attachments/%s" % (attachment) + return self.client.get(path, params, **options) + + def find_by_task(self, task, params={}, **options): + """Returns the compact records for all attachments on the task. + + Parameters + ---------- + task : {Gid} Globally unique identifier for the task. + [params] : {Object} Parameters for the request + """ + path = "/tasks/%s/attachments" % (task) + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/audit_log_api.py b/asana/resources/audit_log_api.py new file mode 100644 index 00000000..43c3e30f --- /dev/null +++ b/asana/resources/audit_log_api.py @@ -0,0 +1,19 @@ + +from .gen.audit_log_api import _AuditLogAPI +from ..page_iterator import AuditLogAPIIterator + + +class AuditLogAPI(_AuditLogAPI): + """AuditLogAPI resource""" + + def get_audit_log_events(self, workspace_gid, params={}, **options): + """Override get_audit_log_events to handle non-empty next_page parameter""" + path = "/workspaces/{workspace_gid}/audit_log_events".replace( + "{workspace_gid}", workspace_gid) + options = self.client._merge_options(options) + if options['iterator_type'] == 'items': + return AuditLogAPIIterator(self.client, path, params, options).items() + if options['iterator_type'] is None: + return self.client.get(path, params, **options) + raise Exception('Unknown value for "iterator_type" option: {}'.format( + str(options['iterator_type']))) diff --git a/asana/resources/batch_api.py b/asana/resources/batch_api.py new file mode 100644 index 00000000..c9f1954a --- /dev/null +++ b/asana/resources/batch_api.py @@ -0,0 +1,6 @@ + +from .gen.batch_api import _BatchAPI + +class BatchAPI(_BatchAPI): + """BatchAPI resource""" + pass diff --git a/asana/resources/custom_field_settings.py b/asana/resources/custom_field_settings.py new file mode 100644 index 00000000..e524ba29 --- /dev/null +++ b/asana/resources/custom_field_settings.py @@ -0,0 +1,26 @@ + +from .gen.custom_field_settings import _CustomFieldSettings + +class CustomFieldSettings(_CustomFieldSettings): + """Custom Field Settings resource""" + def find_by_project(self, project, params={}, **options): + """Returns a list of all of the custom fields settings on a project. + + Parameters + ---------- + project : {Gid} The ID of the project for which to list custom field settings + [params] : {Object} Parameters for the request + """ + path = "/projects/%s/custom_field_settings" % (project) + return self.client.get_collection(path, params, **options) + + def find_by_portfolio(self, portfolio, params={}, **options): + """Returns a list of all of the custom fields settings on a portfolio. + + Parameters + ---------- + portfolio : {Gid} The ID of the portfolio for which to list custom field settings + [params] : {Object} Parameters for the request + """ + path = "/portfolios/%s/custom_field_settings" % (portfolio) + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/custom_fields.py b/asana/resources/custom_fields.py new file mode 100644 index 00000000..45008c36 --- /dev/null +++ b/asana/resources/custom_fields.py @@ -0,0 +1,140 @@ + +from .gen.custom_fields import _CustomFields + +class CustomFields(_CustomFields): + """Custom Fields resource""" + def add_enum_option(self, custom_field, params={}, **options): + self.create_enum_option(custom_field, params, **options) + + def reorder_enum_option(self, custom_field, params={}, **options): + self.insert_enum_option(custom_field, params, **options) + + def create(self, params={}, **options): + """Creates a new custom field in a workspace. Every custom field is required to be created in a specific workspace, and this workspace cannot be changed once set. + + A custom field's `name` must be unique within a workspace and not conflict with names of existing task properties such as 'Due Date' or 'Assignee'. A custom field's `type` must be one of 'text', 'enum', or 'number'. + + Returns the full record of the newly created custom field. + + Parameters + ---------- + [data] : {Object} Data for the request + - workspace : {Gid} The workspace to create a custom field in. + - resource_subtype : {String} The type of the custom field. Must be one of the given values. + - [type] : {String} **Deprecated: New integrations should prefer the `resource_subtype` parameter.** + - name : {String} The name of the custom field. + - [description] : {String} The description of the custom field. + - [precision] : {Integer} The number of decimal places for the numerical values. Required if the custom field is of type 'number'. + - [enum_options] : {String} The discrete values the custom field can assume. Required if the custom field is of type 'enum'. + """ + return self.client.post("/custom_fields", params, **options) + + def find_by_id(self, custom_field, params={}, **options): + """Returns the complete definition of a custom field's metadata. + + Parameters + ---------- + custom_field : {Gid} Globally unique identifier for the custom field. + [params] : {Object} Parameters for the request + """ + path = "/custom_fields/%s" % (custom_field) + return self.client.get(path, params, **options) + + def find_by_workspace(self, workspace, params={}, **options): + """Returns a list of the compact representation of all of the custom fields in a workspace. + + Parameters + ---------- + workspace : {Gid} The workspace or organization to find custom field definitions in. + [params] : {Object} Parameters for the request + """ + path = "/workspaces/%s/custom_fields" % (workspace) + return self.client.get_collection(path, params, **options) + + def update(self, custom_field, params={}, **options): + """A specific, existing custom field can be updated by making a PUT request on the URL for that custom field. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged + + When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the custom field. + + An enum custom field's `enum_options` cannot be updated with this endpoint. Instead see "Work With Enum Options" for information on how to update `enum_options`. + + Locked custom fields can only be updated by the user who locked the field. + + Returns the complete updated custom field record. + + Parameters + ---------- + custom_field : {Gid} Globally unique identifier for the custom field. + [data] : {Object} Data for the request + """ + path = "/custom_fields/%s" % (custom_field) + return self.client.put(path, params, **options) + + def delete(self, custom_field, params={}, **options): + """A specific, existing custom field can be deleted by making a DELETE request on the URL for that custom field. + + Locked custom fields can only be deleted by the user who locked the field. + + Returns an empty data record. + + Parameters + ---------- + custom_field : {Gid} Globally unique identifier for the custom field. + """ + path = "/custom_fields/%s" % (custom_field) + return self.client.delete(path, params, **options) + + def create_enum_option(self, custom_field, params={}, **options): + """Creates an enum option and adds it to this custom field's list of enum options. A custom field can have at most 50 enum options (including disabled options). By default new enum options are inserted at the end of a custom field's list. + + Locked custom fields can only have enum options added by the user who locked the field. + + Returns the full record of the newly created enum option. + + Parameters + ---------- + custom_field : {Gid} Globally unique identifier for the custom field. + [data] : {Object} Data for the request + - name : {String} The name of the enum option. + - [color] : {String} The color of the enum option. Defaults to 'none'. + - [insert_before] : {Gid} An existing enum option within this custom field before which the new enum option should be inserted. Cannot be provided together with after_enum_option. + - [insert_after] : {Gid} An existing enum option within this custom field after which the new enum option should be inserted. Cannot be provided together with before_enum_option. + """ + path = "/custom_fields/%s/enum_options" % (custom_field) + return self.client.post(path, params, **options) + + def update_enum_option(self, enum_option, params={}, **options): + """Updates an existing enum option. Enum custom fields require at least one enabled enum option. + + Locked custom fields can only be updated by the user who locked the field. + + Returns the full record of the updated enum option. + + Parameters + ---------- + enum_option : {Gid} Globally unique identifier for the enum option. + [data] : {Object} Data for the request + - name : {String} The name of the enum option. + - [color] : {String} The color of the enum option. Defaults to 'none'. + - [enabled] : {Boolean} Whether or not the enum option is a selectable value for the custom field. + """ + path = "/enum_options/%s" % (enum_option) + return self.client.put(path, params, **options) + + def insert_enum_option(self, custom_field, params={}, **options): + """Moves a particular enum option to be either before or after another specified enum option in the custom field. + + Locked custom fields can only be reordered by the user who locked the field. + + Parameters + ---------- + custom_field : {Gid} Globally unique identifier for the custom field. + [data] : {Object} Data for the request + - enum_option : {Gid} The ID of the enum option to relocate. + - name : {String} The name of the enum option. + - [color] : {String} The color of the enum option. Defaults to 'none'. + - [before_enum_option] : {Gid} An existing enum option within this custom field before which the new enum option should be inserted. Cannot be provided together with after_enum_option. + - [after_enum_option] : {Gid} An existing enum option within this custom field after which the new enum option should be inserted. Cannot be provided together with before_enum_option. + """ + path = "/custom_fields/%s/enum_options/insert" % (custom_field) + return self.client.post(path, params, **options) diff --git a/asana/resources/events.py b/asana/resources/events.py new file mode 100644 index 00000000..dc1643ac --- /dev/null +++ b/asana/resources/events.py @@ -0,0 +1,22 @@ + +from .gen.events import _Events +from ..error import InvalidTokenError +from ..page_iterator import EventsPageIterator + +class Events(_Events): + """Events resource""" + + def get(self, params, **options): + """Dispatches a GET request to /events of the API to get a set of recent changes to a resource.""" + options = self.client._merge_options({ 'full_payload': True }) + return self.client.get('/events', params, **options) + + def get_next(self, query, **options): + """Returns a tuple containing the next page of events and a sync token for the given query (and optional 'sync' token)""" + iterator = EventsPageIterator(self.client, '/events', query, options) + result = next(iterator) + return (result, iterator.sync) + + def get_iterator(self, query, **options): + """Returns an event iterator for the given query (and optional 'sync' token)""" + return EventsPageIterator(self.client, '/events', query, options).items() diff --git a/asana/resources/gen/__init__.py b/asana/resources/gen/__init__.py new file mode 100644 index 00000000..2786f20b --- /dev/null +++ b/asana/resources/gen/__init__.py @@ -0,0 +1,32 @@ +from . import ( + attachments, + audit_log_api, + batch_api, + custom_field_settings, + custom_fields, + events, + goals, + jobs, + organization_exports, + portfolios, + portfolio_memberships, + project_briefs, + project_memberships, + project_statuses, + project_templates, + projects, + sections, + status_updates, + stories, + tags, + tasks, + team_memberships, + teams, + time_periods, + typeahead, + users, + user_task_lists, + webhooks, + workspace_memberships, + workspaces +) diff --git a/asana/resources/gen/attachments.py b/asana/resources/gen/attachments.py new file mode 100644 index 00000000..cb5f2998 --- /dev/null +++ b/asana/resources/gen/attachments.py @@ -0,0 +1,49 @@ +# coding=utf-8 +class _Attachments: + + def __init__(self, client=None): + self.client = client + + def delete_attachment(self, attachment_gid, params=None, **options): + """Delete an attachment + :param str attachment_gid: (required) Globally unique identifier for the attachment. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/attachments/{attachment_gid}".replace("{attachment_gid}", attachment_gid) + return self.client.delete(path, params, **options) + + def get_attachment(self, attachment_gid, params=None, **options): + """Get an attachment + :param str attachment_gid: (required) Globally unique identifier for the attachment. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/attachments/{attachment_gid}".replace("{attachment_gid}", attachment_gid) + return self.client.get(path, params, **options) + + def get_attachments_for_object(self, params=None, **options): + """Get attachments from an object + :param Object params: Parameters for the request + - parent {str}: (required) Globally unique identifier for object to fetch statuses from. Must be a GID for a `project`, `project_brief`, or `task`. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/attachments" + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/gen/audit_log_api.py b/asana/resources/gen/audit_log_api.py new file mode 100644 index 00000000..36c81cc3 --- /dev/null +++ b/asana/resources/gen/audit_log_api.py @@ -0,0 +1,25 @@ +# coding=utf-8 +class _AuditLogAPI: + + def __init__(self, client=None): + self.client = client + + def get_audit_log_events(self, workspace_gid, params=None, **options): + """Get audit log events + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + - start_at {datetime}: Filter to events created after this time (inclusive). + - end_at {datetime}: Filter to events created before this time (exclusive). + - event_type {str}: Filter to events of this type. Refer to the [supported audit log events](/docs/audit-log-events#supported-audit-log-events) for a full list of values. + - actor_type {str}: Filter to events with an actor of this type. This only needs to be included if querying for actor types without an ID. If `actor_gid` is included, this should be excluded. + - actor_gid {str}: Filter to events triggered by the actor with this ID. + - resource_gid {str}: Filter to events with this resource ID. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}/audit_log_events".replace("{workspace_gid}", workspace_gid) + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/gen/batch_api.py b/asana/resources/gen/batch_api.py new file mode 100644 index 00000000..3652b3d3 --- /dev/null +++ b/asana/resources/gen/batch_api.py @@ -0,0 +1,18 @@ +# coding=utf-8 +class _BatchAPI: + + def __init__(self, client=None): + self.client = client + + def create_batch_request(self, params=None, **options): + """Submit parallel requests + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/batch" + return self.client.post(path, params, **options) diff --git a/asana/resources/gen/custom_field_settings.py b/asana/resources/gen/custom_field_settings.py new file mode 100644 index 00000000..563a68c3 --- /dev/null +++ b/asana/resources/gen/custom_field_settings.py @@ -0,0 +1,37 @@ +# coding=utf-8 +class _CustomFieldSettings: + + def __init__(self, client=None): + self.client = client + + def get_custom_field_settings_for_portfolio(self, portfolio_gid, params=None, **options): + """Get a portfolio's custom fields + :param str portfolio_gid: (required) Globally unique identifier for the portfolio. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios/{portfolio_gid}/custom_field_settings".replace("{portfolio_gid}", portfolio_gid) + return self.client.get_collection(path, params, **options) + + def get_custom_field_settings_for_project(self, project_gid, params=None, **options): + """Get a project's custom fields + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/custom_field_settings".replace("{project_gid}", project_gid) + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/gen/custom_fields.py b/asana/resources/gen/custom_fields.py new file mode 100644 index 00000000..ba1a673e --- /dev/null +++ b/asana/resources/gen/custom_fields.py @@ -0,0 +1,122 @@ +# coding=utf-8 +class _CustomFields: + + def __init__(self, client=None): + self.client = client + + def create_custom_field(self, params=None, **options): + """Create a custom field + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/custom_fields" + return self.client.post(path, params, **options) + + def create_enum_option_for_custom_field(self, custom_field_gid, params=None, **options): + """Create an enum option + :param str custom_field_gid: (required) Globally unique identifier for the custom field. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/custom_fields/{custom_field_gid}/enum_options".replace("{custom_field_gid}", custom_field_gid) + return self.client.post(path, params, **options) + + def delete_custom_field(self, custom_field_gid, params=None, **options): + """Delete a custom field + :param str custom_field_gid: (required) Globally unique identifier for the custom field. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/custom_fields/{custom_field_gid}".replace("{custom_field_gid}", custom_field_gid) + return self.client.delete(path, params, **options) + + def get_custom_field(self, custom_field_gid, params=None, **options): + """Get a custom field + :param str custom_field_gid: (required) Globally unique identifier for the custom field. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/custom_fields/{custom_field_gid}".replace("{custom_field_gid}", custom_field_gid) + return self.client.get(path, params, **options) + + def get_custom_fields_for_workspace(self, workspace_gid, params=None, **options): + """Get a workspace's custom fields + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}/custom_fields".replace("{workspace_gid}", workspace_gid) + return self.client.get_collection(path, params, **options) + + def insert_enum_option_for_custom_field(self, custom_field_gid, params=None, **options): + """Reorder a custom field's enum + :param str custom_field_gid: (required) Globally unique identifier for the custom field. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/custom_fields/{custom_field_gid}/enum_options/insert".replace("{custom_field_gid}", custom_field_gid) + return self.client.post(path, params, **options) + + def update_custom_field(self, custom_field_gid, params=None, **options): + """Update a custom field + :param str custom_field_gid: (required) Globally unique identifier for the custom field. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/custom_fields/{custom_field_gid}".replace("{custom_field_gid}", custom_field_gid) + return self.client.put(path, params, **options) + + def update_enum_option(self, enum_option_gid, params=None, **options): + """Update an enum option + :param str enum_option_gid: (required) Globally unique identifier for the enum option. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/enum_options/{enum_option_gid}".replace("{enum_option_gid}", enum_option_gid) + return self.client.put(path, params, **options) diff --git a/asana/resources/gen/events.py b/asana/resources/gen/events.py new file mode 100644 index 00000000..5ba54075 --- /dev/null +++ b/asana/resources/gen/events.py @@ -0,0 +1,20 @@ +# coding=utf-8 +class _Events: + + def __init__(self, client=None): + self.client = client + + def get_events(self, params=None, **options): + """Get events on a resource + :param Object params: Parameters for the request + - resource {str}: (required) A resource ID to subscribe to. The resource can be a task or project. + - sync {str}: A sync token received from the last request, or none on first sync. Events will be returned from the point in time that the sync token was generated. *Note: On your first request, omit the sync token. The response will be the same as for an expired sync token, and will include a new valid sync token.If the sync token is too old (which may happen from time to time) the API will return a `412 Precondition Failed` error, and include a fresh sync token in the response.* + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/events" + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/gen/goal_relationships.py b/asana/resources/gen/goal_relationships.py new file mode 100644 index 00000000..e5ee197c --- /dev/null +++ b/asana/resources/gen/goal_relationships.py @@ -0,0 +1,76 @@ +# coding=utf-8 +class _GoalRelationships: + + def __init__(self, client=None): + self.client = client + + def add_supporting_relationship(self, goal_gid, params=None, **options): + """Add a supporting goal relationship + :param str goal_gid: (required) Globally unique identifier for the goal. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goals/{goal_gid}/addSupportingRelationship".replace("{goal_gid}", goal_gid) + return self.client.post(path, params, **options) + + def get_goal_relationship(self, goal_relationship_gid, params=None, **options): + """Get a goal relationship + :param str goal_relationship_gid: (required) Globally unique identifier for the goal relationship. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goal_relationships/{goal_relationship_gid}".replace("{goal_relationship_gid}", goal_relationship_gid) + return self.client.get(path, params, **options) + + def get_goal_relationships(self, params=None, **options): + """Get goal relationships + :param Object params: Parameters for the request + - supported_goal {str}: (required) Globally unique identifier for the supported goal in the goal relationship. + - resource_subtype {str}: If provided, filter to goal relationships with a given resource_subtype. + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goal_relationships" + return self.client.get_collection(path, params, **options) + + def remove_supporting_relationship(self, goal_gid, params=None, **options): + """Removes a supporting goal relationship + :param str goal_gid: (required) Globally unique identifier for the goal. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goals/{goal_gid}/removeSupportingRelationship".replace("{goal_gid}", goal_gid) + return self.client.post(path, params, **options) + + def update_goal_relationship(self, goal_relationship_gid, params=None, **options): + """Update a goal relationship + :param str goal_relationship_gid: (required) Globally unique identifier for the goal relationship. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goal_relationships/{goal_relationship_gid}".replace("{goal_relationship_gid}", goal_relationship_gid) + return self.client.put(path, params, **options) diff --git a/asana/resources/gen/goals.py b/asana/resources/gen/goals.py new file mode 100644 index 00000000..79e47743 --- /dev/null +++ b/asana/resources/gen/goals.py @@ -0,0 +1,153 @@ +# coding=utf-8 +class _Goals: + + def __init__(self, client=None): + self.client = client + + def add_followers(self, goal_gid, params=None, **options): + """Add a collaborator to a goal + :param str goal_gid: (required) Globally unique identifier for the goal. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goals/{goal_gid}/addFollowers".replace("{goal_gid}", goal_gid) + return self.client.post(path, params, **options) + + def create_goal(self, params=None, **options): + """Create a goal + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goals" + return self.client.post(path, params, **options) + + def create_goal_metric(self, goal_gid, params=None, **options): + """Create a goal metric + :param str goal_gid: (required) Globally unique identifier for the goal. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goals/{goal_gid}/setMetric".replace("{goal_gid}", goal_gid) + return self.client.post(path, params, **options) + + def delete_goal(self, goal_gid, params=None, **options): + """Delete a goal + :param str goal_gid: (required) Globally unique identifier for the goal. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goals/{goal_gid}".replace("{goal_gid}", goal_gid) + return self.client.delete(path, params, **options) + + def get_goal(self, goal_gid, params=None, **options): + """Get a goal + :param str goal_gid: (required) Globally unique identifier for the goal. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goals/{goal_gid}".replace("{goal_gid}", goal_gid) + return self.client.get(path, params, **options) + + def get_goals(self, params=None, **options): + """Get goals + :param Object params: Parameters for the request + - portfolio {str}: Globally unique identifier for supporting portfolio. + - project {str}: Globally unique identifier for supporting project. + - is_workspace_level {bool}: Filter to goals with is_workspace_level set to query value. Must be used with the workspace parameter. + - team {str}: Globally unique identifier for the team. + - workspace {str}: Globally unique identifier for the workspace. + - time_periods {list[str]}: Globally unique identifiers for the time periods. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goals" + return self.client.get_collection(path, params, **options) + + def get_parent_goals_for_goal(self, goal_gid, params=None, **options): + """Get parent goals from a goal + :param str goal_gid: (required) Globally unique identifier for the goal. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goals/{goal_gid}/parentGoals".replace("{goal_gid}", goal_gid) + return self.client.get_collection(path, params, **options) + + def remove_followers(self, goal_gid, params=None, **options): + """Remove a collaborator from a goal + :param str goal_gid: (required) Globally unique identifier for the goal. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goals/{goal_gid}/removeFollowers".replace("{goal_gid}", goal_gid) + return self.client.post(path, params, **options) + + def update_goal(self, goal_gid, params=None, **options): + """Update a goal + :param str goal_gid: (required) Globally unique identifier for the goal. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goals/{goal_gid}".replace("{goal_gid}", goal_gid) + return self.client.put(path, params, **options) + + def update_goal_metric(self, goal_gid, params=None, **options): + """Update a goal metric + :param str goal_gid: (required) Globally unique identifier for the goal. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/goals/{goal_gid}/setMetricCurrentValue".replace("{goal_gid}", goal_gid) + return self.client.post(path, params, **options) diff --git a/asana/resources/gen/jobs.py b/asana/resources/gen/jobs.py new file mode 100644 index 00000000..2c1d7027 --- /dev/null +++ b/asana/resources/gen/jobs.py @@ -0,0 +1,19 @@ +# coding=utf-8 +class _Jobs: + + def __init__(self, client=None): + self.client = client + + def get_job(self, job_gid, params=None, **options): + """Get a job by id + :param str job_gid: (required) Globally unique identifier for the job. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/jobs/{job_gid}".replace("{job_gid}", job_gid) + return self.client.get(path, params, **options) diff --git a/asana/resources/gen/memberships.py b/asana/resources/gen/memberships.py new file mode 100644 index 00000000..64a222a9 --- /dev/null +++ b/asana/resources/gen/memberships.py @@ -0,0 +1,65 @@ +# coding=utf-8 +class _Memberships: + + def __init__(self, client=None): + self.client = client + + def create_membership(self, params=None, **options): + """Create a membership + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/memberships" + return self.client.post(path, params, **options) + + def delete_membership(self, membership_gid, params=None, **options): + """Delete a membership + :param str membership_gid: (required) Globally unique identifier for the membership. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/memberships/{membership_gid}".replace("{membership_gid}", membership_gid) + return self.client.delete(path, params, **options) + + def get_memberships(self, params=None, **options): + """Get multiple memberships + :param Object params: Parameters for the request + - parent {str}: Globally unique identifier for `project`, `portfolio`, `team`, `goal`, and `workspace`. + - member {str}: Globally unique identifier for `team` or `user`. + - resource_subtype {str}: The resource_subtype to filter on. Must be provided with `member` and `workspace` if `parent` is not provided. Valid values include `team_membership`, `workspace_membership`, `portfolio_membership` + - workspace {str}: The workspace to filter on. Must be provided with `member` and `resource_subtype` if `parent` is not provided. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Pagination limit for the request. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/memberships" + return self.client.get_collection(path, params, **options) + + def update_membership(self, membership_gid, params=None, **options): + """Update a membership + :param str membership_gid: (required) Globally unique identifier for the membership. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/memberships/{membership_gid}".replace("{membership_gid}", membership_gid) + return self.client.put(path, params, **options) diff --git a/asana/resources/gen/message.py b/asana/resources/gen/message.py new file mode 100644 index 00000000..13791545 --- /dev/null +++ b/asana/resources/gen/message.py @@ -0,0 +1,19 @@ +# coding=utf-8 +class _Message: + + def __init__(self, client=None): + self.client = client + + def get_message(self, message_gid, params=None, **options): + """Get a message + :param str message_gid: (required) The message to get. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/messages/{message_gid}".replace("{message_gid}", message_gid) + return self.client.get(path, params, **options) diff --git a/asana/resources/gen/organization_exports.py b/asana/resources/gen/organization_exports.py new file mode 100644 index 00000000..0c196941 --- /dev/null +++ b/asana/resources/gen/organization_exports.py @@ -0,0 +1,34 @@ +# coding=utf-8 +class _OrganizationExports: + + def __init__(self, client=None): + self.client = client + + def create_organization_export(self, params=None, **options): + """Create an organization export request + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/organization_exports" + return self.client.post(path, params, **options) + + def get_organization_export(self, organization_export_gid, params=None, **options): + """Get details on an org export request + :param str organization_export_gid: (required) Globally unique identifier for the organization export. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/organization_exports/{organization_export_gid}".replace("{organization_export_gid}", organization_export_gid) + return self.client.get(path, params, **options) diff --git a/asana/resources/gen/portfolio_memberships.py b/asana/resources/gen/portfolio_memberships.py new file mode 100644 index 00000000..bbae489d --- /dev/null +++ b/asana/resources/gen/portfolio_memberships.py @@ -0,0 +1,54 @@ +# coding=utf-8 +class _PortfolioMemberships: + + def __init__(self, client=None): + self.client = client + + def get_portfolio_membership(self, portfolio_membership_gid, params=None, **options): + """Get a portfolio membership + :param str portfolio_membership_gid: (required) + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolio_memberships/{portfolio_membership_gid}".replace("{portfolio_membership_gid}", portfolio_membership_gid) + return self.client.get(path, params, **options) + + def get_portfolio_memberships(self, params=None, **options): + """Get multiple portfolio memberships + :param Object params: Parameters for the request + - portfolio {str}: The portfolio to filter results on. + - workspace {str}: The workspace to filter results on. + - user {str}: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolio_memberships" + return self.client.get_collection(path, params, **options) + + def get_portfolio_memberships_for_portfolio(self, portfolio_gid, params=None, **options): + """Get memberships from a portfolio + :param str portfolio_gid: (required) Globally unique identifier for the portfolio. + :param Object params: Parameters for the request + - user {str}: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios/{portfolio_gid}/portfolio_memberships".replace("{portfolio_gid}", portfolio_gid) + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/gen/portfolios.py b/asana/resources/gen/portfolios.py new file mode 100644 index 00000000..5ec3d557 --- /dev/null +++ b/asana/resources/gen/portfolios.py @@ -0,0 +1,175 @@ +# coding=utf-8 +class _Portfolios: + + def __init__(self, client=None): + self.client = client + + def add_custom_field_setting_for_portfolio(self, portfolio_gid, params=None, **options): + """Add a custom field to a portfolio + :param str portfolio_gid: (required) Globally unique identifier for the portfolio. + :param Object params: Parameters for the request + :param **options + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios/{portfolio_gid}/addCustomFieldSetting".replace("{portfolio_gid}", portfolio_gid) + return self.client.post(path, params, **options) + + def add_item_for_portfolio(self, portfolio_gid, params=None, **options): + """Add a portfolio item + :param str portfolio_gid: (required) Globally unique identifier for the portfolio. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios/{portfolio_gid}/addItem".replace("{portfolio_gid}", portfolio_gid) + return self.client.post(path, params, **options) + + def add_members_for_portfolio(self, portfolio_gid, params=None, **options): + """Add users to a portfolio + :param str portfolio_gid: (required) Globally unique identifier for the portfolio. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios/{portfolio_gid}/addMembers".replace("{portfolio_gid}", portfolio_gid) + return self.client.post(path, params, **options) + + def create_portfolio(self, params=None, **options): + """Create a portfolio + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios" + return self.client.post(path, params, **options) + + def delete_portfolio(self, portfolio_gid, params=None, **options): + """Delete a portfolio + :param str portfolio_gid: (required) Globally unique identifier for the portfolio. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios/{portfolio_gid}".replace("{portfolio_gid}", portfolio_gid) + return self.client.delete(path, params, **options) + + def get_items_for_portfolio(self, portfolio_gid, params=None, **options): + """Get portfolio items + :param str portfolio_gid: (required) Globally unique identifier for the portfolio. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios/{portfolio_gid}/items".replace("{portfolio_gid}", portfolio_gid) + return self.client.get_collection(path, params, **options) + + def get_portfolio(self, portfolio_gid, params=None, **options): + """Get a portfolio + :param str portfolio_gid: (required) Globally unique identifier for the portfolio. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios/{portfolio_gid}".replace("{portfolio_gid}", portfolio_gid) + return self.client.get(path, params, **options) + + def get_portfolios(self, params=None, **options): + """Get multiple portfolios + :param Object params: Parameters for the request + - workspace {str}: (required) The workspace or organization to filter portfolios on. + - owner {str}: The user who owns the portfolio. Currently, API users can only get a list of portfolios that they themselves own. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios" + return self.client.get_collection(path, params, **options) + + def remove_custom_field_setting_for_portfolio(self, portfolio_gid, params=None, **options): + """Remove a custom field from a portfolio + :param str portfolio_gid: (required) Globally unique identifier for the portfolio. + :param Object params: Parameters for the request + :param **options + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios/{portfolio_gid}/removeCustomFieldSetting".replace("{portfolio_gid}", portfolio_gid) + return self.client.post(path, params, **options) + + def remove_item_for_portfolio(self, portfolio_gid, params=None, **options): + """Remove a portfolio item + :param str portfolio_gid: (required) Globally unique identifier for the portfolio. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios/{portfolio_gid}/removeItem".replace("{portfolio_gid}", portfolio_gid) + return self.client.post(path, params, **options) + + def remove_members_for_portfolio(self, portfolio_gid, params=None, **options): + """Remove users from a portfolio + :param str portfolio_gid: (required) Globally unique identifier for the portfolio. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios/{portfolio_gid}/removeMembers".replace("{portfolio_gid}", portfolio_gid) + return self.client.post(path, params, **options) + + def update_portfolio(self, portfolio_gid, params=None, **options): + """Update a portfolio + :param str portfolio_gid: (required) Globally unique identifier for the portfolio. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/portfolios/{portfolio_gid}".replace("{portfolio_gid}", portfolio_gid) + return self.client.put(path, params, **options) diff --git a/asana/resources/gen/project_briefs.py b/asana/resources/gen/project_briefs.py new file mode 100644 index 00000000..4d59ff55 --- /dev/null +++ b/asana/resources/gen/project_briefs.py @@ -0,0 +1,61 @@ +# coding=utf-8 +class _ProjectBriefs: + + def __init__(self, client=None): + self.client = client + + def create_project_brief(self, project_gid, params=None, **options): + """Create a project brief + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/project_briefs".replace("{project_gid}", project_gid) + return self.client.post(path, params, **options) + + def delete_project_brief(self, project_brief_gid, params=None, **options): + """Delete a project brief + :param str project_brief_gid: (required) Globally unique identifier for the project brief. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/project_briefs/{project_brief_gid}".replace("{project_brief_gid}", project_brief_gid) + return self.client.delete(path, params, **options) + + def get_project_brief(self, project_brief_gid, params=None, **options): + """Get a project brief + :param str project_brief_gid: (required) Globally unique identifier for the project brief. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/project_briefs/{project_brief_gid}".replace("{project_brief_gid}", project_brief_gid) + return self.client.get(path, params, **options) + + def update_project_brief(self, project_brief_gid, params=None, **options): + """Update a project brief + :param str project_brief_gid: (required) Globally unique identifier for the project brief. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/project_briefs/{project_brief_gid}".replace("{project_brief_gid}", project_brief_gid) + return self.client.put(path, params, **options) diff --git a/asana/resources/gen/project_memberships.py b/asana/resources/gen/project_memberships.py new file mode 100644 index 00000000..a78c0af5 --- /dev/null +++ b/asana/resources/gen/project_memberships.py @@ -0,0 +1,36 @@ +# coding=utf-8 +class _ProjectMemberships: + + def __init__(self, client=None): + self.client = client + + def get_project_membership(self, project_membership_gid, params=None, **options): + """Get a project membership + :param str project_membership_gid: (required) + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/project_memberships/{project_membership_gid}".replace("{project_membership_gid}", project_membership_gid) + return self.client.get(path, params, **options) + + def get_project_memberships_for_project(self, project_gid, params=None, **options): + """Get memberships from a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + - user {str}: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/project_memberships".replace("{project_gid}", project_gid) + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/gen/project_statuses.py b/asana/resources/gen/project_statuses.py new file mode 100644 index 00000000..94e9af82 --- /dev/null +++ b/asana/resources/gen/project_statuses.py @@ -0,0 +1,63 @@ +# coding=utf-8 +class _ProjectStatuses: + + def __init__(self, client=None): + self.client = client + + def create_project_status_for_project(self, project_gid, params=None, **options): + """Create a project status + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/project_statuses".replace("{project_gid}", project_gid) + return self.client.post(path, params, **options) + + def delete_project_status(self, project_status_gid, params=None, **options): + """Delete a project status + :param str project_status_gid: (required) The project status update to get. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/project_statuses/{project_status_gid}".replace("{project_status_gid}", project_status_gid) + return self.client.delete(path, params, **options) + + def get_project_status(self, project_status_gid, params=None, **options): + """Get a project status + :param str project_status_gid: (required) The project status update to get. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/project_statuses/{project_status_gid}".replace("{project_status_gid}", project_status_gid) + return self.client.get(path, params, **options) + + def get_project_statuses_for_project(self, project_gid, params=None, **options): + """Get statuses from a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/project_statuses".replace("{project_gid}", project_gid) + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/gen/project_templates.py b/asana/resources/gen/project_templates.py new file mode 100644 index 00000000..87c99d29 --- /dev/null +++ b/asana/resources/gen/project_templates.py @@ -0,0 +1,66 @@ +# coding=utf-8 +class _ProjectTemplates: + + def __init__(self, client=None): + self.client = client + + def get_project_template(self, project_template_gid, params=None, **options): + """Get a project template + :param str project_template_gid: (required) Globally unique identifier for the project template. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/project_templates/{project_template_gid}".replace("{project_template_gid}", project_template_gid) + return self.client.get(path, params, **options) + + def get_project_templates(self, params=None, **options): + """Get multiple project templates + :param Object params: Parameters for the request + - workspace {str}: The workspace to filter results on. + - team {str}: The team to filter projects on. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/project_templates" + return self.client.get_collection(path, params, **options) + + def get_project_templates_for_team(self, team_gid, params=None, **options): + """Get a team's project templates + :param str team_gid: (required) Globally unique identifier for the team. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/teams/{team_gid}/project_templates".replace("{team_gid}", team_gid) + return self.client.get_collection(path, params, **options) + + def instantiate_project(self, project_template_gid, params=None, **options): + """Instantiate a project from a project template + :param str project_template_gid: (required) Globally unique identifier for the project template. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/project_templates/{project_template_gid}/instantiateProject".replace("{project_template_gid}", project_template_gid) + return self.client.post(path, params, **options) diff --git a/asana/resources/gen/projects.py b/asana/resources/gen/projects.py new file mode 100644 index 00000000..f93fba92 --- /dev/null +++ b/asana/resources/gen/projects.py @@ -0,0 +1,282 @@ +# coding=utf-8 +class _Projects: + + def __init__(self, client=None): + self.client = client + + def add_custom_field_setting_for_project(self, project_gid, params=None, **options): + """Add a custom field to a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/addCustomFieldSetting".replace("{project_gid}", project_gid) + return self.client.post(path, params, **options) + + def add_followers_for_project(self, project_gid, params=None, **options): + """Add followers to a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/addFollowers".replace("{project_gid}", project_gid) + return self.client.post(path, params, **options) + + def add_members_for_project(self, project_gid, params=None, **options): + """Add users to a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/addMembers".replace("{project_gid}", project_gid) + return self.client.post(path, params, **options) + + def create_project(self, params=None, **options): + """Create a project + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects" + return self.client.post(path, params, **options) + + def create_project_for_team(self, team_gid, params=None, **options): + """Create a project in a team + :param str team_gid: (required) Globally unique identifier for the team. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/teams/{team_gid}/projects".replace("{team_gid}", team_gid) + return self.client.post(path, params, **options) + + def create_project_for_workspace(self, workspace_gid, params=None, **options): + """Create a project in a workspace + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}/projects".replace("{workspace_gid}", workspace_gid) + return self.client.post(path, params, **options) + + def delete_project(self, project_gid, params=None, **options): + """Delete a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}".replace("{project_gid}", project_gid) + return self.client.delete(path, params, **options) + + def duplicate_project(self, project_gid, params=None, **options): + """Duplicate a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/duplicate".replace("{project_gid}", project_gid) + return self.client.post(path, params, **options) + + def get_project(self, project_gid, params=None, **options): + """Get a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}".replace("{project_gid}", project_gid) + return self.client.get(path, params, **options) + + def get_projects(self, params=None, **options): + """Get multiple projects + :param Object params: Parameters for the request + - workspace {str}: The workspace or organization to filter projects on. + - team {str}: The team to filter projects on. + - archived {bool}: Only return projects whose `archived` field takes on the value of this parameter. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects" + return self.client.get_collection(path, params, **options) + + def get_projects_for_task(self, task_gid, params=None, **options): + """Get projects a task is in + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/projects".replace("{task_gid}", task_gid) + return self.client.get_collection(path, params, **options) + + def get_projects_for_team(self, team_gid, params=None, **options): + """Get a team's projects + :param str team_gid: (required) Globally unique identifier for the team. + :param Object params: Parameters for the request + - archived {bool}: Only return projects whose `archived` field takes on the value of this parameter. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/teams/{team_gid}/projects".replace("{team_gid}", team_gid) + return self.client.get_collection(path, params, **options) + + def get_projects_for_workspace(self, workspace_gid, params=None, **options): + """Get all projects in a workspace + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + - archived {bool}: Only return projects whose `archived` field takes on the value of this parameter. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}/projects".replace("{workspace_gid}", workspace_gid) + return self.client.get_collection(path, params, **options) + + def get_task_counts_for_project(self, project_gid, params=None, **options): + """Get task count of a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/task_counts".replace("{project_gid}", project_gid) + return self.client.get(path, params, **options) + + def project_save_as_template(self, project_gid, params=None, **options): + """Create a project template from a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/saveAsTemplate".replace("{project_gid}", project_gid) + return self.client.post(path, params, **options) + + def remove_custom_field_setting_for_project(self, project_gid, params=None, **options): + """Remove a custom field from a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/removeCustomFieldSetting".replace("{project_gid}", project_gid) + return self.client.post(path, params, **options) + + def remove_followers_for_project(self, project_gid, params=None, **options): + """Remove followers from a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/removeFollowers".replace("{project_gid}", project_gid) + return self.client.post(path, params, **options) + + def remove_members_for_project(self, project_gid, params=None, **options): + """Remove users from a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/removeMembers".replace("{project_gid}", project_gid) + return self.client.post(path, params, **options) + + def update_project(self, project_gid, params=None, **options): + """Update a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}".replace("{project_gid}", project_gid) + return self.client.put(path, params, **options) diff --git a/asana/resources/gen/sections.py b/asana/resources/gen/sections.py new file mode 100644 index 00000000..043ac4c0 --- /dev/null +++ b/asana/resources/gen/sections.py @@ -0,0 +1,105 @@ +# coding=utf-8 +class _Sections: + + def __init__(self, client=None): + self.client = client + + def add_task_for_section(self, section_gid, params=None, **options): + """Add task to section + :param str section_gid: (required) The globally unique identifier for the section. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/sections/{section_gid}/addTask".replace("{section_gid}", section_gid) + return self.client.post(path, params, **options) + + def create_section_for_project(self, project_gid, params=None, **options): + """Create a section in a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/sections".replace("{project_gid}", project_gid) + return self.client.post(path, params, **options) + + def delete_section(self, section_gid, params=None, **options): + """Delete a section + :param str section_gid: (required) The globally unique identifier for the section. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/sections/{section_gid}".replace("{section_gid}", section_gid) + return self.client.delete(path, params, **options) + + def get_section(self, section_gid, params=None, **options): + """Get a section + :param str section_gid: (required) The globally unique identifier for the section. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/sections/{section_gid}".replace("{section_gid}", section_gid) + return self.client.get(path, params, **options) + + def get_sections_for_project(self, project_gid, params=None, **options): + """Get sections in a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/sections".replace("{project_gid}", project_gid) + return self.client.get_collection(path, params, **options) + + def insert_section_for_project(self, project_gid, params=None, **options): + """Move or Insert sections + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/sections/insert".replace("{project_gid}", project_gid) + return self.client.post(path, params, **options) + + def update_section(self, section_gid, params=None, **options): + """Update a section + :param str section_gid: (required) The globally unique identifier for the section. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/sections/{section_gid}".replace("{section_gid}", section_gid) + return self.client.put(path, params, **options) diff --git a/asana/resources/gen/status_updates.py b/asana/resources/gen/status_updates.py new file mode 100644 index 00000000..ef89bd5d --- /dev/null +++ b/asana/resources/gen/status_updates.py @@ -0,0 +1,65 @@ +# coding=utf-8 +class _StatusUpdates: + + def __init__(self, client=None): + self.client = client + + def create_status_for_object(self, params=None, **options): + """Create a status update + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/status_updates" + return self.client.post(path, params, **options) + + def delete_status(self, status_gid, params=None, **options): + """Delete a status update + :param str status_gid: (required) The status update to get. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/status_updates/{status_gid}".replace("{status_gid}", status_gid) + return self.client.delete(path, params, **options) + + def get_status(self, status_gid, params=None, **options): + """Get a status update + :param str status_gid: (required) The status update to get. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/status_updates/{status_gid}".replace("{status_gid}", status_gid) + return self.client.get(path, params, **options) + + def get_statuses_for_object(self, params=None, **options): + """Get status updates from an object + :param Object params: Parameters for the request + - parent {str}: (required) Globally unique identifier for object to fetch statuses from. Must be a GID for a project, portfolio, or goal. + - created_since {datetime}: Only return statuses that have been created since the given time. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/status_updates" + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/gen/stories.py b/asana/resources/gen/stories.py new file mode 100644 index 00000000..d0dd73ed --- /dev/null +++ b/asana/resources/gen/stories.py @@ -0,0 +1,79 @@ +# coding=utf-8 +class _Stories: + + def __init__(self, client=None): + self.client = client + + def create_story_for_task(self, task_gid, params=None, **options): + """Create a story on a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/stories".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def delete_story(self, story_gid, params=None, **options): + """Delete a story + :param str story_gid: (required) Globally unique identifier for the story. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/stories/{story_gid}".replace("{story_gid}", story_gid) + return self.client.delete(path, params, **options) + + def get_stories_for_task(self, task_gid, params=None, **options): + """Get stories from a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/stories".replace("{task_gid}", task_gid) + return self.client.get_collection(path, params, **options) + + def get_story(self, story_gid, params=None, **options): + """Get a story + :param str story_gid: (required) Globally unique identifier for the story. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/stories/{story_gid}".replace("{story_gid}", story_gid) + return self.client.get(path, params, **options) + + def update_story(self, story_gid, params=None, **options): + """Update a story + :param str story_gid: (required) Globally unique identifier for the story. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/stories/{story_gid}".replace("{story_gid}", story_gid) + return self.client.put(path, params, **options) diff --git a/asana/resources/gen/tags.py b/asana/resources/gen/tags.py new file mode 100644 index 00000000..52fd7988 --- /dev/null +++ b/asana/resources/gen/tags.py @@ -0,0 +1,128 @@ +# coding=utf-8 +class _Tags: + + def __init__(self, client=None): + self.client = client + + def create_tag(self, params=None, **options): + """Create a tag + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tags" + return self.client.post(path, params, **options) + + def create_tag_for_workspace(self, workspace_gid, params=None, **options): + """Create a tag in a workspace + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}/tags".replace("{workspace_gid}", workspace_gid) + return self.client.post(path, params, **options) + + def delete_tag(self, tag_gid, params=None, **options): + """Delete a tag + :param str tag_gid: (required) Globally unique identifier for the tag. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tags/{tag_gid}".replace("{tag_gid}", tag_gid) + return self.client.delete(path, params, **options) + + def get_tag(self, tag_gid, params=None, **options): + """Get a tag + :param str tag_gid: (required) Globally unique identifier for the tag. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tags/{tag_gid}".replace("{tag_gid}", tag_gid) + return self.client.get(path, params, **options) + + def get_tags(self, params=None, **options): + """Get multiple tags + :param Object params: Parameters for the request + - workspace {str}: The workspace to filter tags on. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tags" + return self.client.get_collection(path, params, **options) + + def get_tags_for_task(self, task_gid, params=None, **options): + """Get a task's tags + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/tags".replace("{task_gid}", task_gid) + return self.client.get_collection(path, params, **options) + + def get_tags_for_workspace(self, workspace_gid, params=None, **options): + """Get tags in a workspace + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}/tags".replace("{workspace_gid}", workspace_gid) + return self.client.get_collection(path, params, **options) + + def update_tag(self, tag_gid, params=None, **options): + """Update a tag + :param str tag_gid: (required) Globally unique identifier for the tag. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tags/{tag_gid}".replace("{tag_gid}", tag_gid) + return self.client.put(path, params, **options) diff --git a/asana/resources/gen/tasks.py b/asana/resources/gen/tasks.py new file mode 100644 index 00000000..1b100d28 --- /dev/null +++ b/asana/resources/gen/tasks.py @@ -0,0 +1,443 @@ +# coding=utf-8 +class _Tasks: + + def __init__(self, client=None): + self.client = client + + def add_dependencies_for_task(self, task_gid, params=None, **options): + """Set dependencies for a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/addDependencies".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def add_dependents_for_task(self, task_gid, params=None, **options): + """Set dependents for a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/addDependents".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def add_followers_for_task(self, task_gid, params=None, **options): + """Add followers to a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/addFollowers".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def add_project_for_task(self, task_gid, params=None, **options): + """Add a project to a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/addProject".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def add_tag_for_task(self, task_gid, params=None, **options): + """Add a tag to a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/addTag".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def create_subtask_for_task(self, task_gid, params=None, **options): + """Create a subtask + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/subtasks".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def create_task(self, params=None, **options): + """Create a task + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks" + return self.client.post(path, params, **options) + + def delete_task(self, task_gid, params=None, **options): + """Delete a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}".replace("{task_gid}", task_gid) + return self.client.delete(path, params, **options) + + def duplicate_task(self, task_gid, params=None, **options): + """Duplicate a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/duplicate".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def get_dependencies_for_task(self, task_gid, params=None, **options): + """Get dependencies from a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/dependencies".replace("{task_gid}", task_gid) + return self.client.get_collection(path, params, **options) + + def get_dependents_for_task(self, task_gid, params=None, **options): + """Get dependents from a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/dependents".replace("{task_gid}", task_gid) + return self.client.get_collection(path, params, **options) + + def get_subtasks_for_task(self, task_gid, params=None, **options): + """Get subtasks from a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/subtasks".replace("{task_gid}", task_gid) + return self.client.get_collection(path, params, **options) + + def get_task(self, task_gid, params=None, **options): + """Get a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}".replace("{task_gid}", task_gid) + return self.client.get(path, params, **options) + + def get_tasks(self, params=None, **options): + """Get multiple tasks + :param Object params: Parameters for the request + - assignee {str}: The assignee to filter tasks on. If searching for unassigned tasks, assignee.any = null can be specified. *Note: If you specify `assignee`, you must also specify the `workspace` to filter on.* + - project {str}: The project to filter tasks on. + - section {str}: The section to filter tasks on. + - workspace {str}: The workspace to filter tasks on. *Note: If you specify `workspace`, you must also specify the `assignee` to filter on.* + - completed_since {datetime}: Only return tasks that are either incomplete or that have been completed since this time. + - modified_since {datetime}: Only return tasks that have been modified since the given time. *Note: A task is considered “modified” if any of its properties change, or associations between it and other objects are modified (e.g. a task being added to a project). A task is not considered modified just because another object it is associated with (e.g. a subtask) is modified. Actions that count as modifying the task include assigning, renaming, completing, and adding stories.* + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks" + return self.client.get_collection(path, params, **options) + + def get_tasks_for_project(self, project_gid, params=None, **options): + """Get tasks from a project + :param str project_gid: (required) Globally unique identifier for the project. + :param Object params: Parameters for the request + - completed_since {str}: Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/projects/{project_gid}/tasks".replace("{project_gid}", project_gid) + return self.client.get_collection(path, params, **options) + + def get_tasks_for_section(self, section_gid, params=None, **options): + """Get tasks from a section + :param str section_gid: (required) The globally unique identifier for the section. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/sections/{section_gid}/tasks".replace("{section_gid}", section_gid) + return self.client.get_collection(path, params, **options) + + def get_tasks_for_tag(self, tag_gid, params=None, **options): + """Get tasks from a tag + :param str tag_gid: (required) Globally unique identifier for the tag. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tags/{tag_gid}/tasks".replace("{tag_gid}", tag_gid) + return self.client.get_collection(path, params, **options) + + def get_tasks_for_user_task_list(self, user_task_list_gid, params=None, **options): + """Get tasks from a user task list + :param str user_task_list_gid: (required) Globally unique identifier for the user task list. + :param Object params: Parameters for the request + - completed_since {str}: Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/user_task_lists/{user_task_list_gid}/tasks".replace("{user_task_list_gid}", user_task_list_gid) + return self.client.get_collection(path, params, **options) + + def remove_dependencies_for_task(self, task_gid, params=None, **options): + """Unlink dependencies from a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/removeDependencies".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def remove_dependents_for_task(self, task_gid, params=None, **options): + """Unlink dependents from a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/removeDependents".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def remove_follower_for_task(self, task_gid, params=None, **options): + """Remove followers from a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/removeFollowers".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def remove_project_for_task(self, task_gid, params=None, **options): + """Remove a project from a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/removeProject".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def remove_tag_for_task(self, task_gid, params=None, **options): + """Remove a tag from a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/removeTag".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def search_tasks_for_workspace(self, workspace_gid, params=None, **options): + """Search tasks in a workspace + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + - text {str}: Performs full-text search on both task name and description + - resource_subtype {str}: Filters results by the task's resource_subtype + - assignee_any {str}: Comma-separated list of user identifiers + - assignee_not {str}: Comma-separated list of user identifiers + - portfolios_any {str}: Comma-separated list of portfolio IDs + - projects_any {str}: Comma-separated list of project IDs + - projects_not {str}: Comma-separated list of project IDs + - projects_all {str}: Comma-separated list of project IDs + - sections_any {str}: Comma-separated list of section or column IDs + - sections_not {str}: Comma-separated list of section or column IDs + - sections_all {str}: Comma-separated list of section or column IDs + - tags_any {str}: Comma-separated list of tag IDs + - tags_not {str}: Comma-separated list of tag IDs + - tags_all {str}: Comma-separated list of tag IDs + - teams_any {str}: Comma-separated list of team IDs + - followers_not {str}: Comma-separated list of user identifiers + - created_by_any {str}: Comma-separated list of user identifiers + - created_by_not {str}: Comma-separated list of user identifiers + - assigned_by_any {str}: Comma-separated list of user identifiers + - assigned_by_not {str}: Comma-separated list of user identifiers + - liked_by_not {str}: Comma-separated list of user identifiers + - commented_on_by_not {str}: Comma-separated list of user identifiers + - due_on_before {date}: ISO 8601 date string + - due_on_after {date}: ISO 8601 date string + - due_on {date}: ISO 8601 date string or `null` + - due_at_before {datetime}: ISO 8601 datetime string + - due_at_after {datetime}: ISO 8601 datetime string + - start_on_before {date}: ISO 8601 date string + - start_on_after {date}: ISO 8601 date string + - start_on {date}: ISO 8601 date string or `null` + - created_on_before {date}: ISO 8601 date string + - created_on_after {date}: ISO 8601 date string + - created_on {date}: ISO 8601 date string or `null` + - created_at_before {datetime}: ISO 8601 datetime string + - created_at_after {datetime}: ISO 8601 datetime string + - completed_on_before {date}: ISO 8601 date string + - completed_on_after {date}: ISO 8601 date string + - completed_on {date}: ISO 8601 date string or `null` + - completed_at_before {datetime}: ISO 8601 datetime string + - completed_at_after {datetime}: ISO 8601 datetime string + - modified_on_before {date}: ISO 8601 date string + - modified_on_after {date}: ISO 8601 date string + - modified_on {date}: ISO 8601 date string or `null` + - modified_at_before {datetime}: ISO 8601 datetime string + - modified_at_after {datetime}: ISO 8601 datetime string + - is_blocking {bool}: Filter to incomplete tasks with dependents + - is_blocked {bool}: Filter to tasks with incomplete dependencies + - has_attachment {bool}: Filter to tasks with attachments + - completed {bool}: Filter to completed tasks + - is_subtask {bool}: Filter to subtasks + - sort_by {str}: One of `due_date`, `created_at`, `completed_at`, `likes`, or `modified_at`, defaults to `modified_at` + - sort_ascending {bool}: Default `false` + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}/tasks/search".replace("{workspace_gid}", workspace_gid) + return self.client.get_collection(path, params, **options) + + def set_parent_for_task(self, task_gid, params=None, **options): + """Set the parent of a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}/setParent".replace("{task_gid}", task_gid) + return self.client.post(path, params, **options) + + def update_task(self, task_gid, params=None, **options): + """Update a task + :param str task_gid: (required) The task to operate on. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/tasks/{task_gid}".replace("{task_gid}", task_gid) + return self.client.put(path, params, **options) diff --git a/asana/resources/gen/team_memberships.py b/asana/resources/gen/team_memberships.py new file mode 100644 index 00000000..ef3ba93c --- /dev/null +++ b/asana/resources/gen/team_memberships.py @@ -0,0 +1,70 @@ +# coding=utf-8 +class _TeamMemberships: + + def __init__(self, client=None): + self.client = client + + def get_team_membership(self, team_membership_gid, params=None, **options): + """Get a team membership + :param str team_membership_gid: (required) + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/team_memberships/{team_membership_gid}".replace("{team_membership_gid}", team_membership_gid) + return self.client.get(path, params, **options) + + def get_team_memberships(self, params=None, **options): + """Get team memberships + :param Object params: Parameters for the request + - team {str}: Globally unique identifier for the team. + - user {str}: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. This parameter must be used with the workspace parameter. + - workspace {str}: Globally unique identifier for the workspace. This parameter must be used with the user parameter. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/team_memberships" + return self.client.get_collection(path, params, **options) + + def get_team_memberships_for_team(self, team_gid, params=None, **options): + """Get memberships from a team + :param str team_gid: (required) Globally unique identifier for the team. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/teams/{team_gid}/team_memberships".replace("{team_gid}", team_gid) + return self.client.get_collection(path, params, **options) + + def get_team_memberships_for_user(self, user_gid, params=None, **options): + """Get memberships from a user + :param str user_gid: (required) A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. + :param Object params: Parameters for the request + - workspace {str}: (required) Globally unique identifier for the workspace. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/users/{user_gid}/team_memberships".replace("{user_gid}", user_gid) + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/gen/teams.py b/asana/resources/gen/teams.py new file mode 100644 index 00000000..459f0b34 --- /dev/null +++ b/asana/resources/gen/teams.py @@ -0,0 +1,112 @@ +# coding=utf-8 +class _Teams: + + def __init__(self, client=None): + self.client = client + + def add_user_for_team(self, team_gid, params=None, **options): + """Add a user to a team + :param str team_gid: (required) Globally unique identifier for the team. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/teams/{team_gid}/addUser".replace("{team_gid}", team_gid) + return self.client.post(path, params, **options) + + def create_team(self, params=None, **options): + """Create a team + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/teams" + return self.client.post(path, params, **options) + + def get_team(self, team_gid, params=None, **options): + """Get a team + :param str team_gid: (required) Globally unique identifier for the team. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/teams/{team_gid}".replace("{team_gid}", team_gid) + return self.client.get(path, params, **options) + + def get_teams_for_user(self, user_gid, params=None, **options): + """Get teams for a user + :param str user_gid: (required) A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. + :param Object params: Parameters for the request + - organization {str}: (required) The workspace or organization to filter teams on. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/users/{user_gid}/teams".replace("{user_gid}", user_gid) + return self.client.get_collection(path, params, **options) + + def get_teams_for_workspace(self, workspace_gid, params=None, **options): + """Get teams in a workspace + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}/teams".replace("{workspace_gid}", workspace_gid) + return self.client.get_collection(path, params, **options) + + def remove_user_for_team(self, team_gid, params=None, **options): + """Remove a user from a team + :param str team_gid: (required) Globally unique identifier for the team. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/teams/{team_gid}/removeUser".replace("{team_gid}", team_gid) + return self.client.post(path, params, **options) + + def update_team(self, params=None, **options): + """Update a team + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/teams" + return self.client.put(path, params, **options) diff --git a/asana/resources/gen/time_periods.py b/asana/resources/gen/time_periods.py new file mode 100644 index 00000000..a1471b9f --- /dev/null +++ b/asana/resources/gen/time_periods.py @@ -0,0 +1,37 @@ +# coding=utf-8 +class _TimePeriods: + + def __init__(self, client=None): + self.client = client + + def get_time_period(self, time_period_gid, params=None, **options): + """Get a time period + :param str time_period_gid: (required) Globally unique identifier for the time period. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/time_periods/{time_period_gid}".replace("{time_period_gid}", time_period_gid) + return self.client.get(path, params, **options) + + def get_time_periods(self, params=None, **options): + """Get time periods + :param Object params: Parameters for the request + - start_on {date}: ISO 8601 date string + - end_on {date}: ISO 8601 date string + - workspace {str}: (required) Globally unique identifier for the workspace. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/time_periods" + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/gen/typeahead.py b/asana/resources/gen/typeahead.py new file mode 100644 index 00000000..c23110cf --- /dev/null +++ b/asana/resources/gen/typeahead.py @@ -0,0 +1,23 @@ +# coding=utf-8 +class _Typeahead: + + def __init__(self, client=None): + self.client = client + + def typeahead_for_workspace(self, workspace_gid, params=None, **options): + """Get objects via typeahead + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + - resource_type {str}: (required) The type of values the typeahead should return. You can choose from one of the following: `custom_field`, `project`, `project_template`, `portfolio`, `tag`, `task`, and `user`. Note that unlike in the names of endpoints, the types listed here are in singular form (e.g. `task`). Using multiple types is not yet supported. + - type {str}: *Deprecated: new integrations should prefer the resource_type field.* + - query {str}: The string that will be used to search for relevant objects. If an empty string is passed in, the API will return results. + - count {int}: The number of results to return. The default is 20 if this parameter is omitted, with a minimum of 1 and a maximum of 100. If there are fewer results found than requested, all will be returned. + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}/typeahead".replace("{workspace_gid}", workspace_gid) + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/gen/user_task_lists.py b/asana/resources/gen/user_task_lists.py new file mode 100644 index 00000000..b59a9d56 --- /dev/null +++ b/asana/resources/gen/user_task_lists.py @@ -0,0 +1,34 @@ +# coding=utf-8 +class _UserTaskLists: + + def __init__(self, client=None): + self.client = client + + def get_user_task_list(self, user_task_list_gid, params=None, **options): + """Get a user task list + :param str user_task_list_gid: (required) Globally unique identifier for the user task list. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/user_task_lists/{user_task_list_gid}".replace("{user_task_list_gid}", user_task_list_gid) + return self.client.get(path, params, **options) + + def get_user_task_list_for_user(self, user_gid, params=None, **options): + """Get a user's task list + :param str user_gid: (required) A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. + :param Object params: Parameters for the request + - workspace {str}: (required) The workspace in which to get the user task list. + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/users/{user_gid}/user_task_list".replace("{user_gid}", user_gid) + return self.client.get(path, params, **options) diff --git a/asana/resources/gen/users.py b/asana/resources/gen/users.py new file mode 100644 index 00000000..55538f6e --- /dev/null +++ b/asana/resources/gen/users.py @@ -0,0 +1,82 @@ +# coding=utf-8 +class _Users: + + def __init__(self, client=None): + self.client = client + + def get_favorites_for_user(self, user_gid, params=None, **options): + """Get a user's favorites + :param str user_gid: (required) A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. + :param Object params: Parameters for the request + - resource_type {str}: (required) The resource type of favorites to be returned. + - workspace {str}: (required) The workspace in which to get favorites. + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/users/{user_gid}/favorites".replace("{user_gid}", user_gid) + return self.client.get_collection(path, params, **options) + + def get_user(self, user_gid, params=None, **options): + """Get a user + :param str user_gid: (required) A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/users/{user_gid}".replace("{user_gid}", user_gid) + return self.client.get(path, params, **options) + + def get_users(self, params=None, **options): + """Get multiple users + :param Object params: Parameters for the request + - workspace {str}: The workspace or organization ID to filter users on. + - team {str}: The team ID to filter users on. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/users" + return self.client.get_collection(path, params, **options) + + def get_users_for_team(self, team_gid, params=None, **options): + """Get users in a team + :param str team_gid: (required) Globally unique identifier for the team. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/teams/{team_gid}/users".replace("{team_gid}", team_gid) + return self.client.get_collection(path, params, **options) + + def get_users_for_workspace(self, workspace_gid, params=None, **options): + """Get users in a workspace or organization + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}/users".replace("{workspace_gid}", workspace_gid) + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/gen/webhooks.py b/asana/resources/gen/webhooks.py new file mode 100644 index 00000000..29a59840 --- /dev/null +++ b/asana/resources/gen/webhooks.py @@ -0,0 +1,77 @@ +# coding=utf-8 +class _Webhooks: + + def __init__(self, client=None): + self.client = client + + def create_webhook(self, params=None, **options): + """Establish a webhook + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/webhooks" + return self.client.post(path, params, **options) + + def delete_webhook(self, webhook_gid, params=None, **options): + """Delete a webhook + :param str webhook_gid: (required) Globally unique identifier for the webhook. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/webhooks/{webhook_gid}".replace("{webhook_gid}", webhook_gid) + return self.client.delete(path, params, **options) + + def get_webhook(self, webhook_gid, params=None, **options): + """Get a webhook + :param str webhook_gid: (required) Globally unique identifier for the webhook. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/webhooks/{webhook_gid}".replace("{webhook_gid}", webhook_gid) + return self.client.get(path, params, **options) + + def get_webhooks(self, params=None, **options): + """Get multiple webhooks + :param Object params: Parameters for the request + - workspace {str}: (required) The workspace to query for webhooks in. + - resource {str}: Only return webhooks for the given resource. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/webhooks" + return self.client.get_collection(path, params, **options) + + def update_webhook(self, webhook_gid, params=None, **options): + """Update a webhook + :param str webhook_gid: (required) Globally unique identifier for the webhook. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/webhooks/{webhook_gid}".replace("{webhook_gid}", webhook_gid) + return self.client.put(path, params, **options) diff --git a/asana/resources/gen/workspace_memberships.py b/asana/resources/gen/workspace_memberships.py new file mode 100644 index 00000000..ec84ddb7 --- /dev/null +++ b/asana/resources/gen/workspace_memberships.py @@ -0,0 +1,52 @@ +# coding=utf-8 +class _WorkspaceMemberships: + + def __init__(self, client=None): + self.client = client + + def get_workspace_membership(self, workspace_membership_gid, params=None, **options): + """Get a workspace membership + :param str workspace_membership_gid: (required) + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspace_memberships/{workspace_membership_gid}".replace("{workspace_membership_gid}", workspace_membership_gid) + return self.client.get(path, params, **options) + + def get_workspace_memberships_for_user(self, user_gid, params=None, **options): + """Get workspace memberships for a user + :param str user_gid: (required) A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/users/{user_gid}/workspace_memberships".replace("{user_gid}", user_gid) + return self.client.get_collection(path, params, **options) + + def get_workspace_memberships_for_workspace(self, workspace_gid, params=None, **options): + """Get the workspace memberships for a workspace + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + - user {str}: A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}/workspace_memberships".replace("{workspace_gid}", workspace_gid) + return self.client.get_collection(path, params, **options) diff --git a/asana/resources/gen/workspaces.py b/asana/resources/gen/workspaces.py new file mode 100644 index 00000000..0250dffd --- /dev/null +++ b/asana/resources/gen/workspaces.py @@ -0,0 +1,76 @@ +# coding=utf-8 +class _Workspaces: + + def __init__(self, client=None): + self.client = client + + def add_user_for_workspace(self, workspace_gid, params=None, **options): + """Add a user to a workspace or organization + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}/addUser".replace("{workspace_gid}", workspace_gid) + return self.client.post(path, params, **options) + + def get_workspace(self, workspace_gid, params=None, **options): + """Get a workspace + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}".replace("{workspace_gid}", workspace_gid) + return self.client.get(path, params, **options) + + def get_workspaces(self, params=None, **options): + """Get multiple workspaces + :param Object params: Parameters for the request + :param **options + - offset {str}: Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' + - limit {int}: Results per page. The number of objects to return per page. The value must be between 1 and 100. + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces" + return self.client.get_collection(path, params, **options) + + def remove_user_for_workspace(self, workspace_gid, params=None, **options): + """Remove a user from a workspace or organization + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}/removeUser".replace("{workspace_gid}", workspace_gid) + return self.client.post(path, params, **options) + + def update_workspace(self, workspace_gid, params=None, **options): + """Update a workspace + :param str workspace_gid: (required) Globally unique identifier for the workspace or organization. + :param Object params: Parameters for the request + :param **options + - opt_fields {list[str]}: Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. + - opt_pretty {bool}: Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. + :return: Object + """ + if params is None: + params = {} + path = "/workspaces/{workspace_gid}".replace("{workspace_gid}", workspace_gid) + return self.client.put(path, params, **options) diff --git a/asana/resources/goal_relationships.py b/asana/resources/goal_relationships.py new file mode 100644 index 00000000..8580407d --- /dev/null +++ b/asana/resources/goal_relationships.py @@ -0,0 +1,5 @@ +from .gen.goal_relationships import _GoalRelationships + +class GoalRelationships(_GoalRelationships): + """Goal relationships resource""" + pass diff --git a/asana/resources/goals.py b/asana/resources/goals.py new file mode 100644 index 00000000..7d2b961d --- /dev/null +++ b/asana/resources/goals.py @@ -0,0 +1,6 @@ + +from .gen.goals import _Goals + +class Goals(_Goals): + """Goals resource""" + pass diff --git a/asana/resources/jobs.py b/asana/resources/jobs.py new file mode 100644 index 00000000..d10f7e83 --- /dev/null +++ b/asana/resources/jobs.py @@ -0,0 +1,15 @@ + +from .gen.jobs import _Jobs + +class Jobs(_Jobs): + """Jobs resource""" + def find_by_id(self, job, params={}, **options): + """Returns the complete job record for a single job. + + Parameters + ---------- + job : {Gid} The job to get. + [params] : {Object} Parameters for the request + """ + path = "/jobs/%s" % (job) + return self.client.get(path, params, **options) diff --git a/asana/resources/memberships.py b/asana/resources/memberships.py new file mode 100644 index 00000000..1da78a76 --- /dev/null +++ b/asana/resources/memberships.py @@ -0,0 +1,5 @@ +from .gen.memberships import _Memberships + +class Memberships(_Memberships): + """Memberships resource""" + pass diff --git a/asana/resources/message.py b/asana/resources/message.py new file mode 100644 index 00000000..8eeacca6 --- /dev/null +++ b/asana/resources/message.py @@ -0,0 +1,6 @@ + +from .gen.message import _Message + +class Message(_Message): + """Message resource""" + pass diff --git a/asana/resources/organization_exports.py b/asana/resources/organization_exports.py new file mode 100644 index 00000000..e649b7c0 --- /dev/null +++ b/asana/resources/organization_exports.py @@ -0,0 +1,30 @@ +from .gen.organization_exports import _OrganizationExports + + +class OrganizationExports(_OrganizationExports): + """The :class:`OrganizationExports` object, which represents the resource + of the same name in Asana's API. + + """ + + def find_by_id(self, organization_export, params={}, **options): + """Returns details of a previously-requested Organization export. + + Parameters + ---------- + organization_export : {Gid} Globally unique identifier for the Organization export. + [params] : {Object} Parameters for the request + """ + path = "/organization_exports/%s" % (organization_export) + return self.client.get(path, params, **options) + + def create(self, params={}, **options): + """This method creates a request to export an Organization. Asana will complete the export at some + point after you create the request. + + Parameters + ---------- + [data] : {Object} Data for the request + - organization : {Gid} Globally unique identifier for the workspace or organization. + """ + return self.client.post("/organization_exports", params, **options) diff --git a/asana/resources/portfolio_memberships.py b/asana/resources/portfolio_memberships.py new file mode 100644 index 00000000..ae20ffea --- /dev/null +++ b/asana/resources/portfolio_memberships.py @@ -0,0 +1,42 @@ + +from .gen.portfolio_memberships import _PortfolioMemberships + +class PortfolioMemberships(_PortfolioMemberships): + """Portfolio Memberships resource""" + + def find_all(self, params={}, **options): + """Returns the compact portfolio membership records for the portfolio. You must + specify `portfolio`, `portfolio` and `user`, or `workspace` and `user`. + + Parameters + ---------- + [params] : {Object} Parameters for the request + - [portfolio] : {Gid} The portfolio for which to fetch memberships. + - [workspace] : {Gid} The workspace for which to fetch memberships. + - [user] : {String} The user to filter the memberships to. + """ + return self.client.get_collection("/portfolio_memberships", params, **options) + + def find_by_portfolio(self, portfolio, params={}, **options): + """Returns the compact portfolio membership records for the portfolio. + + Parameters + ---------- + portfolio : {Gid} The portfolio for which to fetch memberships. + [params] : {Object} Parameters for the request + - [user] : {String} If present, the user to filter the memberships to. + """ + path = "/portfolios/%s/portfolio_memberships" % (portfolio) + return self.client.get_collection(path, params, **options) + + def find_by_id(self, portfolio_membership, params={}, **options): + """Returns the portfolio membership record. + + Parameters + ---------- + portfolio_membership : {Gid} Globally unique identifier for the portfolio membership. + [params] : {Object} Parameters for the request + """ + path = "/portfolio_memberships/%s" % (portfolio_membership) + return self.client.get(path, params, **options) + diff --git a/asana/resources/portfolios.py b/asana/resources/portfolios.py new file mode 100644 index 00000000..fbe27435 --- /dev/null +++ b/asana/resources/portfolios.py @@ -0,0 +1,184 @@ + +from .gen.portfolios import _Portfolios + +class Portfolios(_Portfolios): + """Portfolios resource""" + + def create(self, params={}, **options): + """Creates a new portfolio in the given workspace with the supplied name. + + Note that portfolios created in the Asana UI may have some state + (like the "Priority" custom field) which is automatically added to the + portfolio when it is created. Portfolios created via our API will **not** + be created with the same initial state to allow integrations to create + their own starting state on a portfolio. + + Parameters + ---------- + [data] : {Object} Data for the request + - workspace : {Gid} The workspace or organization in which to create the portfolio. + - name : {String} The name of the newly-created portfolio + - [color] : {String} An optional color for the portfolio + """ + return self.client.post("/portfolios", params, **options) + + def find_by_id(self, portfolio, params={}, **options): + """Returns the complete record for a single portfolio. + + Parameters + ---------- + portfolio : {Gid} The portfolio to get. + [params] : {Object} Parameters for the request + """ + path = "/portfolios/%s" % (portfolio) + return self.client.get(path, params, **options) + + def update(self, portfolio, params={}, **options): + """An existing portfolio can be updated by making a PUT request on the + URL for that portfolio. Only the fields provided in the `data` block will be + updated; any unspecified fields will remain unchanged. + + Returns the complete updated portfolio record. + + Parameters + ---------- + portfolio : {Gid} The portfolio to update. + [data] : {Object} Data for the request + """ + path = "/portfolios/%s" % (portfolio) + return self.client.put(path, params, **options) + + def delete(self, portfolio, params={}, **options): + """An existing portfolio can be deleted by making a DELETE request + on the URL for that portfolio. + + Returns an empty data record. + + Parameters + ---------- + portfolio : {Gid} The portfolio to delete. + """ + path = "/portfolios/%s" % (portfolio) + return self.client.delete(path, params, **options) + + def find_all(self, params={}, **options): + """Returns a list of the portfolios in compact representation that are owned + by the current API user. + + Parameters + ---------- + [params] : {Object} Parameters for the request + - workspace : {Gid} The workspace or organization to filter portfolios on. + - owner : {String} The user who owns the portfolio. Currently, API users can only get a + list of portfolios that they themselves own. + """ + return self.client.get_collection("/portfolios", params, **options) + + def get_items(self, portfolio, params={}, **options): + """Get a list of the items in compact form in a portfolio. + + Parameters + ---------- + portfolio : {Gid} The portfolio from which to get the list of items. + [params] : {Object} Parameters for the request + """ + path = "/portfolios/%s/items" % (portfolio) + return self.client.get_collection(path, params, **options) + + def add_item(self, portfolio, params={}, **options): + """Add an item to a portfolio. + + Returns an empty data block. + + Parameters + ---------- + portfolio : {Gid} The portfolio to which to add an item. + [data] : {Object} Data for the request + - item : {Gid} The item to add to the portfolio. + - [insert_before] : {Gid} An id of an item in this portfolio. The new item will be added before the one specified here. + `insert_before` and `insert_after` parameters cannot both be specified. + - [insert_after] : {Gid} An id of an item in this portfolio. The new item will be added after the one specified here. + `insert_before` and `insert_after` parameters cannot both be specified. + """ + path = "/portfolios/%s/addItem" % (portfolio) + return self.client.post(path, params, **options) + + def remove_item(self, portfolio, params={}, **options): + """Remove an item to a portfolio. + + Returns an empty data block. + + Parameters + ---------- + portfolio : {Gid} The portfolio from which to remove the item. + [data] : {Object} Data for the request + - item : {Gid} The item to remove from the portfolio. + """ + path = "/portfolios/%s/removeItem" % (portfolio) + return self.client.post(path, params, **options) + + def add_members(self, portfolio, params={}, **options): + """Adds the specified list of users as members of the portfolio. Returns the updated portfolio record. + + Parameters + ---------- + portfolio : {Gid} The portfolio to add members to. + [data] : {Object} Data for the request + - members : {Array} An array of user ids. + """ + path = "/portfolios/%s/addMembers" % (portfolio) + return self.client.post(path, params, **options) + + def remove_members(self, portfolio, params={}, **options): + """Removes the specified list of members from the portfolio. Returns the updated portfolio record. + + Parameters + ---------- + portfolio : {Gid} The portfolio to remove members from. + [data] : {Object} Data for the request + - members : {Array} An array of user ids. + """ + path = "/portfolios/%s/removeMembers" % (portfolio) + return self.client.post(path, params, **options) + + def custom_field_settings(self, portfolio, params={}, **options): + """Get the custom field settings on a portfolio. + + Parameters + ---------- + portfolio : {Gid} The portfolio from which to get the custom field settings. + [params] : {Object} Parameters for the request + """ + path = "/portfolios/%s/custom_field_settings" % (portfolio) + return self.client.get_collection(path, params, **options) + + def add_custom_field_setting(self, portfolio, params={}, **options): + """Create a new custom field setting on the portfolio. Returns the full + record for the new custom field setting. + + Parameters + ---------- + portfolio : {Gid} The portfolio onto which to add the custom field. + [data] : {Object} Data for the request + - custom_field : {Gid} The id of the custom field to add to the portfolio. + - [is_important] : {Boolean} Whether this field should be considered important to this portfolio (for instance, to display in the list view of items in the portfolio). + - [insert_before] : {Gid} An id of a custom field setting on this portfolio. The new custom field setting will be added before this one. + `insert_before` and `insert_after` parameters cannot both be specified. + - [insert_after] : {Gid} An id of a custom field setting on this portfolio. The new custom field setting will be added after this one. + `insert_before` and `insert_after` parameters cannot both be specified. + """ + path = "/portfolios/%s/addCustomFieldSetting" % (portfolio) + return self.client.post(path, params, **options) + + def remove_custom_field_setting(self, portfolio, params={}, **options): + """Remove a custom field setting on the portfolio. Returns an empty data + block. + + Parameters + ---------- + portfolio : {Gid} The portfolio from which to remove the custom field. + [data] : {Object} Data for the request + - custom_field : {Gid} The id of the custom field to remove from this portfolio. + """ + path = "/portfolios/%s/removeCustomFieldSetting" % (portfolio) + return self.client.post(path, params, **options) diff --git a/asana/resources/project_briefs.py b/asana/resources/project_briefs.py new file mode 100644 index 00000000..ff73b5d1 --- /dev/null +++ b/asana/resources/project_briefs.py @@ -0,0 +1,6 @@ + +from .gen.project_briefs import _ProjectBriefs + +class ProjectBriefs(_ProjectBriefs): + """ProjectBriefs resource""" + pass diff --git a/asana/resources/project_memberships.py b/asana/resources/project_memberships.py new file mode 100644 index 00000000..ec44a91b --- /dev/null +++ b/asana/resources/project_memberships.py @@ -0,0 +1,29 @@ + +from .gen.project_memberships import _ProjectMemberships + +class ProjectMemberships(_ProjectMemberships): + """Project Memberships resource""" + + def find_by_project(self, project, params={}, **options): + """Returns the compact project membership records for the project. + + Parameters + ---------- + project : {Gid} The project for which to fetch memberships. + [params] : {Object} Parameters for the request + - [user] : {String} If present, the user to filter the memberships to. + """ + path = "/projects/%s/project_memberships" % (project) + return self.client.get_collection(path, params, **options) + + def find_by_id(self, project_membership, params={}, **options): + """Returns the project membership record. + + Parameters + ---------- + project_membership : {Gid} Globally unique identifier for the project membership. + [params] : {Object} Parameters for the request + """ + path = "/project_memberships/%s" % (project_membership) + return self.client.get(path, params, **options) + diff --git a/asana/resources/project_statuses.py b/asana/resources/project_statuses.py new file mode 100644 index 00000000..397e0bec --- /dev/null +++ b/asana/resources/project_statuses.py @@ -0,0 +1,56 @@ + +from .gen.project_statuses import _ProjectStatuses + +class ProjectStatuses(_ProjectStatuses): + """Project Statuses resource""" + def create(self, project, params={}, **options): + self.create_in_project(project, params, **options) + + def create_in_project(self, project, params={}, **options): + """Creates a new status update on the project. + + Returns the full record of the newly created project status update. + + Parameters + ---------- + project : {Gid} The project on which to create a status update. + [data] : {Object} Data for the request + - text : {String} The text of the project status update. + - color : {String} The color to associate with the status update. Must be one of `"red"`, `"yellow"`, or `"green"`. + """ + path = "/projects/%s/project_statuses" % (project) + return self.client.post(path, params, **options) + + def find_by_project(self, project, params={}, **options): + """Returns the compact project status update records for all updates on the project. + + Parameters + ---------- + project : {Gid} The project to find status updates for. + [params] : {Object} Parameters for the request + """ + path = "/projects/%s/project_statuses" % (project) + return self.client.get_collection(path, params, **options) + + def find_by_id(self, project_status, params={}, **options): + """Returns the complete record for a single status update. + + Parameters + ---------- + project-status : {Gid} The project status update to get. + [params] : {Object} Parameters for the request + """ + path = "/project_statuses/%s" % (project_status) + return self.client.get(path, params, **options) + + def delete(self, project_status, params={}, **options): + """Deletes a specific, existing project status update. + + Returns an empty data record. + + Parameters + ---------- + project-status : {Gid} The project status update to delete. + """ + path = "/project_statuses/%s" % (project_status) + return self.client.delete(path, params, **options) diff --git a/asana/resources/project_templates.py b/asana/resources/project_templates.py new file mode 100644 index 00000000..3715a537 --- /dev/null +++ b/asana/resources/project_templates.py @@ -0,0 +1,6 @@ + +from .gen.project_templates import _ProjectTemplates + +class ProjectTemplates(_ProjectTemplates): + """ProjectTemplates resource""" + pass diff --git a/asana/resources/projects.py b/asana/resources/projects.py new file mode 100644 index 00000000..d4c38c9f --- /dev/null +++ b/asana/resources/projects.py @@ -0,0 +1,258 @@ + +from .gen.projects import _Projects + +class Projects(_Projects): + """Projects resource""" + def create(self, params={}, **options): + """Creates a new project in a workspace or team. + + Every project is required to be created in a specific workspace or + organization, and this cannot be changed once set. Note that you can use + the `workspace` parameter regardless of whether or not it is an + organization. + + If the workspace for your project _is_ an organization, you must also + supply a `team` to share the project with. + + Returns the full record of the newly created project. + + Parameters + ---------- + [data] : {Object} Data for the request + - workspace : {Gid} The workspace or organization to create the project in. + - [team] : {Gid} If creating in an organization, the specific team to create the + project in. + """ + return self.client.post("/projects", params, **options) + + def create_in_workspace(self, workspace, params={}, **options): + """If the workspace for your project _is_ an organization, you must also + supply a `team` to share the project with. + + Returns the full record of the newly created project. + + Parameters + ---------- + workspace : {Gid} The workspace or organization to create the project in. + [data] : {Object} Data for the request + """ + path = "/workspaces/%s/projects" % (workspace) + return self.client.post(path, params, **options) + + def create_in_team(self, team, params={}, **options): + """Creates a project shared with the given team. + + Returns the full record of the newly created project. + + Parameters + ---------- + team : {Gid} The team to create the project in. + [data] : {Object} Data for the request + """ + path = "/teams/%s/projects" % (team) + return self.client.post(path, params, **options) + + def find_by_id(self, project, params={}, **options): + """Returns the complete project record for a single project. + + Parameters + ---------- + project : {Gid} The project to get. + [params] : {Object} Parameters for the request + """ + path = "/projects/%s" % (project) + return self.client.get(path, params, **options) + + def update(self, project, params={}, **options): + """A specific, existing project can be updated by making a PUT request on the + URL for that project. Only the fields provided in the `data` block will be + updated; any unspecified fields will remain unchanged. + + When using this method, it is best to specify only those fields you wish + to change, or else you may overwrite changes made by another user since + you last retrieved the task. + + Returns the complete updated project record. + + Parameters + ---------- + project : {Gid} The project to update. + [data] : {Object} Data for the request + """ + path = "/projects/%s" % (project) + return self.client.put(path, params, **options) + + def delete(self, project, params={}, **options): + """A specific, existing project can be deleted by making a DELETE request + on the URL for that project. + + Returns an empty data record. + + Parameters + ---------- + project : {Gid} The project to delete. + """ + path = "/projects/%s" % (project) + return self.client.delete(path, params, **options) + + def duplicate_project(self, project, params={}, **options): + """Creates and returns a job that will asynchronously handle the duplication. + + Parameters + ---------- + project : {Gid} The project to duplicate. + [data] : {Object} Data for the request + - name : {String} The name of the new project. + - [team] : {Gid} Sets the team of the new project. If team is not defined, the new project + will be in the same team as the the original project. + - [include] : {Array} The elements that will be duplicated to the new project. + Tasks are always included. + - [schedule_dates] : {String} A dictionary of options to auto-shift dates. + `task_dates` must be included to use this option. + Requires either `start_on` or `due_on`, but not both. + `start_on` will set the first start date of the new + project to the given date, while `due_on` will set the last due date + to the given date. Both will offset the remaining dates by the same amount + of the original project. + """ + path = "/projects/%s/duplicate" % (project) + return self.client.post(path, params, **options) + + def find_all(self, params={}, **options): + """Returns the compact project records for some filtered set of projects. + Use one or more of the parameters provided to filter the projects returned. + + Parameters + ---------- + [params] : {Object} Parameters for the request + - [workspace] : {Gid} The workspace or organization to filter projects on. + - [team] : {Gid} The team to filter projects on. + - [is_template] : {Boolean} **Note: This parameter can only be included if a team is also defined, or the workspace is not an organization** + Filters results to include only template projects. + - [archived] : {Boolean} Only return projects whose `archived` field takes on the value of + this parameter. + """ + return self.client.get_collection("/projects", params, **options) + + def find_by_workspace(self, workspace, params={}, **options): + """Returns the compact project records for all projects in the workspace. + + Parameters + ---------- + workspace : {Gid} The workspace or organization to find projects in. + [params] : {Object} Parameters for the request + - [is_template] : {Boolean} **Note: This parameter can only be included if a team is also defined, or the workspace is not an organization** + Filters results to include only template projects. + - [archived] : {Boolean} Only return projects whose `archived` field takes on the value of + this parameter. + """ + path = "/workspaces/%s/projects" % (workspace) + return self.client.get_collection(path, params, **options) + + def find_by_team(self, team, params={}, **options): + """Returns the compact project records for all projects in the team. + + Parameters + ---------- + team : {Gid} The team to find projects in. + [params] : {Object} Parameters for the request + - [is_template] : {Boolean} Filters results to include only template projects. + - [archived] : {Boolean} Only return projects whose `archived` field takes on the value of + this parameter. + """ + path = "/teams/%s/projects" % (team) + return self.client.get_collection(path, params, **options) + + def tasks(self, project, params={}, **options): + """Returns the compact task records for all tasks within the given project, + ordered by their priority within the project. Tasks can exist in more than one project at a time. + + Parameters + ---------- + project : {Gid} The project in which to search for tasks. + [params] : {Object} Parameters for the request + """ + path = "/projects/%s/tasks" % (project) + return self.client.get_collection(path, params, **options) + + def add_followers(self, project, params={}, **options): + """Adds the specified list of users as followers to the project. Followers are a subset of members, therefore if + the users are not already members of the project they will also become members as a result of this operation. + Returns the updated project record. + + Parameters + ---------- + project : {Gid} The project to add followers to. + [data] : {Object} Data for the request + - followers : {Array} An array of followers to add to the project. + """ + path = "/projects/%s/addFollowers" % (project) + return self.client.post(path, params, **options) + + def remove_followers(self, project, params={}, **options): + """Removes the specified list of users from following the project, this will not affect project membership status. + Returns the updated project record. + + Parameters + ---------- + project : {Gid} The project to remove followers from. + [data] : {Object} Data for the request + - followers : {Array} An array of followers to remove from the project. + """ + path = "/projects/%s/removeFollowers" % (project) + return self.client.post(path, params, **options) + + def add_members(self, project, params={}, **options): + """Adds the specified list of users as members of the project. Returns the updated project record. + + Parameters + ---------- + project : {Gid} The project to add members to. + [data] : {Object} Data for the request + - members : {Array} An array of user ids. + """ + path = "/projects/%s/addMembers" % (project) + return self.client.post(path, params, **options) + + def remove_members(self, project, params={}, **options): + """Removes the specified list of members from the project. Returns the updated project record. + + Parameters + ---------- + project : {Gid} The project to remove members from. + [data] : {Object} Data for the request + - members : {Array} An array of user ids. + """ + path = "/projects/%s/removeMembers" % (project) + return self.client.post(path, params, **options) + + def add_custom_field_setting(self, project, params={}, **options): + """Create a new custom field setting on the project. + + Parameters + ---------- + project : {Gid} The project to associate the custom field with + [data] : {Object} Data for the request + - custom_field : {Gid} The id of the custom field to associate with this project. + - [is_important] : {Boolean} Whether this field should be considered important to this project. + - [insert_before] : {Gid} An id of a Custom Field Settings on this project, before which the new Custom Field Settings will be added. + `insert_before` and `insert_after` parameters cannot both be specified. + - [insert_after] : {Gid} An id of a Custom Field Settings on this project, after which the new Custom Field Settings will be added. + `insert_before` and `insert_after` parameters cannot both be specified. + """ + path = "/projects/%s/addCustomFieldSetting" % (project) + return self.client.post(path, params, **options) + + def remove_custom_field_setting(self, project, params={}, **options): + """Remove a custom field setting on the project. + + Parameters + ---------- + project : {Gid} The project to associate the custom field with + [data] : {Object} Data for the request + - [custom_field] : {Gid} The id of the custom field to remove from this project. + """ + path = "/projects/%s/removeCustomFieldSetting" % (project) + return self.client.post(path, params, **options) + + diff --git a/asana/resources/sections.py b/asana/resources/sections.py new file mode 100644 index 00000000..002acedc --- /dev/null +++ b/asana/resources/sections.py @@ -0,0 +1,119 @@ +from .gen.sections import _Sections + + +class Sections(_Sections): + """The :class:`Sections` object, which represents the resource of the same + name in Asana's API. + + """ + def create_in_project(self, project, params={}, **options): + """Creates a new section in a project. + + Returns the full record of the newly created section. + + Parameters + ---------- + project : {Gid} The project to create the section in + [data] : {Object} Data for the request + - name : {String} The text to be displayed as the section name. This cannot be an empty string. + """ + path = "/projects/%s/sections" % (project) + return self.client.post(path, params, **options) + + def find_by_project(self, project, params={}, **options): + """Returns the compact records for all sections in the specified project. + + Parameters + ---------- + project : {Gid} The project to get sections from. + [params] : {Object} Parameters for the request + """ + path = "/projects/%s/sections" % (project) + return self.client.get_collection(path, params, **options) + + def find_by_id(self, section, params={}, **options): + """Returns the complete record for a single section. + + Parameters + ---------- + section : {Gid} The section to get. + [params] : {Object} Parameters for the request + """ + path = "/sections/%s" % (section) + return self.client.get(path, params, **options) + + def update(self, section, params={}, **options): + """A specific, existing section can be updated by making a PUT request on + the URL for that project. Only the fields provided in the `data` block + will be updated; any unspecified fields will remain unchanged. (note that + at this time, the only field that can be updated is the `name` field.) + + When using this method, it is best to specify only those fields you wish + to change, or else you may overwrite changes made by another user since + you last retrieved the task. + + Returns the complete updated section record. + + Parameters + ---------- + section : {Gid} The section to update. + [data] : {Object} Data for the request + """ + path = "/sections/%s" % (section) + return self.client.put(path, params, **options) + + def delete(self, section, params={}, **options): + """A specific, existing section can be deleted by making a DELETE request + on the URL for that section. + + Note that sections must be empty to be deleted. + + The last remaining section in a board view cannot be deleted. + + Returns an empty data block. + + Parameters + ---------- + section : {Gid} The section to delete. + """ + path = "/sections/%s" % (section) + return self.client.delete(path, params, **options) + + def add_task(self, section, params={}, **options): + """Add a task to a specific, existing section. This will remove the task from other sections of the project. + + The task will be inserted at the top of a section unless an `insert_before` or `insert_after` parameter is declared. + + This does not work for separators (tasks with the `resource_subtype` of section). + + Parameters + ---------- + section : {Gid} The section to add a task to + [data] : {Object} Data for the request + - task : {Gid} The task to add to this section + - [insert_before] : {Gid} Insert the given task immediately before the task specified by this parameter. Cannot be provided together with `insert_after`. + - [insert_after] : {Gid} Insert the given task immediately after the task specified by this parameter. Cannot be provided together with `insert_before`. + """ + path = "/sections/%s/addTask" % (section) + return self.client.post(path, params, **options) + + def insert_in_project(self, project, params={}, **options): + """Move sections relative to each other in a board view. One of + `before_section` or `after_section` is required. + + Sections cannot be moved between projects. + + At this point in time, moving sections is not supported in list views, only board views. + + Returns an empty data block. + + Parameters + ---------- + project : {Gid} The project in which to reorder the given section + [data] : {Object} Data for the request + - section : {Gid} The section to reorder + - [before_section] : {Gid} Insert the given section immediately before the section specified by this parameter. + - [after_section] : {Gid} Insert the given section immediately after the section specified by this parameter. + """ + path = "/projects/%s/sections/insert" % (project) + return self.client.post(path, params, **options) diff --git a/asana/resources/status_updates.py b/asana/resources/status_updates.py new file mode 100644 index 00000000..c061a7bb --- /dev/null +++ b/asana/resources/status_updates.py @@ -0,0 +1,6 @@ + +from .gen.status_updates import _StatusUpdates + +class StatusUpdates(_StatusUpdates): + """Goals resource""" + pass diff --git a/asana/resources/stories.py b/asana/resources/stories.py new file mode 100644 index 00000000..edf2913c --- /dev/null +++ b/asana/resources/stories.py @@ -0,0 +1,70 @@ + +from .gen.stories import _Stories + +class Stories(_Stories): + """Stories resource""" + def find_by_task(self, task, params={}, **options): + """Returns the compact records for all stories on the task. + + Parameters + ---------- + task : {Gid} Globally unique identifier for the task. + [params] : {Object} Parameters for the request + """ + path = "/tasks/%s/stories" % (task) + return self.client.get_collection(path, params, **options) + + def find_by_id(self, story, params={}, **options): + """Returns the full record for a single story. + + Parameters + ---------- + story : {Gid} Globally unique identifier for the story. + [params] : {Object} Parameters for the request + """ + path = "/stories/%s" % (story) + return self.client.get(path, params, **options) + + def create_on_task(self, task, params={}, **options): + """Adds a comment to a task. The comment will be authored by the + currently authenticated user, and timestamped when the server receives + the request. + + Returns the full record for the new story added to the task. + + Parameters + ---------- + task : {Id} Globally unique identifier for the task. + [data] : {Object} Data for the request + - text : {String} The plain text of the comment to add. + """ + path = "/tasks/%s/stories" % (task) + return self.client.post(path, params, **options) + + def update(self, story, params={}, **options): + """Updates the story and returns the full record for the updated story. + Only comment stories can have their text updated, and only comment stories and + attachment stories can be pinned. Only one of `text` and `html_text` can be specified. + + Parameters + ---------- + story : {Gid} Globally unique identifier for the story. + [data] : {Object} Data for the request + - [text] : {String} The plain text with which to update the comment. + - [html_text] : {String} The rich text with which to update the comment. + - [is_pinned] : {Boolean} Whether the story should be pinned on the resource. + """ + path = "/stories/%s" % (story) + return self.client.put(path, params, **options) + + def delete(self, story, params={}, **options): + """Deletes a story. A user can only delete stories they have created. Returns an empty data record. + + Parameters + ---------- + story : {Gid} Globally unique identifier for the story. + """ + path = "/stories/%s" % (story) + return self.client.delete(path, params, **options) + + diff --git a/asana/resources/tags.py b/asana/resources/tags.py new file mode 100644 index 00000000..20356310 --- /dev/null +++ b/asana/resources/tags.py @@ -0,0 +1,118 @@ + +from .gen.tags import _Tags + +class Tags(_Tags): + """Tags resource""" + def create(self, params={}, **options): + """Creates a new tag in a workspace or organization. + + Every tag is required to be created in a specific workspace or + organization, and this cannot be changed once set. Note that you can use + the `workspace` parameter regardless of whether or not it is an + organization. + + Returns the full record of the newly created tag. + + Parameters + ---------- + [data] : {Object} Data for the request + - workspace : {Gid} The workspace or organization to create the tag in. + """ + return self.client.post("/tags", params, **options) + + def create_in_workspace(self, workspace, params={}, **options): + """Creates a new tag in a workspace or organization. + + Every tag is required to be created in a specific workspace or + organization, and this cannot be changed once set. Note that you can use + the `workspace` parameter regardless of whether or not it is an + organization. + + Returns the full record of the newly created tag. + + Parameters + ---------- + workspace : {Gid} The workspace or organization to create the tag in. + [data] : {Object} Data for the request + """ + path = "/workspaces/%s/tags" % (workspace) + return self.client.post(path, params, **options) + + def find_by_id(self, tag, params={}, **options): + """Returns the complete tag record for a single tag. + + Parameters + ---------- + tag : {Gid} The tag to get. + [params] : {Object} Parameters for the request + """ + path = "/tags/%s" % (tag) + return self.client.get(path, params, **options) + + def update(self, tag, params={}, **options): + """Updates the properties of a tag. Only the fields provided in the `data` + block will be updated; any unspecified fields will remain unchanged. + + When using this method, it is best to specify only those fields you wish + to change, or else you may overwrite changes made by another user since + you last retrieved the task. + + Returns the complete updated tag record. + + Parameters + ---------- + tag : {Gid} The tag to update. + [data] : {Object} Data for the request + """ + path = "/tags/%s" % (tag) + return self.client.put(path, params, **options) + + def delete(self, tag, params={}, **options): + """A specific, existing tag can be deleted by making a DELETE request + on the URL for that tag. + + Returns an empty data record. + + Parameters + ---------- + tag : {Gid} The tag to delete. + """ + path = "/tags/%s" % (tag) + return self.client.delete(path, params, **options) + + def find_all(self, params={}, **options): + """Returns the compact tag records for some filtered set of tags. + Use one or more of the parameters provided to filter the tags returned. + + Parameters + ---------- + [params] : {Object} Parameters for the request + - [workspace] : {Gid} The workspace or organization to filter tags on. + - [team] : {Gid} The team to filter tags on. + - [archived] : {Boolean} Only return tags whose `archived` field takes on the value of + this parameter. + """ + return self.client.get_collection("/tags", params, **options) + + def find_by_workspace(self, workspace, params={}, **options): + """Returns the compact tag records for all tags in the workspace. + + Parameters + ---------- + workspace : {Gid} The workspace or organization to find tags in. + [params] : {Object} Parameters for the request + """ + path = "/workspaces/%s/tags" % (workspace) + return self.client.get_collection(path, params, **options) + + def get_tasks_with_tag(self, tag, params={}, **options): + """Returns the compact task records for all tasks with the given tag. + Tasks can have more than one tag at a time. + Parameters + ---------- + tag : {Id} The tag to fetch tasks from. + [params] : {Object} Parameters for the request + """ + path = "/tags/%s/tasks" % (tag) + return self.client.get_collection(path, params, **options) + diff --git a/asana/resources/tasks.py b/asana/resources/tasks.py new file mode 100644 index 00000000..0f6436a6 --- /dev/null +++ b/asana/resources/tasks.py @@ -0,0 +1,472 @@ + +from .gen.tasks import _Tasks + +class Tasks(_Tasks): + """Tasks resource""" + def set_parent(self, task_id, params={}, **options): + """Changes the parent of a task. Each task may only be a subtask of a single + parent, or no parent task at all. Returns an empty data block. + + Parameters + ---------- + task : {Id} Globally unique identifier for the task. + [data] : {Object} Data for the request + - parent : {Id} The new parent of the task, or `null` for no parent. + """ + path = '/tasks/%s/setParent' % (task_id) + return self.client.post(path, params, **options) + + def create(self, params={}, **options): + """Creating a new task is as easy as POSTing to the `/tasks` endpoint + with a data block containing the fields you'd like to set on the task. + Any unspecified fields will take on default values. + + Every task is required to be created in a specific workspace, and this + workspace cannot be changed once set. The workspace need not be set + explicitly if you specify `projects` or a `parent` task instead. + + `projects` can be a comma separated list of projects, or just a single + project the task should belong to. + + Parameters + ---------- + [data] : {Object} Data for the request + - [workspace] : {Gid} The workspace to create a task in. + """ + return self.client.post("/tasks", params, **options) + + def create_in_workspace(self, workspace, params={}, **options): + """Creating a new task is as easy as POSTing to the `/tasks` endpoint + with a data block containing the fields you'd like to set on the task. + Any unspecified fields will take on default values. + + Every task is required to be created in a specific workspace, and this + workspace cannot be changed once set. The workspace need not be set + explicitly if you specify a `project` or a `parent` task instead. + + Parameters + ---------- + workspace : {Gid} The workspace to create a task in. + [data] : {Object} Data for the request + """ + path = "/workspaces/%s/tasks" % (workspace) + return self.client.post(path, params, **options) + + def find_by_id(self, task, params={}, **options): + """Returns the complete task record for a single task. + + Parameters + ---------- + task : {Gid} The task to get. + [params] : {Object} Parameters for the request + """ + path = "/tasks/%s" % (task) + return self.client.get(path, params, **options) + + def update(self, task, params={}, **options): + """A specific, existing task can be updated by making a PUT request on the + URL for that task. Only the fields provided in the `data` block will be + updated; any unspecified fields will remain unchanged. + + When using this method, it is best to specify only those fields you wish + to change, or else you may overwrite changes made by another user since + you last retrieved the task. + + Returns the complete updated task record. + + Parameters + ---------- + task : {Gid} The task to update. + [data] : {Object} Data for the request + """ + path = "/tasks/%s" % (task) + return self.client.put(path, params, **options) + + def delete(self, task, params={}, **options): + """A specific, existing task can be deleted by making a DELETE request on the + URL for that task. Deleted tasks go into the "trash" of the user making + the delete request. Tasks can be recovered from the trash within a period + of 30 days; afterward they are completely removed from the system. + + Returns an empty data record. + + Parameters + ---------- + task : {Gid} The task to delete. + """ + path = "/tasks/%s" % (task) + return self.client.delete(path, params, **options) + + def duplicate_task(self, task, params={}, **options): + """Creates and returns a job that will asynchronously handle the duplication. + + Parameters + ---------- + task : {Gid} The task to duplicate. + [data] : {Object} Data for the request + - name : {String} The name of the new task. + - [include] : {Array} The fields that will be duplicated to the new task. + """ + path = "/tasks/%s/duplicate" % (task) + return self.client.post(path, params, **options) + + def find_by_project(self, project, params={}, **options): + """Returns the compact task records for all tasks within the given project, + ordered by their priority within the project. + + Parameters + ---------- + project : {Gid} The project in which to search for tasks. + [params] : {Object} Parameters for the request + """ + path = "/projects/%s/tasks" % (project) + return self.client.get_collection(path, params, **options) + + def find_by_tag(self, tag, params={}, **options): + """Returns the compact task records for all tasks with the given tag. + + Parameters + ---------- + tag : {Gid} The tag in which to search for tasks. + [params] : {Object} Parameters for the request + """ + path = "/tags/%s/tasks" % (tag) + return self.client.get_collection(path, params, **options) + + def find_by_section(self, section, params={}, **options): + """Board view only: Returns the compact section records for all tasks within the given section. + + Parameters + ---------- + section : {Gid} The section in which to search for tasks. + [params] : {Object} Parameters for the request + """ + path = "/sections/%s/tasks" % (section) + return self.client.get_collection(path, params, **options) + + def find_by_user_task_list(self, user_task_list, params={}, **options): + """Returns the compact list of tasks in a user's My Tasks list. The returned + tasks will be in order within each assignee status group of `Inbox`, + `Today`, and `Upcoming`. + + **Note:** tasks in `Later` have a different ordering in the Asana web app + than the other assignee status groups; this endpoint will still return + them in list order in `Later` (differently than they show up in Asana, + but the same order as in Asana's mobile apps). + + **Note:** Access control is enforced for this endpoint as with all Asana + API endpoints, meaning a user's private tasks will be filtered out if the + API-authenticated user does not have access to them. + + **Note:** Both complete and incomplete tasks are returned by default + unless they are filtered out (for example, setting `completed_since=now` + will return only incomplete tasks, which is the default view for "My + Tasks" in Asana.) + + Parameters + ---------- + user_task_list : {Gid} The user task list in which to search for tasks. + [params] : {Object} Parameters for the request + - [completed_since] : {String} Only return tasks that are either incomplete or that have been + completed since this time. + """ + path = "/user_task_lists/%s/tasks" % (user_task_list) + return self.client.get_collection(path, params, **options) + + def find_all(self, params={}, **options): + """Returns the compact task records for some filtered set of tasks. Use one + or more of the parameters provided to filter the tasks returned. You must + specify a `project`, `section`, `tag`, or `user_task_list` if you do not + specify `assignee` and `workspace`. + + Parameters + ---------- + [params] : {Object} Parameters for the request + - [assignee] : {String} The assignee to filter tasks on. + - [workspace] : {Gid} The workspace or organization to filter tasks on. + - [project] : {Gid} The project to filter tasks on. + - [section] : {Gid} The section to filter tasks on. + - [tag] : {Gid} The tag to filter tasks on. + - [user_task_list] : {Gid} The user task list to filter tasks on. + - [completed_since] : {String} Only return tasks that are either incomplete or that have been + completed since this time. + - [modified_since] : {String} Only return tasks that have been modified since the given time. + """ + return self.client.get_collection("/tasks", params, **options) + + def search_in_workspace(self, workspace, params={}, **options): + """The search endpoint allows you to build complex queries to find and fetch exactly the data you need from Asana. For a more comprehensive description of all the query parameters and limitations of this endpoint, see our [long-form documentation](/developers/documentation/getting-started/search-api) for this feature. + + Parameters + ---------- + workspace : {Gid} The workspace or organization in which to search for tasks. + [params] : {Object} Parameters for the request + - [resource_subtype] : {Enum} Filters results by the task's resource_subtype. + """ + path = "/workspaces/%s/tasks/search" % (workspace) + return self.client.get_collection(path, params, **options) + + def dependencies(self, task, params={}, **options): + """Returns the compact representations of all of the dependencies of a task. + + Parameters + ---------- + task : {Gid} The task to get dependencies on. + [params] : {Object} Parameters for the request + """ + path = "/tasks/%s/dependencies" % (task) + return self.client.get(path, params, **options) + + def dependents(self, task, params={}, **options): + """Returns the compact representations of all of the dependents of a task. + + Parameters + ---------- + task : {Gid} The task to get dependents on. + [params] : {Object} Parameters for the request + """ + path = "/tasks/%s/dependents" % (task) + return self.client.get(path, params, **options) + + def add_dependencies(self, task, params={}, **options): + """Marks a set of tasks as dependencies of this task, if they are not + already dependencies. *A task can have at most 15 dependencies.* + + Parameters + ---------- + task : {Gid} The task to add dependencies to. + [data] : {Object} Data for the request + - dependencies : {Array} An array of task IDs that this task should depend on. + """ + path = "/tasks/%s/addDependencies" % (task) + return self.client.post(path, params, **options) + + def add_dependents(self, task, params={}, **options): + """Marks a set of tasks as dependents of this task, if they are not already + dependents. *A task can have at most 30 dependents.* + + Parameters + ---------- + task : {Gid} The task to add dependents to. + [data] : {Object} Data for the request + - dependents : {Array} An array of task IDs that should depend on this task. + """ + path = "/tasks/%s/addDependents" % (task) + return self.client.post(path, params, **options) + + def remove_dependencies(self, task, params={}, **options): + """Unlinks a set of dependencies from this task. + + Parameters + ---------- + task : {Gid} The task to remove dependencies from. + [data] : {Object} Data for the request + - dependencies : {Array} An array of task IDs to remove as dependencies. + """ + path = "/tasks/%s/removeDependencies" % (task) + return self.client.post(path, params, **options) + + def remove_dependents(self, task, params={}, **options): + """Unlinks a set of dependents from this task. + + Parameters + ---------- + task : {Gid} The task to remove dependents from. + [data] : {Object} Data for the request + - dependents : {Array} An array of task IDs to remove as dependents. + """ + path = "/tasks/%s/removeDependents" % (task) + return self.client.post(path, params, **options) + + def add_followers(self, task, params={}, **options): + """Adds each of the specified followers to the task, if they are not already + following. Returns the complete, updated record for the affected task. + + Parameters + ---------- + task : {Gid} The task to add followers to. + [data] : {Object} Data for the request + - followers : {Array} An array of followers to add to the task. + """ + path = "/tasks/%s/addFollowers" % (task) + return self.client.post(path, params, **options) + + def remove_followers(self, task, params={}, **options): + """Removes each of the specified followers from the task if they are + following. Returns the complete, updated record for the affected task. + + Parameters + ---------- + task : {Gid} The task to remove followers from. + [data] : {Object} Data for the request + - followers : {Array} An array of followers to remove from the task. + """ + path = "/tasks/%s/removeFollowers" % (task) + return self.client.post(path, params, **options) + + def projects(self, task, params={}, **options): + """Returns a compact representation of all of the projects the task is in. + + Parameters + ---------- + task : {Gid} The task to get projects on. + [params] : {Object} Parameters for the request + """ + path = "/tasks/%s/projects" % (task) + return self.client.get_collection(path, params, **options) + + def add_project(self, task, params={}, **options): + """Adds the task to the specified project, in the optional location + specified. If no location arguments are given, the task will be added to + the end of the project. + + `addProject` can also be used to reorder a task within a project or section that + already contains it. + + At most one of `insert_before`, `insert_after`, or `section` should be + specified. Inserting into a section in an non-order-dependent way can be + done by specifying `section`, otherwise, to insert within a section in a + particular place, specify `insert_before` or `insert_after` and a task + within the section to anchor the position of this task. + + Returns an empty data block. + + Parameters + ---------- + task : {Gid} The task to add to a project. + [data] : {Object} Data for the request + - project : {Gid} The project to add the task to. + - [insert_after] : {Gid} A task in the project to insert the task after, or `null` to + insert at the beginning of the list. + - [insert_before] : {Gid} A task in the project to insert the task before, or `null` to + insert at the end of the list. + - [section] : {Gid} A section in the project to insert the task into. The task will be + inserted at the bottom of the section. + """ + path = "/tasks/%s/addProject" % (task) + return self.client.post(path, params, **options) + + def remove_project(self, task, params={}, **options): + """Removes the task from the specified project. The task will still exist + in the system, but it will not be in the project anymore. + + Returns an empty data block. + + Parameters + ---------- + task : {Gid} The task to remove from a project. + [data] : {Object} Data for the request + - project : {Gid} The project to remove the task from. + """ + path = "/tasks/%s/removeProject" % (task) + return self.client.post(path, params, **options) + + def tags(self, task, params={}, **options): + """Returns a compact representation of all of the tags the task has. + + Parameters + ---------- + task : {Gid} The task to get tags on. + [params] : {Object} Parameters for the request + """ + path = "/tasks/%s/tags" % (task) + return self.client.get_collection(path, params, **options) + + def add_tag(self, task, params={}, **options): + """Adds a tag to a task. Returns an empty data block. + + Parameters + ---------- + task : {Gid} The task to add a tag to. + [data] : {Object} Data for the request + - tag : {Gid} The tag to add to the task. + """ + path = "/tasks/%s/addTag" % (task) + return self.client.post(path, params, **options) + + def remove_tag(self, task, params={}, **options): + """Removes a tag from the task. Returns an empty data block. + + Parameters + ---------- + task : {Gid} The task to remove a tag from. + [data] : {Object} Data for the request + - tag : {Gid} The tag to remove from the task. + """ + path = "/tasks/%s/removeTag" % (task) + return self.client.post(path, params, **options) + + def subtasks(self, task, params={}, **options): + """Returns a compact representation of all of the subtasks of a task. + + Parameters + ---------- + task : {Gid} The task to get the subtasks of. + [params] : {Object} Parameters for the request + """ + path = "/tasks/%s/subtasks" % (task) + return self.client.get_collection(path, params, **options) + + def add_subtask(self, task, params={}, **options): + """Creates a new subtask and adds it to the parent task. Returns the full record + for the newly created subtask. + + Parameters + ---------- + task : {Gid} The task to add a subtask to. + [data] : {Object} Data for the request + """ + path = "/tasks/%s/subtasks" % (task) + return self.client.post(path, params, **options) + + def stories(self, task, params={}, **options): + """Returns a compact representation of all of the stories on the task. + + Parameters + ---------- + task : {Gid} The task containing the stories to get. + [params] : {Object} Parameters for the request + """ + path = "/tasks/%s/stories" % (task) + return self.client.get_collection(path, params, **options) + + def add_comment(self, task, params={}, **options): + """Adds a comment to a task. The comment will be authored by the + currently authenticated user, and timestamped when the server receives + the request. + + Returns the full record for the new story added to the task. + + Parameters + ---------- + task : {Id} Globally unique identifier for the task. + [data] : {Object} Data for the request + - text : {String} The plain text of the comment to add. + """ + path = "/tasks/%s/stories" % (task) + return self.client.post(path, params, **options) + + def insert_in_user_task_list(self, user_task_list, params={}, **options): + """Insert or reorder tasks in a user's My Tasks list. If the task was not + assigned to the owner of the user task list it will be reassigned when + this endpoint is called. If neither `insert_before` nor `insert_after` + are provided the task will be inserted at the top of the assignee's + inbox. + + Returns an empty data block. + + Parameters + ---------- + user_task_list : {Gid} Globally unique identifier for the user task list. + [data] : {Object} Data for the request + - task : {Gid} Globally unique identifier for the task. + - [insert_before] : {Gid} Insert the task before the task specified by this field. The inserted + task will inherit the `assignee_status` of this task. `insert_before` + and `insert_after` parameters cannot both be specified. + - [insert_after] : {Gid} Insert the task after the task specified by this field. The inserted + task will inherit the `assignee_status` of this task. `insert_before` + and `insert_after` parameters cannot both be specified. + """ + path = "/user_task_lists/%s/tasks/insert" % (user_task_list) + return self.client.post(path, params, **options) + diff --git a/asana/resources/team_memberships.py b/asana/resources/team_memberships.py new file mode 100644 index 00000000..b3bba790 --- /dev/null +++ b/asana/resources/team_memberships.py @@ -0,0 +1,6 @@ + +from .gen.team_memberships import _TeamMemberships + +class TeamMemberships(_TeamMemberships): + """TeamMemberships resource""" + pass diff --git a/asana/resources/teams.py b/asana/resources/teams.py new file mode 100644 index 00000000..737f7374 --- /dev/null +++ b/asana/resources/teams.py @@ -0,0 +1,86 @@ + +from .gen.teams import _Teams + +class Teams(_Teams): + """Teams resource""" + def find_by_id(self, team, params={}, **options): + """Returns the full record for a single team. + + Parameters + ---------- + team : {Id} Globally unique identifier for the team. + [params] : {Object} Parameters for the request + """ + path = "/teams/%s" % (team) + return self.client.get(path, params, **options) + + def find_by_organization(self, organization, params={}, **options): + """Returns the compact records for all teams in the organization visible to + the authorized user. + + Parameters + ---------- + organization : {Id} Globally unique identifier for the workspace or organization. + [params] : {Object} Parameters for the request + """ + path = "/organizations/%s/teams" % (organization) + return self.client.get_collection(path, params, **options) + + def find_by_user(self, user, params={}, **options): + """Returns the compact records for all teams to which user is assigned. + + Parameters + ---------- + user : {String} An identifier for the user. Can be one of an email address, + the globally unique identifier for the user, or the keyword `me` + to indicate the current user making the request. + [params] : {Object} Parameters for the request + - [organization] : {Id} The workspace or organization to filter teams on. + """ + path = "/users/%s/teams" % (user) + return self.client.get_collection(path, params, **options) + + def users(self, team, params={}, **options): + """Returns the compact records for all users that are members of the team. + + Parameters + ---------- + team : {Id} Globally unique identifier for the team. + [params] : {Object} Parameters for the request + """ + path = "/teams/%s/users" % (team) + return self.client.get_collection(path, params, **options) + + def add_user(self, team, params={}, **options): + """The user making this call must be a member of the team in order to add others. + The user to add must exist in the same organization as the team in order to be added. + The user to add can be referenced by their globally unique user ID or their email address. + Returns the full user record for the added user. + + Parameters + ---------- + team : {Id} Globally unique identifier for the team. + [data] : {Object} Data for the request + - user : {String} An identifier for the user. Can be one of an email address, + the globally unique identifier for the user, or the keyword `me` + to indicate the current user making the request. + """ + path = "/teams/%s/addUser" % (team) + return self.client.post(path, params, **options) + + def remove_user(self, team, params={}, **options): + """The user to remove can be referenced by their globally unique user ID or their email address. + Removes the user from the specified team. Returns an empty data record. + + Parameters + ---------- + team : {Id} Globally unique identifier for the team. + [data] : {Object} Data for the request + - user : {String} An identifier for the user. Can be one of an email address, + the globally unique identifier for the user, or the keyword `me` + to indicate the current user making the request. + """ + path = "/teams/%s/removeUser" % (team) + return self.client.post(path, params, **options) + + diff --git a/asana/resources/time_periods.py b/asana/resources/time_periods.py new file mode 100644 index 00000000..1980735b --- /dev/null +++ b/asana/resources/time_periods.py @@ -0,0 +1,6 @@ + +from .gen.time_periods import _TimePeriods + +class TimePeriods(_TimePeriods): + """TimePeriods resource""" + pass diff --git a/asana/resources/typeahead.py b/asana/resources/typeahead.py new file mode 100644 index 00000000..bfb36814 --- /dev/null +++ b/asana/resources/typeahead.py @@ -0,0 +1,6 @@ + +from .gen.typeahead import _Typeahead + +class Typeahead(_Typeahead): + """Typeahead resource""" + pass diff --git a/asana/resources/user_task_lists.py b/asana/resources/user_task_lists.py new file mode 100644 index 00000000..db4a3b70 --- /dev/null +++ b/asana/resources/user_task_lists.py @@ -0,0 +1,60 @@ + +from .gen.user_task_lists import _UserTaskLists + +class UserTaskLists(_UserTaskLists): + """User Task Lists resource""" + def find_by_user(self, user, params={}, **options): + """Returns the full record for the user task list for the given user + + Parameters + ---------- + user : {String} An identifier for the user. Can be one of an email address, + the globally unique identifier for the user, or the keyword `me` + to indicate the current user making the request. + [params] : {Object} Parameters for the request + - workspace : {Gid} Globally unique identifier for the workspace or organization. + """ + path = "/users/%s/user_task_list" % (user) + return self.client.get(path, params, **options) + + def find_by_id(self, user_task_list, params={}, **options): + """Returns the full record for a user task list. + + Parameters + ---------- + user_task_list : {Gid} Globally unique identifier for the user task list. + [params] : {Object} Parameters for the request + """ + path = "/user_task_lists/%s" % (user_task_list) + return self.client.get(path, params, **options) + + def tasks(self, user_task_list, params={}, **options): + """Returns the compact list of tasks in a user's My Tasks list. The returned + tasks will be in order within each assignee status group of `Inbox`, + `Today`, and `Upcoming`. + + **Note:** tasks in `Later` have a different ordering in the Asana web app + than the other assignee status groups; this endpoint will still return + them in list order in `Later` (differently than they show up in Asana, + but the same order as in Asana's mobile apps). + + **Note:** Access control is enforced for this endpoint as with all Asana + API endpoints, meaning a user's private tasks will be filtered out if the + API-authenticated user does not have access to them. + + **Note:** Both complete and incomplete tasks are returned by default + unless they are filtered out (for example, setting `completed_since=now` + will return only incomplete tasks, which is the default view for "My + Tasks" in Asana.) + + Parameters + ---------- + user_task_list : {Gid} The user task list in which to search for tasks. + [params] : {Object} Parameters for the request + - [completed_since] : {String} Only return tasks that are either incomplete or that have been + completed since this time. + """ + path = "/user_task_lists/%s/tasks" % (user_task_list) + return self.client.get_collection(path, params, **options) + + diff --git a/asana/resources/users.py b/asana/resources/users.py new file mode 100644 index 00000000..98ab7b97 --- /dev/null +++ b/asana/resources/users.py @@ -0,0 +1,68 @@ + +from .gen.users import _Users + +class Users(_Users): + """Users resource""" + def me(self, params={}, **options): + """Returns the full user record for the currently authenticated user. + + Parameters + ---------- + [params] : {Object} Parameters for the request + """ + return self.client.get("/users/me", params, **options) + + def find_by_id(self, user, params={}, **options): + """Returns the full user record for the single user with the provided ID. + + Parameters + ---------- + user : {String} An identifier for the user. Can be one of an email address, + the globally unique identifier for the user, or the keyword `me` + to indicate the current user making the request. + [params] : {Object} Parameters for the request + """ + path = "/users/%s" % (user) + return self.client.get(path, params, **options) + + def get_user_favorites(self, user, params={}, **options): + """Returns all of a user's favorites in the given workspace, of the given type. + Results are given in order (The same order as Asana's sidebar). + + Parameters + ---------- + user : {String} An identifier for the user. Can be one of an email address, + the globally unique identifier for the user, or the keyword `me` + to indicate the current user making the request. + [params] : {Object} Parameters for the request + - workspace : {Id} The workspace in which to get favorites. + - resource_type : {Enum} The resource type of favorites to be returned. + """ + path = "/users/%s/favorites" % (user) + return self.client.get_collection(path, params, **options) + + def find_by_workspace(self, workspace, params={}, **options): + """Returns the user records for all users in the specified workspace or + organization. + + Parameters + ---------- + workspace : {Id} The workspace in which to get users. + [params] : {Object} Parameters for the request + """ + path = "/workspaces/%s/users" % (workspace) + return self.client.get_collection(path, params, **options) + + def find_all(self, params={}, **options): + """Returns the user records for all users in all workspaces and organizations + accessible to the authenticated user. Accepts an optional workspace ID + parameter. + + Parameters + ---------- + [params] : {Object} Parameters for the request + - [workspace] : {Id} The workspace or organization to filter users on. + """ + return self.client.get_collection("/users", params, **options) + + diff --git a/asana/resources/webhooks.py b/asana/resources/webhooks.py new file mode 100644 index 00000000..25e79536 --- /dev/null +++ b/asana/resources/webhooks.py @@ -0,0 +1,64 @@ + +from .gen.webhooks import _Webhooks + +class Webhooks(_Webhooks): + """Webhooks resource""" + def create(self, params={}, **options): + """Establishing a webhook is a two-part process. First, a simple HTTP POST + similar to any other resource creation. Since you could have multiple + webhooks we recommend specifying a unique local id for each target. + + Next comes the confirmation handshake. When a webhook is created, we will + send a test POST to the `target` with an `X-Hook-Secret` header as + described in the + [Resthooks Security documentation](http://resthooks.org/docs/security/). + The target must respond with a `200 OK` and a matching `X-Hook-Secret` + header to confirm that this webhook subscription is indeed expected. + + If you do not acknowledge the webhook's confirmation handshake it will + fail to setup, and you will receive an error in response to your attempt + to create it. This means you need to be able to receive and complete the + webhook *while* the POST request is in-flight. + + Parameters + ---------- + resource : {Id} A resource ID to subscribe to. The resource can be a task or project. + target : {String} The URL to receive the HTTP POST. + [data] : {Object} Data for the request + """ + return self.client.post("/webhooks", params, **options) + + def get_all(self, params={}, **options): + """Returns the compact representation of all webhooks your app has + registered for the authenticated user in the given workspace. + + Parameters + ---------- + workspace : {Id} The workspace to query for webhooks in. + [params] : {Object} Parameters for the request + - [resource] : {Id} Only return webhooks for the given resource. + """ + return self.client.get_collection("/webhooks", params, **options) + + def get_by_id(self, webhook, params={}, **options): + """Returns the full record for the given webhook. + + Parameters + ---------- + webhook : {Id} The webhook to get. + [params] : {Object} Parameters for the request + """ + path = "/webhooks/%s" % (webhook) + return self.client.get(path, params, **options) + + def delete_by_id(self, webhook, params={}, **options): + """This method permanently removes a webhook. Note that it may be possible + to receive a request that was already in flight after deleting the + webhook, but no further requests will be issued. + + Parameters + ---------- + webhook : {Id} The webhook to delete. + """ + path = "/webhooks/%s" % (webhook) + return self.client.delete(path, params, **options) diff --git a/asana/resources/workspace_memberships.py b/asana/resources/workspace_memberships.py new file mode 100644 index 00000000..daecf713 --- /dev/null +++ b/asana/resources/workspace_memberships.py @@ -0,0 +1,6 @@ + +from .gen.workspace_memberships import _WorkspaceMemberships + +class WorkspaceMemberships(_WorkspaceMemberships): + """WorkspaceMemberships resource""" + pass diff --git a/asana/resources/workspaces.py b/asana/resources/workspaces.py new file mode 100644 index 00000000..c1fd2166 --- /dev/null +++ b/asana/resources/workspaces.py @@ -0,0 +1,97 @@ + +from .gen.workspaces import _Workspaces + +class Workspaces(_Workspaces): + """Workspaces resource""" + def find_by_id(self, workspace, params={}, **options): + """Returns the full workspace record for a single workspace. + + Parameters + ---------- + workspace : {Id} Globally unique identifier for the workspace or organization. + [params] : {Object} Parameters for the request + """ + path = "/workspaces/%s" % (workspace) + return self.client.get(path, params, **options) + + def find_all(self, params={}, **options): + """Returns the compact records for all workspaces visible to the authorized user. + + Parameters + ---------- + [params] : {Object} Parameters for the request + """ + return self.client.get_collection("/workspaces", params, **options) + + def update(self, workspace, params={}, **options): + """A specific, existing workspace can be updated by making a PUT request on + the URL for that workspace. Only the fields provided in the data block + will be updated; any unspecified fields will remain unchanged. + + Currently the only field that can be modified for a workspace is its `name`. + + Returns the complete, updated workspace record. + + Parameters + ---------- + workspace : {Id} The workspace to update. + [data] : {Object} Data for the request + """ + path = "/workspaces/%s" % (workspace) + return self.client.put(path, params, **options) + + def typeahead(self, workspace, params={}, **options): + """Retrieves objects in the workspace based on an auto-completion/typeahead + search algorithm. This feature is meant to provide results quickly, so do + not rely on this API to provide extremely accurate search results. The + result set is limited to a single page of results with a maximum size, + so you won't be able to fetch large numbers of results. + + Parameters + ---------- + workspace : {Id} The workspace to fetch objects from. + [params] : {Object} Parameters for the request + - resource_type : {Enum} The type of values the typeahead should return. You can choose from + one of the following: custom_field, project, tag, task, and user. + Note that unlike in the names of endpoints, the types listed here are + in singular form (e.g. `task`). Using multiple types is not yet supported. + - [type] : {Enum} **Deprecated: new integrations should prefer the resource_type field.** + - [query] : {String} The string that will be used to search for relevant objects. If an + empty string is passed in, the API will currently return an empty + result set. + - [count] : {Number} The number of results to return. The default is `20` if this + parameter is omitted, with a minimum of `1` and a maximum of `100`. + If there are fewer results found than requested, all will be returned. + """ + path = "/workspaces/%s/typeahead" % (workspace) + return self.client.get_collection(path, params, **options) + + def add_user(self, workspace, params={}, **options): + """The user can be referenced by their globally unique user ID or their email address. + Returns the full user record for the invited user. + + Parameters + ---------- + workspace : {Id} The workspace or organization to invite the user to. + [data] : {Object} Data for the request + - user : {String} An identifier for the user. Can be one of an email address, + the globally unique identifier for the user, or the keyword `me` + to indicate the current user making the request. + """ + path = "/workspaces/%s/addUser" % (workspace) + return self.client.post(path, params, **options) + + def remove_user(self, workspace, params={}, **options): + """The user making this call must be an admin in the workspace. + Returns an empty data record. + + Parameters + ---------- + workspace : {Id} The workspace or organization to invite the user to. + [data] : {Object} Data for the request + - user : {String} An identifier for the user. Can be one of an email address, + the globally unique identifier for the user, or the keyword `me` + to indicate the current user making the request. + """ + path = "/workspaces/%s/removeUser" % (workspace) + return self.client.post(path, params, **options) diff --git a/asana/rest.py b/asana/rest.py deleted file mode 100644 index 8b169f7f..00000000 --- a/asana/rest.py +++ /dev/null @@ -1,317 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import io -import json -import logging -import re -import ssl - -import certifi -# python 2 and python 3 compatibility library -import six -from six.moves.urllib.parse import urlencode - -try: - import urllib3 -except ImportError: - raise ImportError('Swagger python client requires urllib3.') - - -logger = logging.getLogger(__name__) - - -class RESTResponse(io.IOBase): - - def __init__(self, resp): - self.urllib3_response = resp - self.status = resp.status - self.reason = resp.reason - self.data = resp.data - - def getheaders(self): - """Returns a dictionary of the response headers.""" - return self.urllib3_response.getheaders() - - def getheader(self, name, default=None): - """Returns a given response header.""" - return self.urllib3_response.getheader(name, default) - - -class RESTClientObject(object): - - def __init__(self, configuration, pools_size=4, maxsize=None): - # urllib3.PoolManager will pass all kw parameters to connectionpool - # https://github.com/shazow/urllib3/blob/f9409436f83aeb79fbaf090181cd81b784f1b8ce/urllib3/poolmanager.py#L75 # noqa: E501 - # https://github.com/shazow/urllib3/blob/f9409436f83aeb79fbaf090181cd81b784f1b8ce/urllib3/connectionpool.py#L680 # noqa: E501 - # maxsize is the number of requests to host that are allowed in parallel # noqa: E501 - # Custom SSL certificates and client certificates: http://urllib3.readthedocs.io/en/latest/advanced-usage.html # noqa: E501 - - # cert_reqs - if configuration.verify_ssl: - cert_reqs = ssl.CERT_REQUIRED - else: - cert_reqs = ssl.CERT_NONE - - # ca_certs - if configuration.ssl_ca_cert: - ca_certs = configuration.ssl_ca_cert - else: - # if not set certificate file, use Mozilla's root certificates. - ca_certs = certifi.where() - - addition_pool_args = {} - if configuration.assert_hostname is not None: - addition_pool_args['assert_hostname'] = configuration.assert_hostname # noqa: E501 - - if maxsize is None: - if configuration.connection_pool_maxsize is not None: - maxsize = configuration.connection_pool_maxsize - else: - maxsize = 4 - - # https pool manager - if configuration.proxy: - self.pool_manager = urllib3.ProxyManager( - num_pools=pools_size, - maxsize=maxsize, - cert_reqs=cert_reqs, - ca_certs=ca_certs, - cert_file=configuration.cert_file, - key_file=configuration.key_file, - proxy_url=configuration.proxy, - **addition_pool_args - ) - else: - self.pool_manager = urllib3.PoolManager( - num_pools=pools_size, - maxsize=maxsize, - cert_reqs=cert_reqs, - ca_certs=ca_certs, - cert_file=configuration.cert_file, - key_file=configuration.key_file, - **addition_pool_args - ) - - def request(self, method, url, query_params=None, headers=None, - body=None, post_params=None, _preload_content=True, - _request_timeout=None): - """Perform requests. - - :param method: http request method - :param url: http request url - :param query_params: query parameters in the url - :param headers: http request headers - :param body: request json body, for `application/json` - :param post_params: request post parameters, - `application/x-www-form-urlencoded` - and `multipart/form-data` - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - """ - method = method.upper() - assert method in ['GET', 'HEAD', 'DELETE', 'POST', 'PUT', - 'PATCH', 'OPTIONS'] - - if post_params and body: - raise ValueError( - "body parameter cannot be used with post_params parameter." - ) - - post_params = post_params or {} - headers = headers or {} - - timeout = None - if _request_timeout: - if isinstance(_request_timeout, (int, ) if six.PY3 else (int, long)): # noqa: E501,F821 - timeout = urllib3.Timeout(total=_request_timeout) - elif (isinstance(_request_timeout, tuple) and - len(_request_timeout) == 2): - timeout = urllib3.Timeout( - connect=_request_timeout[0], read=_request_timeout[1]) - - if 'Content-Type' not in headers: - headers['Content-Type'] = 'application/json' - - try: - # For `POST`, `PUT`, `PATCH`, `OPTIONS`, `DELETE` - if method in ['POST', 'PUT', 'PATCH', 'OPTIONS', 'DELETE']: - if query_params: - url += '?' + urlencode(query_params) - if re.search('json', headers['Content-Type'], re.IGNORECASE): - request_body = '{}' - if body is not None: - request_body = json.dumps(body) - r = self.pool_manager.request( - method, url, - body=request_body, - preload_content=_preload_content, - timeout=timeout, - headers=headers) - elif headers['Content-Type'] == 'application/x-www-form-urlencoded': # noqa: E501 - r = self.pool_manager.request( - method, url, - fields=post_params, - encode_multipart=False, - preload_content=_preload_content, - timeout=timeout, - headers=headers) - elif headers['Content-Type'] == 'multipart/form-data': - # must del headers['Content-Type'], or the correct - # Content-Type which generated by urllib3 will be - # overwritten. - del headers['Content-Type'] - r = self.pool_manager.request( - method, url, - fields=post_params, - encode_multipart=True, - preload_content=_preload_content, - timeout=timeout, - headers=headers) - # Pass a `string` parameter directly in the body to support - # other content types than Json when `body` argument is - # provided in serialized form - elif isinstance(body, str): - request_body = body - r = self.pool_manager.request( - method, url, - body=request_body, - preload_content=_preload_content, - timeout=timeout, - headers=headers) - else: - # Cannot generate the request from given parameters - msg = """Cannot prepare a request message for provided - arguments. Please check that your arguments match - declared content type.""" - raise ApiException(status=0, reason=msg) - # For `GET`, `HEAD` - else: - r = self.pool_manager.request(method, url, - fields=query_params, - preload_content=_preload_content, - timeout=timeout, - headers=headers) - except urllib3.exceptions.SSLError as e: - msg = "{0}\n{1}".format(type(e).__name__, str(e)) - raise ApiException(status=0, reason=msg) - - if _preload_content: - r = RESTResponse(r) - - # log response body - logger.debug("response body: %s", r.data) - - if not 200 <= r.status <= 299: - raise ApiException(http_resp=r) - - return r - - def GET(self, url, headers=None, query_params=None, _preload_content=True, - _request_timeout=None): - return self.request("GET", url, - headers=headers, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - query_params=query_params) - - def HEAD(self, url, headers=None, query_params=None, _preload_content=True, - _request_timeout=None): - return self.request("HEAD", url, - headers=headers, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - query_params=query_params) - - def OPTIONS(self, url, headers=None, query_params=None, post_params=None, - body=None, _preload_content=True, _request_timeout=None): - return self.request("OPTIONS", url, - headers=headers, - query_params=query_params, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - - def DELETE(self, url, headers=None, query_params=None, body=None, - _preload_content=True, _request_timeout=None): - return self.request("DELETE", url, - headers=headers, - query_params=query_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - - def POST(self, url, headers=None, query_params=None, post_params=None, - body=None, _preload_content=True, _request_timeout=None): - return self.request("POST", url, - headers=headers, - query_params=query_params, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - - def PUT(self, url, headers=None, query_params=None, post_params=None, - body=None, _preload_content=True, _request_timeout=None): - return self.request("PUT", url, - headers=headers, - query_params=query_params, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - - def PATCH(self, url, headers=None, query_params=None, post_params=None, - body=None, _preload_content=True, _request_timeout=None): - return self.request("PATCH", url, - headers=headers, - query_params=query_params, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - - -class ApiException(Exception): - - def __init__(self, status=None, reason=None, http_resp=None): - if http_resp: - self.status = http_resp.status - self.reason = http_resp.reason - self.body = http_resp.data - self.headers = http_resp.getheaders() - else: - self.status = status - self.reason = reason - self.body = None - self.headers = None - - def __str__(self): - """Custom error messages for exception""" - error_message = "({0})\n"\ - "Reason: {1}\n".format(self.status, self.reason) - if self.headers: - error_message += "HTTP response headers: {0}\n".format( - self.headers) - - if self.body: - error_message += "HTTP response body: {0}\n".format(self.body) - - return error_message diff --git a/asana/session.py b/asana/session.py new file mode 100644 index 00000000..1d0276ce --- /dev/null +++ b/asana/session.py @@ -0,0 +1,20 @@ +import requests +import requests_oauthlib + +class AsanaOAuth2Session(requests_oauthlib.OAuth2Session): + """Session class for making OAuth authenticated requests to Asana's API""" + + authorize_url = 'https://app.asana.com/-/oauth_authorize' + token_url = 'https://app.asana.com/-/oauth_token' + + def __init__(self, client_secret=None, **kwargs): + super(AsanaOAuth2Session, self).__init__(**kwargs) + self.client_secret = client_secret + + def authorization_url(self): + """Get a URL (and 'state' token) to redirect the user to for authentication""" + return super(AsanaOAuth2Session, self).authorization_url(self.authorize_url) + + def fetch_token(self, **kwargs): + """Exchange a code (and 'state' token) for a bearer token""" + return super(AsanaOAuth2Session, self).fetch_token(self.token_url, client_secret=self.client_secret, **kwargs) diff --git a/asana/version.py b/asana/version.py new file mode 100644 index 00000000..b50da94d --- /dev/null +++ b/asana/version.py @@ -0,0 +1 @@ +__version__ = '3.2.1' diff --git a/codegen/swagger/README.md b/codegen/swagger/README.md deleted file mode 100644 index ca6b3110..00000000 --- a/codegen/swagger/README.md +++ /dev/null @@ -1,74 +0,0 @@ -# Swagger Codegen for the AsanaPythonClientCodegen library - -## Overview -This is a boiler-plate project to generate your own client library with Swagger. Its goal is -to get you started with the basic plumbing so you can put in your own logic. It won't work without -your changes applied. - -## What's Swagger? -The goal of Swagger™ is to define a standard, language-agnostic interface to REST APIs which allows both humans and computers to discover and understand the capabilities of the service without access to source code, documentation, or through network traffic inspection. When properly defined via Swagger, a consumer can understand and interact with the remote service with a minimal amount of implementation logic. Similar to what interfaces have done for lower-level programming, Swagger removes the guesswork in calling the service. - - -Check out [OpenAPI-Spec](https://github.com/OAI/OpenAPI-Specification) for additional information about the Swagger project, including additional libraries with support for other languages and more. - -## How do I use this? -At this point, you've likely generated a client setup. It will include something along these lines: - -``` -. -|- README.md // this file -|- pom.xml // build script -|-- src -|--- main -|---- java -|----- com.asana.codegen.AsanaPythonClientCodegenGenerator.java // generator file -|---- resources -|----- AsanaPythonClientCodegen // template files -|----- META-INF -|------ services -|------- io.swagger.codegen.CodegenConfig -``` - -You _will_ need to make changes in at least the following: - -`AsanaPythonClientCodegenGenerator.java` - -Templates in this folder: - -`src/main/resources/AsanaPythonClientCodegen` - -Once modified, you can run this: - -``` -mvn package -``` - -In your generator project. A single jar file will be produced in `target`. You can now use that with codegen: - -``` -java -cp /path/to/swagger-codegen-cli.jar:/path/to/your.jar io.swagger.codegen.v3.cli.SwaggerCodegen -l AsanaPythonClientCodegen -i /path/to/swagger.yaml -o ./test -``` - -Now your templates are available to the client generator and you can write output values - -## But how do I modify this? -The `ReadMe.java` has comments in it--lots of comments. There is no good substitute -for reading the code more, though. See how the `ReadMe` implements `CodegenConfig`. -That class has the signature of all values that can be overridden. - -For the templates themselves, you have a number of values available to you for generation. -You can execute the `java` command from above while passing different debug flags to show -the object you have available during client generation: - -``` -# The following additional debug options are available for all codegen targets: -# -DdebugSwagger prints the OpenAPI Specification as interpreted by the codegen -# -DdebugModels prints models passed to the template engine -# -DdebugOperations prints operations passed to the template engine -# -DdebugSupportingFiles prints additional data passed to the template engine - -java -DdebugOperations -cp /path/to/swagger-codegen-cli.jar:/path/to/your.jar io.swagger.codegen.Codegen -l AsanaPythonClientCodegen -i /path/to/swagger.yaml -o ./test -``` - -Will, for example, output the debug info for operations. You can use this info -in the `api.mustache` file. diff --git a/codegen/swagger/pom.xml b/codegen/swagger/pom.xml deleted file mode 100644 index edd08158..00000000 --- a/codegen/swagger/pom.xml +++ /dev/null @@ -1,129 +0,0 @@ - - 4.0.0 - io.swagger - AsanaClientCodegen-swagger-codegen - jar - AsanaClientCodegen-swagger-codegen - 1.0.0 - - - - org.apache.maven.plugins - maven-enforcer-plugin - 3.0.0-M1 - - - enforce-maven - - enforce - - - - - 2.2.0 - - - - - - - - org.apache.maven.plugins - maven-surefire-plugin - 2.12 - - - - loggerPath - conf/log4j.properties - - - -Xms512m -Xmx1500m - methods - pertest - - - - - - org.apache.maven.plugins - maven-jar-plugin - 2.2 - - - - jar - test-jar - - - - - - - - - org.codehaus.mojo - build-helper-maven-plugin - ${build-helper-maven-plugin} - - - add_sources - generate-sources - - add-source - - - - src/main/java - - - - - add_test_sources - generate-test-sources - - add-test-source - - - - src/test/java - - - - - - - org.apache.maven.plugins - maven-compiler-plugin - 3.6.1 - - 1.8 - 1.8 - - - - - - - io.swagger.codegen.v3 - swagger-codegen - ${swagger-codegen-version} - provided - - - io.swagger.codegen.v3 - swagger-codegen-generators - ${swagger-codegen-generators-version} - provided - - - - UTF-8 - 3.0.44 - 1.0.41 - 1.0.0 - 4.13.1 - 3.0.0 - - diff --git a/codegen/swagger/src/main/java/com/asana/codegen/ExampleUtility.java b/codegen/swagger/src/main/java/com/asana/codegen/ExampleUtility.java deleted file mode 100644 index 634e95c0..00000000 --- a/codegen/swagger/src/main/java/com/asana/codegen/ExampleUtility.java +++ /dev/null @@ -1,27 +0,0 @@ -package com.asana.codegen; - -import org.json.*; -import io.swagger.codegen.v3.*; - -class ExampleUtility { - public static void tryToSetExample(CodegenParameter p) { - JSONObject obj = new JSONObject(p.jsonSchema); - - if (obj.has("example")) { - p.example = obj.get("example").toString(); - return; - } - - if (!obj.has("schema")) { - return; - } - - JSONObject schema = obj.getJSONObject("schema"); - - if (!schema.has("example")) { - return; - } - - p.example = schema.get("example").toString(); - } -} diff --git a/codegen/swagger/src/main/java/com/asana/codegen/PythonClientCodegenGenerator.java b/codegen/swagger/src/main/java/com/asana/codegen/PythonClientCodegenGenerator.java deleted file mode 100644 index cf275e55..00000000 --- a/codegen/swagger/src/main/java/com/asana/codegen/PythonClientCodegenGenerator.java +++ /dev/null @@ -1,69 +0,0 @@ -package com.asana.codegen; - -import java.util.Map; - -import org.json.*; -import io.swagger.codegen.v3.generators.python.*; -import io.swagger.v3.oas.models.OpenAPI; -import io.swagger.v3.oas.models.Operation; -import io.swagger.v3.oas.models.media.Schema; -import io.swagger.codegen.v3.*; - -public class PythonClientCodegenGenerator extends PythonClientCodegen { - public PythonClientCodegenGenerator() { - super(); - apiDocTemplateFiles.put("code_samples.mustache", ".yaml"); - } - - @Override - public void processOpts() { - // custom generators do not set the CodegenConstants - additionalProperties.put(CodegenConstants.PACKAGE_NAME, "asana"); - setPackageName("asana"); - - additionalProperties.put(CodegenConstants.PROJECT_NAME, "asana"); - setProjectName("asana"); - - // Super must be called AFTER our modification, otherwise the package name - // somehow ends up wrong - super.processOpts(); - } - - @Override - public void setParameterExampleValue(CodegenParameter p) { - // Our example correction code must execute before super, to ensure that - // super does its special magic of determining the example type: - // https://github.com/swagger-api/swagger-codegen-generators/blob/master/src/main/java/io/swagger/codegen/v3/generators/python/PythonClientCodegen.java#L639 - ExampleUtility.tryToSetExample(p); - - // "CSV" is used to declare that a query param string is joined by commas. - // If that's the case, we can use the raw JSON representation as a valid - // python list as the syntax is the same - if ("csv".equalsIgnoreCase(p.collectionFormat)) { - return; - } - - super.setParameterExampleValue(p); - - String type = p.baseType; - if (type == null) { - type = p.dataType; - } - - // Update example for requests that require body - if (!languageSpecificPrimitives.contains(type)) { - // type is a model class, e.g. User - String bodyData = "({\"param1\": \"value1\", \"param2\": \"value2\",})"; - p.example = this.packageName + "." + type + bodyData; - } - } - - @Override - public CodegenOperation fromOperation(String path, String httpMethod, Operation operation, Map schemas, OpenAPI openAPI) { - CodegenOperation op = super.fromOperation(path, httpMethod, operation, schemas, openAPI); - if(op.operationId.equalsIgnoreCase("search_tasks_for_workspace")) { - op.vendorExtensions.put("x-codegen-isSearchTasksForWorkspace", true); - } - return op; - } -} diff --git a/codegen/swagger/src/main/java/com/asana/codegen/ReadMe.java b/codegen/swagger/src/main/java/com/asana/codegen/ReadMe.java deleted file mode 100644 index 749193ac..00000000 --- a/codegen/swagger/src/main/java/com/asana/codegen/ReadMe.java +++ /dev/null @@ -1,164 +0,0 @@ -package com.asana.codegen; - -import io.swagger.codegen.v3.*; -import io.swagger.codegen.v3.generators.DefaultCodegenConfig; - -import java.util.*; -import java.io.File; - -public class ReadMe extends DefaultCodegenConfig { - - // source folder where to write the files - protected String sourceFolder = "src"; - protected String apiVersion = "1.0.0"; - - /** - * Configures the type of generator. - * - * @return the CodegenType for this generator - * @see io.swagger.codegen.CodegenType - */ - public CodegenType getTag() { - return CodegenType.CLIENT; - } - - /** - * Configures a friendly name for the generator. This will be used by the generator - * to select the library with the -l flag. - * - * @return the friendly name for the generator - */ - public String getName() { - return "AsanaPythonClientCodegen"; - } - - /** - * Returns human-friendly help for the generator. Provide the consumer with help - * tips, parameters here - * - * @return A string value for the help message - */ - public String getHelp() { - return "Generates a AsanaPythonClientCodegen client library."; - } - - public ReadMe() { - super(); - - // set the output folder here - outputFolder = "generated-code/AsanaPythonClientCodegen"; - - /** - * Models. You can write model files using the modelTemplateFiles map. - * if you want to create one template for file, you can do so here. - * for multiple files for model, just put another entry in the `modelTemplateFiles` with - * a different extension - */ - modelTemplateFiles.put( - "model.mustache", // the template to use - ".sample"); // the extension for each file to write - - /** - * Api classes. You can write classes for each Api file with the apiTemplateFiles map. - * as with models, add multiple entries with different extensions for multiple files per - * class - */ - apiTemplateFiles.put( - "api.mustache", // the template to use - ".sample"); // the extension for each file to write - - /** - * Template Location. This is the location which templates will be read from. The generator - * will use the resource stream to attempt to read the templates. - */ - templateDir = "AsanaPythonClientCodegen"; - - /** - * Api Package. Optional, if needed, this can be used in templates - */ - apiPackage = "io.swagger.client.api"; - - /** - * Model Package. Optional, if needed, this can be used in templates - */ - modelPackage = "io.swagger.client.model"; - - /** - * Reserved words. Override this with reserved words specific to your language - */ - reservedWords = new HashSet ( - Arrays.asList( - "sample1", // replace with static values - "sample2") - ); - - /** - * Additional Properties. These values can be passed to the templates and - * are available in models, apis, and supporting files - */ - additionalProperties.put("apiVersion", apiVersion); - - /** - * Supporting Files. You can write single files for the generator with the - * entire object tree available. If the input file has a suffix of `.mustache - * it will be processed by the template engine. Otherwise, it will be copied - */ - supportingFiles.add(new SupportingFile("myFile.mustache", // the input template or file - "", // the destination folder, relative `outputFolder` - "myFile.sample") // the output file - ); - - /** - * Language Specific Primitives. These types will not trigger imports by - * the client generator - */ - languageSpecificPrimitives = new HashSet( - Arrays.asList( - "Type1", // replace these with your types - "Type2") - ); - } - - /** - * Escapes a reserved word as defined in the `reservedWords` array. Handle escaping - * those terms here. This logic is only called if a variable matches the reserved words - * - * @return the escaped term - */ - @Override - public String escapeReservedWord(String name) { - return "_" + name; // add an underscore to the name - } - - /** - * Location to write model files. You can use the modelPackage() as defined when the class is - * instantiated - */ - public String modelFileFolder() { - return outputFolder + "/" + sourceFolder + "/" + modelPackage().replace('.', File.separatorChar); - } - - /** - * Location to write api files. You can use the apiPackage() as defined when the class is - * instantiated - */ - @Override - public String apiFileFolder() { - return outputFolder + "/" + sourceFolder + "/" + apiPackage().replace('.', File.separatorChar); - } - - @Override - public String getArgumentsLocation() { - return null; - } - - @Override - protected String getTemplateDir() { - return templateDir; - } - - @Override - public String getDefaultTemplateDir() { - return templateDir; - } -} diff --git a/codegen/swagger/src/main/resources/META-INF/services/io.swagger.codegen.v3.CodegenConfig b/codegen/swagger/src/main/resources/META-INF/services/io.swagger.codegen.v3.CodegenConfig deleted file mode 100644 index 33505366..00000000 --- a/codegen/swagger/src/main/resources/META-INF/services/io.swagger.codegen.v3.CodegenConfig +++ /dev/null @@ -1 +0,0 @@ -com.asana.codegen.PythonClientCodegenGenerator diff --git a/codegen/templates/README.mustache b/codegen/templates/README.mustache deleted file mode 100644 index d6eaa529..00000000 --- a/codegen/templates/README.mustache +++ /dev/null @@ -1,641 +0,0 @@ -# {{{projectName}}} [![GitHub release][release-image]]() [![Build][github-actions-image]][github-actions-url] [![PyPi Version][pypi-image]][pypi-url] - -Python client library for Asana - -- API version: {{appVersion}} -- Package version: {{packageVersion}} -{{^hideGenerationTimestamp}} -- Build date: {{generatedDate}} -{{/hideGenerationTimestamp}} - -## Requirements. - -Python 3.4+ - -## Installation & Usage -### pip install from [PyPI](https://pypi.org/project/asana/) - -```sh -pip install {{{projectName}}} -``` - -Then import the package: -```python -import {{{packageName}}} -``` - -### Setuptools - -Install via [Setuptools](http://pypi.python.org/pypi/setuptools). - -```sh -python setup.py install --user -``` -(or `sudo python setup.py install` to install the package for all users) - -Then import the package: -```python -import {{{packageName}}} -``` - -## Getting Started - -Please follow the [installation procedure](#installation--usage) and then run the following: - -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -# create an instance of the API class -users_api_instance = {{{packageName}}}.UsersApi(api_client) -user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. -opt_fields = ["email","name","photo","photo.image_1024x1024","photo.image_128x128","photo.image_21x21","photo.image_27x27","photo.image_36x36","photo.image_60x60","workspaces","workspaces.name"] # list[str] | Properties to include in the response. Set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a user - api_response = users_api_instance.get_user(user_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling UsersApi->get_user: %s\n" % e) -``` - -### Example: GET, POST, PUT, DELETE on tasks - -#### GET - get multiple tasks -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -# create an instance of the API class -tasks_api_instance = {{{packageName}}}.TasksApi(api_client) -limit = 50 -project = "" -opt_fields = [ - "assignee_section", - "due_at", - "name", - "completed_at", - "completed_by", - "tags", - "dependents", - "hearts", - "liked", - "projects", - "completed", - "num_hearts", - "permalink_url", - "parent", - "assignee", - "assignee_status", - "num_subtasks", - "start_on", - "dependencies", - "is_rendered_as_separator", - "modified_at", - "approval_status", - "notes", - "memberships", - "workspace", - "due_on", - "hearted", - "created_at", - "likes", - "num_likes", - "custom_fields", - "external", - "html_notes", - "followers", - "start_at", - "resource_subtype", - "actual_time_minutes", -] - -try: - # GET - get multiple tasks - api_response = tasks_api_instance.get_tasks( - limit=limit, project=project, opt_fields=opt_fields - ) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->get_tasks: %s\n" % e) -``` - -#### POST - create a task -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -# create an instance of the API class -tasks_api_instance = {{{packageName}}}.TasksApi(api_client) -body = {{{packageName}}}.TasksBody( - { - "name": "New Task", - "projects": [""], - } -) - -try: - # POST - create a task - api_response = tasks_api_instance.create_task(body) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->create_task: %s\n" % e) -``` - -#### PUT - update a task -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -# create an instance of the API class -tasks_api_instance = {{{packageName}}}.TasksApi(api_client) -task_gid = "" -body = {{{packageName}}}.TasksBody( - { - "name": "Updated Task", - } -) - -try: - # PUT - update a task - api_response = tasks_api_instance.update_task(body, task_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->update_task: %s\n" % e) -``` - -#### DELETE - delete a task -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -# create an instance of the API class -tasks_api_instance = {{{packageName}}}.TasksApi(api_client) -task_gid = "" - -try: - # DELETE - delete a task - api_response = tasks_api_instance.delete_task(task_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->delete_task: %s\n" % e) -``` - -## Documentation for API Endpoints - -All URIs are relative to *{{basePath}}* - -Class | Method | HTTP request | Description ------------- | ------------- | ------------- | ------------- -{{#apiInfo}}{{#apis}}{{#operations}}{{#operation}}*{{classname}}* | [**{{operationId}}**]({{apiDocPath}}{{classname}}.md#{{operationIdLowerCase}}) | **{{httpMethod}}** {{path}} | {{#summary}}{{summary}}{{/summary}} -{{/operation}}{{/operations}}{{/apis}}{{/apiInfo}} - -## Documentation For Models - -{{#models}}{{#model}} - [{{{classname}}}]({{modelDocPath}}{{{classname}}}.md) -{{/model}}{{/models}} - -## Documentation For Authorization - -{{^authMethods}} All endpoints do not require authorization. -{{/authMethods}}{{#authMethods}}{{#last}} Authentication schemes defined for the API:{{/last}}{{/authMethods}} -{{#authMethods}}## {{{name}}} - -{{#isApiKey}}- **Type**: API key -- **API key parameter name**: {{{keyParamName}}} -- **Location**: {{#isKeyInQuery}}URL query string{{/isKeyInQuery}}{{#isKeyInHeader}}HTTP header{{/isKeyInHeader}} -{{/isApiKey}} -{{#isBasic}}- **Type**: HTTP basic authentication -{{/isBasic}} -{{#isOAuth}}- **Type**: OAuth -- **Flow**: {{{flow}}} -- **Authorization URL**: {{{authorizationUrl}}} -- **Scopes**: {{^scopes}}N/A{{/scopes}} -{{#each scopes}} - **{{@key}}**: {{this}} -{{/each}} -{{/isOAuth}} - -{{/authMethods}} - -## Getting events - -In order to get events you will need a sync token. This sync token can be acquired in the error message from the initial -request to [get_events](docs/EventsApi.md#get_events). - -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -# create an instance of the API class -events_api_instance = {{{packageName}}}.EventsApi(api_client) -resource = '12345' # str | A resource ID to subscribe to. The resource can be a task or project. -sync = '' # str | A sync token received from the last request, or none on first sync. Events will be returned from the point in time that the sync token was generated. *Note: On your first request, omit the sync token. The response will be the same as for an expired sync token, and will include a new valid sync token.If the sync token is too old (which may happen from time to time) the API will return a `412 Precondition Failed` error, and include a fresh sync token in the response.* (optional) - -try: - # Initial request to get the sync token - api_response = events_api_instance.get_events(resource, sync=sync) -except ApiException as e: - # Set the sync token - sync = json.loads(e.body.decode('utf-8'))['sync'] - -try: - # Follow up request to get events - api_response = events_api_instance.get_events(resource, sync=sync) - pprint(api_response) -except ApiException as e: - print("Exception when calling EventsApi->get_events: %s\n" % e) -``` - -## Pagination - -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -# create an instance of the API class -task_api_instance = {{{packageName}}}.TasksApi(api_client) -limit = 10 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -project = '321654' # str | The project to filter tasks on. (optional) - -try: - # Get multiple tasks with next_page - offset = None - while True: - # If the "offset" is None make a request without providing the offset query parameter - # Asana throws an error if we make a request with a "offset" query param of None - if offset is None: - api_response = task_api_instance.get_tasks(limit=limit, project=project) - else: - api_response = task_api_instance.get_tasks(limit=limit, project=project, offset=offset) - - # Do something - # EX: print response - pprint(api_response) - - # Check to see if there is a next_page - if api_response.next_page: - offset = api_response.next_page.offset - else: - break -except ApiException as e: - print("Exception when calling TasksApi->get_tasks: %s\n" % e) -``` - -## Accessing repsonse data - -By default, the client library returns a class object of the resource. You can use dot notation to access the response data. - -TIP: look at the "Return type" section of the documented endpoint to understand which properties are accessible. (EX: [get_task](docs/TasksApi.md#get_task)) - -### Example: Accessing task data (dot notation) -```python -. -. -. -try: - task = tasks_api_instance.get_task(task_gid).data - task_name = task.name - task_notes = task.notes -except ApiException as e: - . - . - . -``` - -If you would like to convert the class object into a dictionary and access the data via bracket notation, you can use the `to_dict()` method. - -### Example: Accessing task data (bracket notation) -```python -. -. -. -try: - task_dict = tasks_api_instance.get_task(task_gid).to_dict() - task_dict_data = task_dict['data'] - task_name = task_dict_data['name'] - task_notes = task_dict_data['notes'] -except ApiException as e: - . - . - . -``` - -## Accessing response status code and headers - -In the scenario you want to access the response headers or the status code along with the response data you can -provide the `_return_http_data_only` parameter argument in the request method and set the value to `False` - -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -# create an instance of the API class -api_instance = {{{packageName}}}.UsersApi(api_client) -user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - -try: - # Get a user - Add asana-enable in the request - api_response = api_instance.get_user(user_gid, _return_http_data_only=False) # returns a tuple: (object, status, headers) - pprint(api_response) -except ApiException as e: - print("Exception when calling UsersApi->get_user: %s\n" % e) -``` - -## Adding deprecation flag to your "asana-enable" header - -### On the client -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -# Add asana-enable header for the client -api_client.default_headers['asana-enable'] = 'string_ids' -``` - -OR - -### On the request -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -# create an instance of the API class -api_instance = {{{packageName}}}.UsersApi(api_client) -user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - -try: - # Get a user - Add asana-enable in the request - api_response = api_instance.get_user(user_gid, header_params={'asana-enable': 'string_ids'}) - pprint(api_response) -except ApiException as e: - print("Exception when calling UsersApi->get_user: %s\n" % e) -``` - -## Documentation for Using the `call_api` method - -Use this to make HTTP calls when the endpoint does not exist in the current library version or has bugs - -### Example: GET, POST, PUT, DELETE on tasks - -#### GET - get a task -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -try: - # GET - get a task - api_response = api_client.call_api( - "/tasks/{task_gid}", - "GET", - path_params={"task_gid": ""}, - query_params=[], - header_params={"Accept": "application/json; charset=utf-8"}, - body=None, - post_params=[], - files={}, - response_type=object, # If there is an existing response model for the resource you can use that EX: "TaskResponseData" or you can specify one of the following types: float, bool, bytes, str, object - auth_settings=["oauth2"], - async_req=None, - _return_http_data_only=True, - _preload_content=True, - _request_timeout=None, - collection_formats={}, - ) - pprint(api_response) -except ApiException as e: - print("Exception: %s\n" % e) -``` - -#### GET - get multiple tasks -> with opt_fields -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -try: - # GET - get multiple tasks - api_response = api_client.call_api( - "/tasks", - "GET", - path_params={}, - query_params=[('opt_fields', 'name,notes,projects')], - header_params={"Accept": "application/json; charset=utf-8"}, - body=None, - post_params=[], - files={}, - response_type=object, # If there is an existing response model for the resource you can use that EX: "TaskResponseData" or you can specify one of the following types: float, bool, bytes, str, object - auth_settings=["oauth2"], - async_req=None, - _return_http_data_only=True, - _preload_content=True, - _request_timeout=None, - collection_formats={}, - ) - pprint(api_response) -except ApiException as e: - print("Exception: %s\n" % e) -``` - -#### POST - create a task -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -try: - # POST - create a task - api_response = api_client.call_api( - "/tasks", - "POST", - path_params={}, - query_params=[], - header_params={ - "Accept": "application/json; charset=utf-8", - "Content-Type": "application/json; charset=utf-8", - }, - body={ - "data": { - "name": "New Task", - "projects": [""], - } - }, - post_params=[], - files={}, - response_type=object, # If there is an existing response model for the resource you can use that EX: "TaskResponseData" or you can specify one of the following types: float, bool, bytes, str, object - auth_settings=["oauth2"], - async_req=None, - _return_http_data_only=True, - _preload_content=True, - _request_timeout=None, - collection_formats={}, - ) - pprint(api_response) -except ApiException as e: - print("Exception: %s\n" % e) -``` - -#### PUT - update a task -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -try: - # PUT - update a task - api_response = api_client.call_api( - "/tasks/{task_gid}", - "PUT", - path_params={"task_gid": ""}, - query_params=[], - header_params={ - "Accept": "application/json; charset=utf-8", - "Content-Type": "application/json; charset=utf-8", - }, - body={ - "data": { - "name": "Updated Task", - } - }, - post_params=[], - files={}, - response_type=object, # If there is an existing response model for the resource you can use that EX: "TaskResponseData" or you can specify one of the following types: float, bool, bytes, str, object - auth_settings=["oauth2"], - async_req=None, - _return_http_data_only=True, - _preload_content=True, - _request_timeout=None, - collection_formats={}, - ) - pprint(api_response) -except ApiException as e: - print("Exception: %s\n" % e) -``` - -#### DELETE - delete a task -```python -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = '' -api_client = {{{packageName}}}.ApiClient(configuration) - -try: - # DELETE - delete a task - api_response = api_client.call_api( - "/tasks/{task_gid}", - "DELETE", - path_params={"task_gid": ""}, - query_params=[], - header_params={"Accept": "application/json; charset=utf-8"}, - body=None, - post_params=[], - files={}, - response_type=object, # If there is an existing response model for the resource you can use that EX: "EmptyResponseData" or you can specify one of the following types: float, bool, bytes, str, object - auth_settings=["oauth2"], - async_req=None, - _return_http_data_only=True, - _preload_content=True, - _request_timeout=None, - collection_formats={}, - ) - pprint(api_response) -except ApiException as e: - print("Exception: %s\n" % e) -``` - -## Author - -{{#apiInfo}}{{#apis}}{{^hasMore}}{{infoEmail}} -{{/hasMore}}{{/apis}}{{/apiInfo}} - -[release-image]: https://img.shields.io/github/release/asana/python-asana.svg - -[github-actions-image]: https://github.com/Asana/python-asana/workflows/Build/badge.svg -[github-actions-url]: https://github.com/Asana/python-asana/actions - -[pypi-image]: https://img.shields.io/pypi/v/asana.svg?style=flat-square -[pypi-url]: https://pypi.python.org/pypi/asana/ diff --git a/codegen/templates/api.mustache b/codegen/templates/api.mustache deleted file mode 100644 index 1330918a..00000000 --- a/codegen/templates/api.mustache +++ /dev/null @@ -1,236 +0,0 @@ -# coding: utf-8 - -{{>partial_header}} - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from {{packageName}}.api_client import ApiClient - - -{{#operations}} -class {{classname}}(object): - """NOTE: This class is auto generated by the swagger code generator program. - - Do not edit the class manually. - Ref: https://github.com/swagger-api/swagger-codegen - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client -{{#operation}} -{{#contents}} - - def {{operationId}}(self, {{#sortParamsByRequiredFlag}}{{#parameters}}{{#required}}{{paramName}}, {{/required}}{{/parameters}}{{/sortParamsByRequiredFlag}}**kwargs): # noqa: E501 - """{{#summary}}{{{.}}}{{/summary}}{{^summary}}{{operationId}}{{/summary}} # noqa: E501 - -{{#notes}} - {{{notes}}} # noqa: E501 -{{/notes}} - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True -{{#sortParamsByRequiredFlag}} - >>> thread = api.{{operationId}}({{#parameters}}{{#required}}{{paramName}}, {{/required}}{{/parameters}}async_req=True) -{{/sortParamsByRequiredFlag}} -{{^sortParamsByRequiredFlag}} - >>> thread = api.{{operationId}}({{#parameters}}{{#required}}{{paramName}}={{paramName}}_value, {{/required}}{{/parameters}}async_req=True) -{{/sortParamsByRequiredFlag}} - >>> result = thread.get() - - :param async_req bool -{{#parameters}} - :param {{dataType}} {{paramName}}:{{#description}} {{{description}}}{{/description}}{{#required}} (required){{/required}}{{#optional}}(optional){{/optional}} -{{/parameters}} - :return: {{#returnType}}{{returnType}}{{/returnType}}{{^returnType}}None{{/returnType}} - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = kwargs.get("_return_http_data_only", True) - if kwargs.get('async_req'): - return self.{{operationId}}_with_http_info({{#sortParamsByRequiredFlag}}{{#parameters}}{{#required}}{{paramName}}, {{/required}}{{/parameters}}{{/sortParamsByRequiredFlag}}**kwargs) # noqa: E501 - else: - (data) = self.{{operationId}}_with_http_info({{#sortParamsByRequiredFlag}}{{#parameters}}{{#required}}{{paramName}}, {{/required}}{{/parameters}}{{/sortParamsByRequiredFlag}}**kwargs) # noqa: E501 - return data - - def {{operationId}}_with_http_info(self, {{#sortParamsByRequiredFlag}}{{#parameters}}{{#required}}{{paramName}}, {{/required}}{{/parameters}}{{/sortParamsByRequiredFlag}}**kwargs): # noqa: E501 - """{{#summary}}{{{.}}}{{/summary}}{{^summary}}{{operationId}}{{/summary}} # noqa: E501 - -{{#notes}} - {{{notes}}} # noqa: E501 -{{/notes}} - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True -{{#sortParamsByRequiredFlag}} - >>> thread = api.{{operationId}}_with_http_info({{#parameters}}{{#required}}{{paramName}}, {{/required}}{{/parameters}}async_req=True) -{{/sortParamsByRequiredFlag}} -{{^sortParamsByRequiredFlag}} - >>> thread = api.{{operationId}}_with_http_info({{#parameters}}{{#required}}{{paramName}}={{paramName}}_value, {{/required}}{{/parameters}}async_req=True) -{{/sortParamsByRequiredFlag}} - >>> result = thread.get() - - :param async_req bool -{{#parameters}} - :param {{dataType}} {{paramName}}:{{#description}} {{{description}}}{{/description}}{{#required}} (required){{/required}}{{#optional}}(optional{{#defaultValue}}, default to {{{.}}}{{/defaultValue}}){{/optional}} -{{/parameters}} - :return: {{#returnType}}{{returnType}}{{/returnType}}{{^returnType}}None{{/returnType}} - If the method is called asynchronously, - returns the request thread. - """ - - all_params = [{{#parameters}}'{{paramName}}'{{#hasMore}}, {{/hasMore}}{{/parameters}}] # noqa: E501 - all_params.append('async_req') - all_params.append('header_params') - all_params.append('_return_http_data_only') - all_params.append('_preload_content') - all_params.append('_request_timeout') - - params = locals() - {{#vendorExtensions.x-codegen-isSearchTasksForWorkspace}} - matchSnakeCase = '^custom_fields_(.*?)_.*$' - custom_fields_query_param_keys = [] - {{/vendorExtensions.x-codegen-isSearchTasksForWorkspace}} - for key, val in six.iteritems(params['kwargs']): - {{#vendorExtensions.x-codegen-isSearchTasksForWorkspace}} - # Do not throw an error if the user provides custom field query parameters - if (re.match(matchSnakeCase, key)): - custom_field_gid = re.search(matchSnakeCase, key).group(1) - custom_field_query_param_key = key.replace(f'custom_fields_{custom_field_gid}_', f'custom_fields.{custom_field_gid}.') - params[custom_field_query_param_key] = val - custom_fields_query_param_keys.append(custom_field_query_param_key) - continue - {{/vendorExtensions.x-codegen-isSearchTasksForWorkspace}} - if key not in all_params: - raise TypeError( - "Got an unexpected keyword argument '%s'" - " to method {{operationId}}" % key - ) - params[key] = val - del params['kwargs'] -{{#parameters}} -{{#required}} - # verify the required parameter '{{paramName}}' is set - if ('{{paramName}}' not in params or - params['{{paramName}}'] is None): - raise ValueError("Missing the required parameter `{{paramName}}` when calling `{{operationId}}`") # noqa: E501 -{{/required}} -{{/parameters}} - -{{#parameters}} -{{#hasValidation}} - {{#maxLength}} - if ('{{paramName}}' in params and - len(params['{{paramName}}']) > {{maxLength}}): - raise ValueError("Invalid value for parameter `{{paramName}}` when calling `{{operationId}}`, length must be less than or equal to `{{maxLength}}`") # noqa: E501 - {{/maxLength}} - {{#minLength}} - if ('{{paramName}}' in params and - len(params['{{paramName}}']) < {{minLength}}): - raise ValueError("Invalid value for parameter `{{paramName}}` when calling `{{operationId}}`, length must be greater than or equal to `{{minLength}}`") # noqa: E501 - {{/minLength}} - {{#maximum}} - if '{{paramName}}' in params and params['{{paramName}}'] >{{#exclusiveMaximum}}={{/exclusiveMaximum}} {{maximum}}: # noqa: E501 - raise ValueError("Invalid value for parameter `{{paramName}}` when calling `{{operationId}}`, must be a value less than {{^exclusiveMaximum}}or equal to {{/exclusiveMaximum}}`{{maximum}}`") # noqa: E501 - {{/maximum}} - {{#minimum}} - if '{{paramName}}' in params and params['{{paramName}}'] <{{#exclusiveMinimum}}={{/exclusiveMinimum}} {{minimum}}: # noqa: E501 - raise ValueError("Invalid value for parameter `{{paramName}}` when calling `{{operationId}}`, must be a value greater than {{^exclusiveMinimum}}or equal to {{/exclusiveMinimum}}`{{minimum}}`") # noqa: E501 - {{/minimum}} - {{#pattern}} - if '{{paramName}}' in params and not re.search(r'{{{vendorExtensions.x-regex}}}', params['{{paramName}}']{{#vendorExtensions.x-modifiers}}{{#@first}}, flags={{/@first}}re.{{.}}{{^@last}} | {{/@last}}{{/vendorExtensions.x-modifiers}}): # noqa: E501 - raise ValueError("Invalid value for parameter `{{paramName}}` when calling `{{operationId}}`, must conform to the pattern `{{{pattern}}}`") # noqa: E501 - {{/pattern}} - {{#maxItems}} - if ('{{paramName}}' in params and - len(params['{{paramName}}']) > {{maxItems}}): - raise ValueError("Invalid value for parameter `{{paramName}}` when calling `{{operationId}}`, number of items must be less than or equal to `{{maxItems}}`") # noqa: E501 - {{/maxItems}} - {{#minItems}} - if ('{{paramName}}' in params and - len(params['{{paramName}}']) < {{minItems}}): - raise ValueError("Invalid value for parameter `{{paramName}}` when calling `{{operationId}}`, number of items must be greater than or equal to `{{minItems}}`") # noqa: E501 - {{/minItems}} -{{/hasValidation}} -{{#@last}} -{{/@last}} -{{/parameters}} - collection_formats = {} - - path_params = {} -{{#pathParams}} - if '{{paramName}}' in params: - path_params['{{baseName}}'] = params['{{paramName}}']{{#isListContainer}} # noqa: E501 - collection_formats['{{baseName}}'] = '{{collectionFormat}}'{{/isListContainer}} # noqa: E501 -{{/pathParams}} - - query_params = [] -{{#queryParams}} - if '{{paramName}}' in params: - query_params.append(('{{baseName}}', params['{{paramName}}'])){{#isListContainer}} # noqa: E501 - collection_formats['{{baseName}}'] = '{{collectionFormat}}'{{/isListContainer}} # noqa: E501 -{{/queryParams}} - -{{#vendorExtensions.x-codegen-isSearchTasksForWorkspace}} - # Checks if the user provided custom field query parameters and adds it to the request - for key in custom_fields_query_param_keys: - query_params.append((key, params[key])) # noqa: E501 -{{/vendorExtensions.x-codegen-isSearchTasksForWorkspace}} - - header_params = kwargs.get("header_params", {}) -{{#headerParams}} - if '{{paramName}}' in params: - header_params['{{baseName}}'] = params['{{paramName}}']{{#isListContainer}} # noqa: E501 - collection_formats['{{baseName}}'] = '{{collectionFormat}}'{{/isListContainer}} # noqa: E501 -{{/headerParams}} - - form_params = [] - local_var_files = {} -{{#formParams}} - if '{{paramName}}' in params: - {{^isBinary}}form_params.append(('{{baseName}}', params['{{paramName}}'])){{/isBinary}}{{#isBinary}}local_var_files['{{baseName}}'] = params['{{paramName}}']{{/isBinary}}{{#isListContainer}} # noqa: E501 - collection_formats['{{baseName}}'] = '{{collectionFormat}}'{{/isListContainer}} # noqa: E501 -{{/formParams}} - - body_params = None -{{#bodyParam}} - if '{{paramName}}' in params: - body_params = params['{{paramName}}'] -{{/bodyParam}} - {{#hasProduces}} - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - [{{#produces}}'{{{mediaType}}}'{{#hasMore}}, {{/hasMore}}{{/produces}}]) # noqa: E501 - - {{/hasProduces}} - {{#hasConsumes}} - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - [{{#consumes}}'{{{mediaType}}}'{{#hasMore}}, {{/hasMore}}{{/consumes}}]) # noqa: E501 - - {{/hasConsumes}} - # Authentication setting - auth_settings = [{{#authMethods}}'{{name}}'{{#hasMore}}, {{/hasMore}}{{/authMethods}}] # noqa: E501 - - return self.api_client.call_api( - '{{{path}}}', '{{httpMethod}}', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type={{#returnType}}'{{returnType}}'{{/returnType}}{{^returnType}}None{{/returnType}}, # noqa: E501 - auth_settings=auth_settings, - async_req=params.get('async_req'), - _return_http_data_only=params.get('_return_http_data_only'), - _preload_content=params.get('_preload_content', True), - _request_timeout=params.get('_request_timeout'), - collection_formats=collection_formats) -{{/contents}} -{{/operation}} -{{/operations}} diff --git a/codegen/templates/api_client.mustache b/codegen/templates/api_client.mustache deleted file mode 100644 index a633f46c..00000000 --- a/codegen/templates/api_client.mustache +++ /dev/null @@ -1,657 +0,0 @@ -# coding: utf-8 -{{>partial_header}} -from __future__ import absolute_import - -import logging -import datetime -import json -import mimetypes -from multiprocessing.pool import ThreadPool -import os -import platform -import re -import tempfile - -# python 2 and python 3 compatibility library -import six -from six.moves.urllib.parse import quote -{{#tornado}} -import tornado.gen -{{/tornado}} - -from {{packageName}}.configuration import Configuration -import {{modelPackage}} -from {{packageName}} import rest - -from urllib.parse import urlencode - - -class ApiClient(object): - """Generic API client for Swagger client library builds. - - Swagger generic API client. This client handles the client- - server communication, and is invariant across implementations. Specifics of - the methods and models for each application are generated from the Swagger - templates. - - NOTE: This class is auto generated by the swagger code generator program. - Ref: https://github.com/swagger-api/swagger-codegen - Do not edit the class manually. - - :param configuration: .Configuration object for this client - :param header_name: a header to pass when making calls to the API. - :param header_value: a header value to pass when making calls to - the API. - :param cookie: a cookie to include in the header when making calls - to the API - """ - - PRIMITIVE_TYPES = (float, bool, bytes, six.text_type) + six.integer_types - NATIVE_TYPES_MAPPING = { - 'int': int, - 'long': int if six.PY3 else long, # noqa: F821 - 'float': float, - 'str': str, - 'bool': bool, - 'date': datetime.date, - 'datetime': datetime.datetime, - 'object': object, - } - - def __init__(self, configuration=None, header_name=None, header_value=None, - cookie=None): - if configuration is None: - configuration = Configuration() - self.configuration = configuration - - try: - self.pool = ThreadPool() - except OSError: - logging.warning('Looks like your system does not support ThreadPool but it will try without it if you do not use async requests') - self.rest_client = rest.RESTClientObject(configuration) - self.default_headers = {} - if header_name is not None: - self.default_headers[header_name] = header_value - self.cookie = cookie - # Set default User-Agent. - self.user_agent = '{{#httpUserAgent}}{{{.}}}{{/httpUserAgent}}{{^httpUserAgent}}Swagger-Codegen/{{{packageVersion}}}/python{{/httpUserAgent}}' - # Add custom header - self.default_headers['X-Asana-Client-Lib'] = urlencode( - { - 'language': 'Python', - 'version': '{{{packageVersion}}}', - 'language_version': platform.python_version(), - 'os': platform.system(), - 'os_version': platform.release() - } - ) - - def __del__(self): - if hasattr(self, "pool"): - self.pool.close() - self.pool.join() - - @property - def user_agent(self): - """User agent for this API client""" - return self.default_headers['User-Agent'] - - @user_agent.setter - def user_agent(self, value): - self.default_headers['User-Agent'] = value - - def set_default_header(self, header_name, header_value): - self.default_headers[header_name] = header_value - - {{#tornado}} - @tornado.gen.coroutine - {{/tornado}} - {{#asyncio}}async {{/asyncio}}def __call_api( - self, resource_path, method, path_params=None, - query_params=None, header_params=None, body=None, post_params=None, - files=None, response_type=None, auth_settings=None, - _return_http_data_only=None, collection_formats=None, - _preload_content=True, _request_timeout=None): - - config = self.configuration - - # header parameters - header_params = header_params or {} - header_params.update(self.default_headers) - if self.cookie: - header_params['Cookie'] = self.cookie - if header_params: - header_params = self.sanitize_for_serialization(header_params) - header_params = dict(self.parameters_to_tuples(header_params, - collection_formats)) - - # path parameters - if path_params: - path_params = self.sanitize_for_serialization(path_params) - path_params = self.parameters_to_tuples(path_params, - collection_formats) - for k, v in path_params: - # specified safe chars, encode everything - resource_path = resource_path.replace( - '{%s}' % k, - quote(str(v), safe=config.safe_chars_for_path_param) - ) - - # query parameters - if query_params: - query_params = self.sanitize_for_serialization(query_params) - query_params = self.parameters_to_tuples(query_params, - collection_formats) - - # post parameters - if post_params or files: - post_params = self.prepare_post_parameters(post_params, files) - post_params = self.sanitize_for_serialization(post_params) - post_params = self.parameters_to_tuples(post_params, - collection_formats) - - # auth setting - self.update_params_for_auth(header_params, query_params, auth_settings) - - # body - if body: - body = self.sanitize_for_serialization(body) - - # request url - url = self.configuration.host + resource_path - - # perform request and return response - response_data = {{#asyncio}}await {{/asyncio}}{{#tornado}}yield {{/tornado}}self.request( - method, url, query_params=query_params, headers=header_params, - post_params=post_params, body=body, - _preload_content=_preload_content, - _request_timeout=_request_timeout) - - self.last_response = response_data - - return_data = response_data - if _preload_content: - # deserialize response data - if response_type: - return_data = self.deserialize(response_data, response_type) - else: - return_data = None - -{{^tornado}} - if _return_http_data_only: - return (return_data) - else: - return (return_data, response_data.status, - response_data.getheaders()) -{{/tornado}} -{{#tornado}} - if _return_http_data_only: - raise tornado.gen.Return(return_data) - else: - raise tornado.gen.Return((return_data, response_data.status, - response_data.getheaders())) -{{/tornado}} - - def sanitize_for_serialization(self, obj): - """Builds a JSON POST object. - - If obj is None, return None. - If obj is str, int, long, float, bool, return directly. - If obj is datetime.datetime, datetime.date - convert to string in iso8601 format. - If obj is list, sanitize each element in the list. - If obj is dict, return the dict. - If obj is swagger model, return the properties dict. - - :param obj: The data to serialize. - :return: The serialized form of data. - """ - if obj is None: - return None - elif isinstance(obj, self.PRIMITIVE_TYPES): - return obj - elif isinstance(obj, list): - return [self.sanitize_for_serialization(sub_obj) - for sub_obj in obj] - elif isinstance(obj, tuple): - return tuple(self.sanitize_for_serialization(sub_obj) - for sub_obj in obj) - elif isinstance(obj, (datetime.datetime, datetime.date)): - return obj.isoformat() - - if isinstance(obj, dict): - obj_dict = obj - else: - # Convert model obj to dict except - # attributes `swagger_types`, `attribute_map` - # and attributes which value is not None. - # Convert attribute name to json key in - # model definition for request. - obj_dict = {obj.attribute_map[attr]: getattr(obj, attr) - for attr, _ in six.iteritems(obj.swagger_types) - if getattr(obj, attr) is not None} - - return {key: self.sanitize_for_serialization(val) - for key, val in six.iteritems(obj_dict)} - - def deserialize(self, response, response_type): - """Deserializes response into an object. - - :param response: RESTResponse object to be deserialized. - :param response_type: class literal for - deserialized object, or string of class name. - - :return: deserialized object. - """ - # handle file downloading - # save response body into a tmp file and return the instance - if response_type == "file": - return self.__deserialize_file(response) - - # fetch data from response object - try: - data = json.loads(response.data) - except ValueError: - data = response.data - - return self.__deserialize(data, response_type) - - def __deserialize(self, data, klass): - """Deserializes dict, list, str into an object. - - :param data: dict, list or str. - :param klass: class literal, or string of class name. - - :return: object. - """ - if data is None: - return None - - if type(klass) == str: - if klass.startswith('list['): - sub_kls = re.match(r'list\[(.*)\]', klass).group(1) - return [self.__deserialize(sub_data, sub_kls) - for sub_data in data] - - if klass.startswith('dict('): - sub_kls = re.match(r'dict\(([^,]*), (.*)\)', klass).group(2) - return {k: self.__deserialize(v, sub_kls) - for k, v in six.iteritems(data)} - - # convert str to class - if klass in self.NATIVE_TYPES_MAPPING: - klass = self.NATIVE_TYPES_MAPPING[klass] - else: - klass = getattr({{modelPackage}}, klass) - - if klass in self.PRIMITIVE_TYPES: - return self.__deserialize_primitive(data, klass) - elif klass == object: - return self.__deserialize_object(data) - elif klass == datetime.date: - return self.__deserialize_date(data) - elif klass == datetime.datetime: - return self.__deserialize_datatime(data) - else: - return self.__deserialize_model(data, klass) - - def call_api(self, resource_path, method, - path_params=None, query_params=None, header_params=None, - body=None, post_params=None, files=None, - response_type=None, auth_settings=None, async_req=None, - _return_http_data_only=None, collection_formats=None, - _preload_content=True, _request_timeout=None): - """Makes the HTTP request (synchronous) and returns deserialized data. - - To make an async request, set the async_req parameter. - - :param resource_path: Path to method endpoint. - :param method: Method to call. - :param path_params: Path parameters in the url. - :param query_params: Query parameters in the url. - :param header_params: Header parameters to be - placed in the request header. - :param body: Request body. - :param post_params dict: Request post form parameters, - for `application/x-www-form-urlencoded`, `multipart/form-data`. - :param auth_settings list: Auth Settings names for the request. - :param response: Response data type. - :param files dict: key -> filename, value -> filepath, - for `multipart/form-data`. - :param async_req bool: execute request asynchronously - :param _return_http_data_only: response data without head status code - and headers - :param collection_formats: dict of collection formats for path, query, - header, and post parameters. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: - If async_req parameter is True, - the request will be called asynchronously. - The method will return the request thread. - If parameter async_req is False or missing, - then the method will return the response directly. - """ - if not async_req: - return self.__call_api(resource_path, method, - path_params, query_params, header_params, - body, post_params, files, - response_type, auth_settings, - _return_http_data_only, collection_formats, - _preload_content, _request_timeout) - else: - thread = self.pool.apply_async(self.__call_api, (resource_path, - method, path_params, query_params, - header_params, body, - post_params, files, - response_type, auth_settings, - _return_http_data_only, - collection_formats, - _preload_content, _request_timeout)) - return thread - - def request(self, method, url, query_params=None, headers=None, - post_params=None, body=None, _preload_content=True, - _request_timeout=None): - """Makes the HTTP request using RESTClient.""" - if method == "GET": - return self.rest_client.GET(url, - query_params=query_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - headers=headers) - elif method == "HEAD": - return self.rest_client.HEAD(url, - query_params=query_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - headers=headers) - elif method == "OPTIONS": - return self.rest_client.OPTIONS(url, - query_params=query_params, - headers=headers, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - elif method == "POST": - return self.rest_client.POST(url, - query_params=query_params, - headers=headers, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - elif method == "PUT": - return self.rest_client.PUT(url, - query_params=query_params, - headers=headers, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - elif method == "PATCH": - return self.rest_client.PATCH(url, - query_params=query_params, - headers=headers, - post_params=post_params, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - elif method == "DELETE": - return self.rest_client.DELETE(url, - query_params=query_params, - headers=headers, - _preload_content=_preload_content, - _request_timeout=_request_timeout, - body=body) - else: - raise ValueError( - "http method must be `GET`, `HEAD`, `OPTIONS`," - " `POST`, `PATCH`, `PUT` or `DELETE`." - ) - - def parameters_to_tuples(self, params, collection_formats): - """Get parameters as list of tuples, formatting collections. - - :param params: Parameters as dict or list of two-tuples - :param dict collection_formats: Parameter collection formats - :return: Parameters as list of tuples, collections formatted - """ - new_params = [] - if collection_formats is None: - collection_formats = {} - for k, v in six.iteritems(params) if isinstance(params, dict) else params: # noqa: E501 - if k in collection_formats: - collection_format = collection_formats[k] - if collection_format == 'multi': - new_params.extend((k, value) for value in v) - else: - if collection_format == 'ssv': - delimiter = ' ' - elif collection_format == 'tsv': - delimiter = '\t' - elif collection_format == 'pipes': - delimiter = '|' - else: # csv is the default - delimiter = ',' - new_params.append( - (k, delimiter.join(str(value) for value in v))) - else: - new_params.append((k, v)) - return new_params - - def prepare_post_parameters(self, post_params=None, files=None): - """Builds form parameters. - - :param post_params: Normal form parameters. - :param files: File parameters. - :return: Form parameters with files. - """ - params = [] - - if post_params: - params = post_params - - if files: - for k, v in six.iteritems(files): - if not v: - continue - file_names = v if type(v) is list else [v] - for n in file_names: - with open(n, 'rb') as f: - filename = os.path.basename(f.name) - filedata = f.read() - mimetype = (mimetypes.guess_type(filename)[0] or - 'application/octet-stream') - params.append( - tuple([k, tuple([filename, filedata, mimetype])])) - - return params - - def select_header_accept(self, accepts): - """Returns `Accept` based on an array of accepts provided. - - :param accepts: List of headers. - :return: Accept (e.g. application/json). - """ - if not accepts: - return - - accepts = [x.lower() for x in accepts] - - if 'application/json' in accepts: - return 'application/json' - else: - return ', '.join(accepts) - - def select_header_content_type(self, content_types): - """Returns `Content-Type` based on an array of content_types provided. - - :param content_types: List of content-types. - :return: Content-Type (e.g. application/json). - """ - if not content_types: - return 'application/json' - - content_types = [x.lower() for x in content_types] - - if 'application/json' in content_types or '*/*' in content_types: - return 'application/json' - else: - return content_types[0] - - def update_params_for_auth(self, headers, querys, auth_settings): - """Updates header and query params based on authentication setting. - - :param headers: Header parameters dict to be updated. - :param querys: Query parameters tuple list to be updated. - :param auth_settings: Authentication setting identifiers list. - """ - if not auth_settings: - return - - for auth in auth_settings: - auth_setting = self.configuration.auth_settings().get(auth) - if auth_setting: - if not auth_setting['value']: - continue - elif auth_setting['in'] == 'header': - headers[auth_setting['key']] = auth_setting['value'] - elif auth_setting['in'] == 'query': - querys.append((auth_setting['key'], auth_setting['value'])) - else: - raise ValueError( - 'Authentication token must be in `query` or `header`' - ) - - def __deserialize_file(self, response): - """Deserializes body to file - - Saves response body into a file in a temporary folder, - using the filename from the `Content-Disposition` header if provided. - - :param response: RESTResponse. - :return: file path. - """ - fd, path = tempfile.mkstemp(dir=self.configuration.temp_folder_path) - os.close(fd) - os.remove(path) - - content_disposition = response.getheader("Content-Disposition") - if content_disposition: - filename = re.search(r'filename=[\'"]?([^\'"\s]+)[\'"]?', - content_disposition).group(1) - path = os.path.join(os.path.dirname(path), filename) - response_data = response.data - with open(path, "wb") as f: - if isinstance(response_data, str): - # change str to bytes so we can write it - response_data = response_data.encode('utf-8') - f.write(response_data) - else: - f.write(response_data) - return path - - def __deserialize_primitive(self, data, klass): - """Deserializes string to primitive type. - - :param data: str. - :param klass: class literal. - - :return: int, long, float, str, bool. - """ - try: - return klass(data) - except UnicodeEncodeError: - return six.text_type(data) - except TypeError: - return data - - def __deserialize_object(self, value): - """Return a original value. - - :return: object. - """ - return value - - def __deserialize_date(self, string): - """Deserializes string to date. - - :param string: str. - :return: date. - """ - try: - from dateutil.parser import parse - return parse(string).date() - except ImportError: - return string - except ValueError: - raise rest.ApiException( - status=0, - reason="Failed to parse `{0}` as date object".format(string) - ) - - def __deserialize_datatime(self, string): - """Deserializes string to datetime. - - The string should be in iso8601 datetime format. - - :param string: str. - :return: datetime. - """ - try: - from dateutil.parser import parse - return parse(string) - except ImportError: - return string - except ValueError: - raise rest.ApiException( - status=0, - reason=( - "Failed to parse `{0}` as datetime object" - .format(string) - ) - ) - - def __hasattr(self, object, name): - return name in object.__class__.__dict__ - - def __deserialize_model(self, data, klass): - """Deserializes list or dict to model. - - :param data: dict, list. - :param klass: class literal. - :return: model object. - """ - - if not klass.swagger_types and not self.__hasattr(klass, 'get_real_child_model'): - return data - - kwargs = {} - if klass.swagger_types is not None: - for attr, attr_type in six.iteritems(klass.swagger_types): - if (data is not None and - klass.attribute_map[attr] in data and - isinstance(data, (list, dict))): - value = data[klass.attribute_map[attr]] - kwargs[attr] = self.__deserialize(value, attr_type) - - instance = klass(**kwargs) - - if (isinstance(instance, dict) and - klass.swagger_types is not None and - isinstance(data, dict)): - for key, value in data.items(): - if key not in klass.swagger_types: - instance[key] = value - if self.__hasattr(instance, 'get_real_child_model'): - klass_name = instance.get_real_child_model(data) - if klass_name: - instance = self.__deserialize(data, klass_name) - return instance diff --git a/codegen/templates/api_doc.mustache b/codegen/templates/api_doc.mustache deleted file mode 100644 index dd55bcc9..00000000 --- a/codegen/templates/api_doc.mustache +++ /dev/null @@ -1,52 +0,0 @@ -# {{packageName}}.{{classname}}{{#description}} -{{description}}{{/description}} - -All URIs are relative to *{{basePath}}* - -Method | HTTP request | Description -------------- | ------------- | ------------- -{{#operations}}{{#operation}}[**{{operationId}}**]({{classname}}.md#{{operationId}}) | **{{httpMethod}}** {{path}} | {{#summary}}{{summary}}{{/summary}} -{{/operation}}{{/operations}} - -{{#operations}} -{{#operation}} -{{#contents}} -{{#@first}} -# **{{{operationId}}}** -> {{#returnType}}{{{returnType}}} {{/returnType}}{{{operationId}}}({{#parameters}}{{#required}}{{{paramName}}}{{/required}}{{^required}}{{{paramName}}}={{{paramName}}}{{/required}}{{#hasMore}}, {{/hasMore}}{{/parameters}}) - -{{{summary}}}{{#notes}} - -{{{notes}}}{{/notes}} - -### Example -```python -{{>code_sample}} -``` - -### Parameters -{{^parameters}}This endpoint does not need any parameter.{{/parameters}}{{#parameters}}{{#@last}} -Name | Type | Description | Notes -------------- | ------------- | ------------- | -------------{{/@last}}{{/parameters}} -{{#parameters}} **{{paramName}}** | {{#isBinary}}**{{dataType}}**{{/isBinary}}{{^isBinary}}{{#isPrimitiveType}}**{{dataType}}**{{/isPrimitiveType}}{{^isPrimitiveType}}[**{{dataType}}**]({{baseType}}.md){{/isPrimitiveType}}{{/isBinary}}| {{description}} | {{^required}}[optional] {{/required}}{{#defaultValue}}[default to {{defaultValue}}]{{/defaultValue}} -{{/parameters}} - -### Return type - -{{#returnType}}{{#returnTypeIsPrimitive}}**{{{returnType}}}**{{/returnTypeIsPrimitive}}{{^returnTypeIsPrimitive}}[**{{{returnType}}}**]({{returnBaseType}}.md){{/returnTypeIsPrimitive}}{{/returnType}}{{^returnType}}void (empty response body){{/returnType}} - -### Authorization - -{{^authMethods}}No authorization required{{/authMethods}}{{#authMethods}}[{{{name}}}](../README.md#{{{name}}}){{^@last}}, {{/@last}}{{/authMethods}} - -### HTTP request headers - - - **Content-Type**: {{#consumes}}{{{mediaType}}}{{#hasMore}}, {{/hasMore}}{{/consumes}}{{^consumes}}Not defined{{/consumes}} - - **Accept**: {{#produces}}{{{mediaType}}}{{#hasMore}}, {{/hasMore}}{{/produces}}{{^produces}}Not defined{{/produces}} - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -{{/@first}} -{{/contents}} -{{/operation}} -{{/operations}} diff --git a/codegen/templates/code_sample.mustache b/codegen/templates/code_sample.mustache deleted file mode 100644 index f82b5e3d..00000000 --- a/codegen/templates/code_sample.mustache +++ /dev/null @@ -1,48 +0,0 @@ -import {{{packageName}}} -from {{{packageName}}}.rest import ApiException -from pprint import pprint -{{#hasAuthMethods}}{{#authMethods}}{{#isBasic}} -# Configure HTTP basic authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.username = 'YOUR_USERNAME' -configuration.password = 'YOUR_PASSWORD'{{/isBasic}}{{#isApiKey}} -# Configure API key authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.api_key['{{{keyParamName}}}'] = 'YOUR_API_KEY' -# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed -# configuration.api_key_prefix['{{{keyParamName}}}'] = 'Bearer'{{/isApiKey}}{{#isOAuth}} -# Configure OAuth2 access token for authorization: {{{name}}} -configuration = {{{packageName}}}.Configuration() -configuration.access_token = ''{{/isOAuth}}{{/authMethods}} -api_client = {{{packageName}}}.ApiClient(configuration) - -# create an instance of the API class -api_instance = {{{packageName}}}.{{{classname}}}(api_client) -{{#parameters}} -{{paramName}} = {{{example}}} # {{{dataType}}} | {{{description}}}{{^required}} (optional){{/required}}{{#defaultValue}} (default to {{{.}}}){{/defaultValue}} -{{/parameters}} -{{/hasAuthMethods}} -{{^hasAuthMethods}} - -# create an instance of the API class -api_instance = {{{packageName}}}.{{{classname}}}() -{{#parameters}} -{{paramName}} = {{{example}}} # {{{dataType}}} | {{{description}}}{{^required}} (optional){{/required}}{{#defaultValue}} (default to {{{.}}}){{/defaultValue}} -{{/parameters}} -{{/hasAuthMethods}} -{{#vendorExtensions.x-codegen-isSearchTasksForWorkspace}} -custom_fields_123_is_set = True # bool | Filiter to tasks with custom field set or unset. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field -custom_fields_123_value = '456' # str or bool or Enum option ID | Filter to tasks with custom field that matches the provided value. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field -custom_fields_123_starts_with = 'start' # string | Filter to tasks with custom field that starts with provided string. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field -custom_fields_123_ends_with = 'end' # string | Filter to tasks with custom field that ends in provided string. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field -custom_fields_123_contains = 'first' # string | Filter to tasks with custom field that contains the provided string. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field -custom_fields_123_less_than = 10 # number | Filter to tasks with custom field with number value less than the provided number. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field -custom_fields_123_greater_than = 100 # number | Filter to tasks with custom field with number value greater than the provided number. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field -{{/vendorExtensions.x-codegen-isSearchTasksForWorkspace}} - -try: -{{#summary}} # {{{.}}} -{{/summary}} {{#returnType}}api_response = {{/returnType}}api_instance.{{{operationId}}}({{#parameters}}{{#required}}{{paramName}}{{/required}}{{^required}}{{paramName}}={{paramName}}{{/required}}{{#hasMore}}, {{/hasMore}}{{/parameters}}{{#vendorExtensions.x-codegen-isSearchTasksForWorkspace}}, custom_fields_123_value=custom_fields_123_value, custom_fields_123_starts_with=custom_fields_123_starts_with, custom_fields_123_ends_with=custom_fields_123_ends_with, custom_fields_123_contains=custom_fields_123_contains, custom_fields_123_less_than=custom_fields_123_less_than, custom_fields_123_greater_than=custom_fields_123_greater_than{{/vendorExtensions.x-codegen-isSearchTasksForWorkspace}}){{#returnType}} - pprint(api_response){{/returnType}} -except ApiException as e: - print("Exception when calling {{classname}}->{{operationId}}: %s\n" % e) diff --git a/codegen/templates/code_samples.mustache b/codegen/templates/code_samples.mustache deleted file mode 100644 index 63275fda..00000000 --- a/codegen/templates/code_samples.mustache +++ /dev/null @@ -1,11 +0,0 @@ -{{classname}}: -{{#operations}} -{{#operation}} -{{#contents}} -{{#@first}} - {{operationId}}: |- - {{>code_sample}} -{{/@first}} -{{/contents}} -{{/operation}} -{{/operations}} diff --git a/codegen/templates/setup.mustache b/codegen/templates/setup.mustache deleted file mode 100644 index 0e52d6e1..00000000 --- a/codegen/templates/setup.mustache +++ /dev/null @@ -1,52 +0,0 @@ -# coding: utf-8 - -{{>partial_header}} - -import os -from setuptools import setup, find_packages # noqa: H301 - -NAME = "{{{projectName}}}" -VERSION = "{{packageVersion}}" -with open(os.path.join(os.path.dirname(__file__), 'README.md')) as readme: - LONG_DESCRIPTION = readme.read() -{{#apiInfo}} -{{#apis}} -{{^hasMore}} -# To install the library, run the following -# -# python setup.py install -# -# prerequisite: setuptools -# http://pypi.python.org/pypi/setuptools - -REQUIRES = [ - "certifi>=2017.4.17", - "python-dateutil>=2.1", - "six>=1.10", - "urllib3>=1.23" -] - -{{#asyncio}} -REQUIRES.append("aiohttp") -{{/asyncio}} -{{#tornado}} -REQUIRES.append("tornado") -{{/tornado}} - -setup( - name=NAME, - version=VERSION, - description="{{appName}}", - long_description=LONG_DESCRIPTION, - long_description_content_type='text/markdown', - author='Asana, Inc', - url="http://github.com/asana/python-asana", - keywords=["asana", "{{appName}}"], - install_requires=REQUIRES, - packages=find_packages(), - include_package_data=True, - license='MIT', -) -{{/hasMore}} -{{/apis}} -{{/apiInfo}} diff --git a/deploy.py b/deploy.py new file mode 100755 index 00000000..a1bd496a --- /dev/null +++ b/deploy.py @@ -0,0 +1,54 @@ +#!/usr/bin/env python + +""" +Script for deploying a new version of the python-asana library. +""" + +from __future__ import print_function + +import argparse +import subprocess + +if __name__ == '__main__': + # Setup parser for command line arguments + parser = argparse.ArgumentParser() + parser.add_argument( + 'part', + choices=['major', 'minor', 'patch'], + help='The part of the version to be bumped' + ) + args = parser.parse_args() + + # Get the current version from asana/version.py + current_version = {} + with open('asana/version.py') as fp: + exec(fp.read(), current_version) + major, minor, patch = current_version['__version__'].split('.') + + # Bump version part based on argument provided + if args.part == 'major': + major = str(int(major) + 1) + minor = 0 + patch = 0 + if args.part == 'minor': + minor = str(int(minor) + 1) + patch = 0 + if args.part == 'patch': + patch = str(int(patch) + 1) + + # Overwrite the version in VERSION and asana/version.py + updated_version = "{}.{}.{}".format(major, minor, patch) + with open('VERSION', 'w') as version_file: + version_file.write("{}".format(updated_version)) + with open('asana/version.py', 'w') as version_file: + version_file.write("__version__ = '{}'\n".format(updated_version)) + + # Add, commit and push version changes to GitHub and tag release + subprocess.call('git add VERSION asana/version.py', shell=True) + subprocess.call( + 'git commit -m "Releasing version {}"'.format(updated_version), shell=True + ) + subprocess.call('git tag v{}'.format(updated_version), shell=True) + subprocess.call('git push --tags origin master:master', shell=True) + + print('Successfully deployed version {}'.format(updated_version)) diff --git a/docs/AddCustomFieldSettingRequest.md b/docs/AddCustomFieldSettingRequest.md deleted file mode 100644 index 2aa536b6..00000000 --- a/docs/AddCustomFieldSettingRequest.md +++ /dev/null @@ -1,12 +0,0 @@ -# AddCustomFieldSettingRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**custom_field** | **str** | The custom field to associate with this container. | -**is_important** | **bool** | Whether this field should be considered important to this container (for instance, to display in the list view of items in the container). | [optional] -**insert_before** | **str** | A gid of a Custom Field Setting on this container, before which the new Custom Field Setting will be added. `insert_before` and `insert_after` parameters cannot both be specified. | [optional] -**insert_after** | **str** | A gid of a Custom Field Setting on this container, after which the new Custom Field Setting will be added. `insert_before` and `insert_after` parameters cannot both be specified. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AddFollowersRequest.md b/docs/AddFollowersRequest.md deleted file mode 100644 index 26429de2..00000000 --- a/docs/AddFollowersRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# AddFollowersRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**followers** | **str** | An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AddMembersRequest.md b/docs/AddMembersRequest.md deleted file mode 100644 index f6ab2bf4..00000000 --- a/docs/AddMembersRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# AddMembersRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**members** | **str** | An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfProjectResponseOwner.md b/docs/AllOfProjectResponseOwner.md deleted file mode 100644 index 0e947401..00000000 --- a/docs/AllOfProjectResponseOwner.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfProjectResponseOwner - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfProjectTemplateBaseOwner.md b/docs/AllOfProjectTemplateBaseOwner.md deleted file mode 100644 index 0dacf1ea..00000000 --- a/docs/AllOfProjectTemplateBaseOwner.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfProjectTemplateBaseOwner - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfProjectTemplateResponseOwner.md b/docs/AllOfProjectTemplateResponseOwner.md deleted file mode 100644 index 7e8979c1..00000000 --- a/docs/AllOfProjectTemplateResponseOwner.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfProjectTemplateResponseOwner - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfStoryResponseNewDateValue.md b/docs/AllOfStoryResponseNewDateValue.md deleted file mode 100644 index 01b8af46..00000000 --- a/docs/AllOfStoryResponseNewDateValue.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfStoryResponseNewDateValue - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfStoryResponseOldDateValue.md b/docs/AllOfStoryResponseOldDateValue.md deleted file mode 100644 index 0c87ccb9..00000000 --- a/docs/AllOfStoryResponseOldDateValue.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfStoryResponseOldDateValue - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfTaskTemplateResponseCreatedBy.md b/docs/AllOfTaskTemplateResponseCreatedBy.md deleted file mode 100644 index 3135f3e3..00000000 --- a/docs/AllOfTaskTemplateResponseCreatedBy.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfTaskTemplateResponseCreatedBy - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfTaskTemplateResponseProject.md b/docs/AllOfTaskTemplateResponseProject.md deleted file mode 100644 index cdb98ad3..00000000 --- a/docs/AllOfTaskTemplateResponseProject.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfTaskTemplateResponseProject - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfTaskTemplateResponseTemplate.md b/docs/AllOfTaskTemplateResponseTemplate.md deleted file mode 100644 index 2749f74d..00000000 --- a/docs/AllOfTaskTemplateResponseTemplate.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfTaskTemplateResponseTemplate - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfUserTaskListBaseOwner.md b/docs/AllOfUserTaskListBaseOwner.md deleted file mode 100644 index bd0da11b..00000000 --- a/docs/AllOfUserTaskListBaseOwner.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfUserTaskListBaseOwner - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfUserTaskListBaseWorkspace.md b/docs/AllOfUserTaskListBaseWorkspace.md deleted file mode 100644 index df5a679d..00000000 --- a/docs/AllOfUserTaskListBaseWorkspace.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfUserTaskListBaseWorkspace - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfUserTaskListCompactOwner.md b/docs/AllOfUserTaskListCompactOwner.md deleted file mode 100644 index b38101b9..00000000 --- a/docs/AllOfUserTaskListCompactOwner.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfUserTaskListCompactOwner - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfUserTaskListCompactWorkspace.md b/docs/AllOfUserTaskListCompactWorkspace.md deleted file mode 100644 index df5f05c9..00000000 --- a/docs/AllOfUserTaskListCompactWorkspace.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfUserTaskListCompactWorkspace - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfUserTaskListRequestOwner.md b/docs/AllOfUserTaskListRequestOwner.md deleted file mode 100644 index 84b0c6c6..00000000 --- a/docs/AllOfUserTaskListRequestOwner.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfUserTaskListRequestOwner - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfUserTaskListRequestWorkspace.md b/docs/AllOfUserTaskListRequestWorkspace.md deleted file mode 100644 index ee9fe072..00000000 --- a/docs/AllOfUserTaskListRequestWorkspace.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfUserTaskListRequestWorkspace - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfUserTaskListResponseOwner.md b/docs/AllOfUserTaskListResponseOwner.md deleted file mode 100644 index 3f8fc3fa..00000000 --- a/docs/AllOfUserTaskListResponseOwner.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfUserTaskListResponseOwner - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfUserTaskListResponseWorkspace.md b/docs/AllOfUserTaskListResponseWorkspace.md deleted file mode 100644 index 0f2c0801..00000000 --- a/docs/AllOfUserTaskListResponseWorkspace.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfUserTaskListResponseWorkspace - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfWorkspaceMembershipResponseUserTaskListOwner.md b/docs/AllOfWorkspaceMembershipResponseUserTaskListOwner.md deleted file mode 100644 index dc09667a..00000000 --- a/docs/AllOfWorkspaceMembershipResponseUserTaskListOwner.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfWorkspaceMembershipResponseUserTaskListOwner - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AllOfWorkspaceMembershipResponseUserTaskListWorkspace.md b/docs/AllOfWorkspaceMembershipResponseUserTaskListWorkspace.md deleted file mode 100644 index 99051fd5..00000000 --- a/docs/AllOfWorkspaceMembershipResponseUserTaskListWorkspace.md +++ /dev/null @@ -1,8 +0,0 @@ -# AllOfWorkspaceMembershipResponseUserTaskListWorkspace - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AsanaNamedResource.md b/docs/AsanaNamedResource.md deleted file mode 100644 index 819e4dd6..00000000 --- a/docs/AsanaNamedResource.md +++ /dev/null @@ -1,11 +0,0 @@ -# AsanaNamedResource - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the object. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AsanaNamedResourceArray.md b/docs/AsanaNamedResourceArray.md deleted file mode 100644 index 24644e36..00000000 --- a/docs/AsanaNamedResourceArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# AsanaNamedResourceArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[AsanaNamedResource]**](AsanaNamedResource.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AsanaResource.md b/docs/AsanaResource.md deleted file mode 100644 index 00bb2a28..00000000 --- a/docs/AsanaResource.md +++ /dev/null @@ -1,10 +0,0 @@ -# AsanaResource - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AttachmentBase.md b/docs/AttachmentBase.md deleted file mode 100644 index ce497343..00000000 --- a/docs/AttachmentBase.md +++ /dev/null @@ -1,12 +0,0 @@ -# AttachmentBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the file. | [optional] -**resource_subtype** | **str** | The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `onedrive`, `box`, `vimeo`, and `external`. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AttachmentCompact.md b/docs/AttachmentCompact.md deleted file mode 100644 index 06683584..00000000 --- a/docs/AttachmentCompact.md +++ /dev/null @@ -1,12 +0,0 @@ -# AttachmentCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the file. | [optional] -**resource_subtype** | **str** | The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `onedrive`, `box`, `vimeo`, and `external`. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AttachmentRequest.md b/docs/AttachmentRequest.md deleted file mode 100644 index 5c9b6a6d..00000000 --- a/docs/AttachmentRequest.md +++ /dev/null @@ -1,14 +0,0 @@ -# AttachmentRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**resource_subtype** | **str** | The type of the attachment. Must be one of the given values. If not specified, a file attachment of type `asana` will be assumed. Note that if the value of `resource_subtype` is `external`, a `parent`, `name`, and `url` must also be provided. | [optional] -**file** | **str** | Required for `asana` attachments. | [optional] -**parent** | **str** | Required identifier of the parent task, project, or project_brief, as a string. | -**url** | **str** | The URL of the external resource being attached. Required for attachments of type `external`. | [optional] -**name** | **str** | The name of the external resource being attached. Required for attachments of type `external`. | [optional] -**connect_to_app** | **bool** | *Optional*. Only relevant for external attachments with a parent task. A boolean indicating whether the current app should be connected with the attachment for the purposes of showing an app components widget. Requires the app to have been added to a project the parent task is in. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AttachmentResponse.md b/docs/AttachmentResponse.md deleted file mode 100644 index 43ebef4b..00000000 --- a/docs/AttachmentResponse.md +++ /dev/null @@ -1,20 +0,0 @@ -# AttachmentResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the file. | [optional] -**resource_subtype** | **str** | The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `onedrive`, `box`, `vimeo`, and `external`. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**download_url** | **str** | The URL containing the content of the attachment. *Note:* May be null if the attachment is hosted by [Box](https://www.box.com/) and will be null if the attachment is a Video Message hosted by [Vimeo](https://vimeo.com/). If present, this URL may only be valid for two minutes from the time of retrieval. You should avoid persisting this URL somewhere and just refresh it on demand to ensure you do not keep stale URLs. | [optional] -**permanent_url** | **str** | | [optional] -**host** | **str** | The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `box`, and `vimeo`. | [optional] -**parent** | [**AttachmentResponseParent**](AttachmentResponseParent.md) | | [optional] -**size** | **int** | The size of the attachment in bytes. Only present when the `resource_subtype` is `asana`. | [optional] -**view_url** | **str** | The URL where the attachment can be viewed, which may be friendlier to users in a browser than just directing them to a raw file. May be null if no view URL exists for the service. | [optional] -**connected_to_app** | **bool** | Whether the attachment is connected to the app making the request for the purposes of showing an app components widget. Only present when the `resource_subtype` is `external` or `gdrive`. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AttachmentResponseArray.md b/docs/AttachmentResponseArray.md deleted file mode 100644 index a1d0d4f0..00000000 --- a/docs/AttachmentResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# AttachmentResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[AttachmentResponse]**](AttachmentResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AttachmentResponseData.md b/docs/AttachmentResponseData.md deleted file mode 100644 index 752437d8..00000000 --- a/docs/AttachmentResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# AttachmentResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**AttachmentResponse**](AttachmentResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AttachmentResponseParent.md b/docs/AttachmentResponseParent.md deleted file mode 100644 index 564328db..00000000 --- a/docs/AttachmentResponseParent.md +++ /dev/null @@ -1,13 +0,0 @@ -# AttachmentResponseParent - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the task. | [optional] -**resource_subtype** | **str** | The resource subtype of the parent resource that the filter applies to. | [optional] -**created_by** | [**AttachmentResponseParentCreatedBy**](AttachmentResponseParentCreatedBy.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AttachmentResponseParentCreatedBy.md b/docs/AttachmentResponseParentCreatedBy.md deleted file mode 100644 index 316e4ffe..00000000 --- a/docs/AttachmentResponseParentCreatedBy.md +++ /dev/null @@ -1,10 +0,0 @@ -# AttachmentResponseParentCreatedBy - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource. | [optional] -**resource_type** | **str** | The type of resource. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AttachmentsApi.md b/docs/AttachmentsApi.md deleted file mode 100644 index ef3cf5a5..00000000 --- a/docs/AttachmentsApi.md +++ /dev/null @@ -1,235 +0,0 @@ -# asana.AttachmentsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_attachment_for_object**](AttachmentsApi.md#create_attachment_for_object) | **POST** /attachments | Upload an attachment -[**delete_attachment**](AttachmentsApi.md#delete_attachment) | **DELETE** /attachments/{attachment_gid} | Delete an attachment -[**get_attachment**](AttachmentsApi.md#get_attachment) | **GET** /attachments/{attachment_gid} | Get an attachment -[**get_attachments_for_object**](AttachmentsApi.md#get_attachments_for_object) | **GET** /attachments | Get attachments from an object - -# **create_attachment_for_object** -> AttachmentResponseData create_attachment_for_object(resource_subtype=resource_subtype, file=file, parent=parent, url=url, name=name, connect_to_app=connect_to_app, opt_fields=opt_fields) - -Upload an attachment - -Upload an attachment. This method uploads an attachment on an object and returns the compact record for the created attachment object. This is possible by either: - Providing the URL of the external resource being attached, or - Downloading the file content first and then uploading it as any other attachment. Note that it is not possible to attach files from third party services such as Dropbox, Box, Vimeo & Google Drive via the API The 100MB size limit on attachments in Asana is enforced on this endpoint. This endpoint expects a multipart/form-data encoded request containing the full contents of the file to be uploaded. Requests made should follow the HTTP/1.1 specification that line terminators are of the form `CRLF` or `\\r\\n` outlined [here](http://www.w3.org/Protocols/HTTP/1.1/draft-ietf-http-v11-spec-01#Basic-Rules) in order for the server to reliably and properly handle the request. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.AttachmentsApi(api_client) -resource_subtype = 'external' # str | (optional) -file = 'file_example' # str | (optional) -parent = 'parent_example' # str | (optional) -url = 'url_example' # str | (optional) -name = 'name_example' # str | (optional) -connect_to_app = true # bool | (optional) -opt_fields = ["connected_to_app","created_at","download_url","host","name","parent","parent.created_by","parent.name","parent.resource_subtype","permanent_url","resource_subtype","size","view_url"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Upload an attachment - api_response = api_instance.create_attachment_for_object(resource_subtype=resource_subtype, file=file, parent=parent, url=url, name=name, connect_to_app=connect_to_app, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling AttachmentsApi->create_attachment_for_object: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **resource_subtype** | **str**| | [optional] - **file** | **str**| | [optional] - **parent** | **str**| | [optional] - **url** | **str**| | [optional] - **name** | **str**| | [optional] - **connect_to_app** | **bool**| | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**AttachmentResponseData**](AttachmentResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: multipart/form-data - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_attachment** -> EmptyResponseData delete_attachment(attachment_gid) - -Delete an attachment - -Deletes a specific, existing attachment. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.AttachmentsApi(api_client) -attachment_gid = '12345' # str | Globally unique identifier for the attachment. - -try: - # Delete an attachment - api_response = api_instance.delete_attachment(attachment_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling AttachmentsApi->delete_attachment: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **attachment_gid** | **str**| Globally unique identifier for the attachment. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_attachment** -> AttachmentResponseData get_attachment(attachment_gid, opt_fields=opt_fields) - -Get an attachment - -Get the full record for a single attachment. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.AttachmentsApi(api_client) -attachment_gid = '12345' # str | Globally unique identifier for the attachment. -opt_fields = ["connected_to_app","created_at","download_url","host","name","parent","parent.created_by","parent.name","parent.resource_subtype","permanent_url","resource_subtype","size","view_url"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get an attachment - api_response = api_instance.get_attachment(attachment_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling AttachmentsApi->get_attachment: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **attachment_gid** | **str**| Globally unique identifier for the attachment. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**AttachmentResponseData**](AttachmentResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_attachments_for_object** -> AttachmentResponseArray get_attachments_for_object(parent, limit=limit, offset=offset, opt_fields=opt_fields) - -Get attachments from an object - -Returns the compact records for all attachments on the object. There are three possible `parent` values for this request: `project`, `project_brief`, and `task`. For a project, an attachment refers to a file uploaded to the \"Key resources\" section in the project Overview. For a project brief, an attachment refers to inline files in the project brief itself. For a task, an attachment refers to a file directly associated to that task. Note that within the Asana app, inline images in the task description do not appear in the index of image thumbnails nor as stories in the task. However, requests made to `GET /attachments` for a task will return all of the images in the task, including inline images. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.AttachmentsApi(api_client) -parent = '159874' # str | Globally unique identifier for object to fetch statuses from. Must be a GID for a `project`, `project_brief`, or `task`. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["connected_to_app","created_at","download_url","host","name","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permanent_url","resource_subtype","size","uri","view_url"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get attachments from an object - api_response = api_instance.get_attachments_for_object(parent, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling AttachmentsApi->get_attachments_for_object: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **parent** | **str**| Globally unique identifier for object to fetch statuses from. Must be a GID for a `project`, `project_brief`, or `task`. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**AttachmentResponseArray**](AttachmentResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/AttachmentsApi.yaml b/docs/AttachmentsApi.yaml deleted file mode 100644 index bf88bae7..00000000 --- a/docs/AttachmentsApi.yaml +++ /dev/null @@ -1,91 +0,0 @@ -AttachmentsApi: - create_attachment_for_object: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.AttachmentsApi(api_client) - resource_subtype = 'external' # str | (optional) - file = 'file_example' # str | (optional) - parent = 'parent_example' # str | (optional) - url = 'url_example' # str | (optional) - name = 'name_example' # str | (optional) - connect_to_app = true # bool | (optional) - opt_fields = ["connected_to_app","created_at","download_url","host","name","parent","parent.created_by","parent.name","parent.resource_subtype","permanent_url","resource_subtype","size","view_url"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Upload an attachment - api_response = api_instance.create_attachment_for_object(resource_subtype=resource_subtype, file=file, parent=parent, url=url, name=name, connect_to_app=connect_to_app, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling AttachmentsApi->create_attachment_for_object: %s\n" % e) - delete_attachment: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.AttachmentsApi(api_client) - attachment_gid = '12345' # str | Globally unique identifier for the attachment. - - try: - # Delete an attachment - api_response = api_instance.delete_attachment(attachment_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling AttachmentsApi->delete_attachment: %s\n" % e) - get_attachment: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.AttachmentsApi(api_client) - attachment_gid = '12345' # str | Globally unique identifier for the attachment. - opt_fields = ["connected_to_app","created_at","download_url","host","name","parent","parent.created_by","parent.name","parent.resource_subtype","permanent_url","resource_subtype","size","view_url"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get an attachment - api_response = api_instance.get_attachment(attachment_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling AttachmentsApi->get_attachment: %s\n" % e) - get_attachments_for_object: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.AttachmentsApi(api_client) - parent = '159874' # str | Globally unique identifier for object to fetch statuses from. Must be a GID for a `project`, `project_brief`, or `task`. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["connected_to_app","created_at","download_url","host","name","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permanent_url","resource_subtype","size","uri","view_url"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get attachments from an object - api_response = api_instance.get_attachments_for_object(parent, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling AttachmentsApi->get_attachments_for_object: %s\n" % e) diff --git a/docs/AuditLogAPIApi.md b/docs/AuditLogAPIApi.md deleted file mode 100644 index e2a6b973..00000000 --- a/docs/AuditLogAPIApi.md +++ /dev/null @@ -1,75 +0,0 @@ -# asana.AuditLogAPIApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**get_audit_log_events**](AuditLogAPIApi.md#get_audit_log_events) | **GET** /workspaces/{workspace_gid}/audit_log_events | Get audit log events - -# **get_audit_log_events** -> AuditLogEventArray get_audit_log_events(workspace_gid, start_at=start_at, end_at=end_at, event_type=event_type, actor_type=actor_type, actor_gid=actor_gid, resource_gid=resource_gid, limit=limit, offset=offset) - -Get audit log events - -Retrieve the audit log events that have been captured in your domain. This endpoint will return a list of [AuditLogEvent](/reference/audit-log-api) objects, sorted by creation time in ascending order. Note that the Audit Log API captures events from October 8th, 2021 and later. Queries for events before this date will not return results. There are a number of query parameters (below) that can be used to filter the set of [AuditLogEvent](/reference/audit-log-api) objects that are returned in the response. Any combination of query parameters is valid. When no filters are provided, all of the events that have been captured in your domain will match. The list of events will always be [paginated](/docs/pagination). The default limit is 1000 events. The next set of events can be retrieved using the `offset` from the previous response. If there are no events that match the provided filters in your domain, the endpoint will return `null` for the `next_page` field. Querying again with the same filters may return new events if they were captured after the last request. Once a response includes a `next_page` with an `offset`, subsequent requests can be made with the latest `offset` to poll for new events that match the provided filters. *Note: If the filters you provided match events in your domain and `next_page` is present in the response, we will continue to send `next_page` on subsequent requests even when there are no more events that match the filters. This was put in place so that you can implement an audit log stream that will return future events that match these filters. If you are not interested in future events that match the filters you have defined, you can rely on checking empty `data` response for the end of current events that match your filters.* When no `offset` is provided, the response will begin with the oldest events that match the provided filters. It is important to note that [AuditLogEvent](/reference/audit-log-api) objects will be permanently deleted from our systems after 90 days. If you wish to keep a permanent record of these events, we recommend using a SIEM tool to ingest and store these logs. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.AuditLogAPIApi(api_client) -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -start_at = '2013-10-20T19:20:30+01:00' # datetime | Filter to events created after this time (inclusive). (optional) -end_at = '2013-10-20T19:20:30+01:00' # datetime | Filter to events created before this time (exclusive). (optional) -event_type = 'event_type_example' # str | Filter to events of this type. Refer to the [supported audit log events](/docs/audit-log-events#supported-audit-log-events) for a full list of values. (optional) -actor_type = 'actor_type_example' # str | Filter to events with an actor of this type. This only needs to be included if querying for actor types without an ID. If `actor_gid` is included, this should be excluded. (optional) -actor_gid = 'actor_gid_example' # str | Filter to events triggered by the actor with this ID. (optional) -resource_gid = 'resource_gid_example' # str | Filter to events with this resource ID. (optional) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - -try: - # Get audit log events - api_response = api_instance.get_audit_log_events(workspace_gid, start_at=start_at, end_at=end_at, event_type=event_type, actor_type=actor_type, actor_gid=actor_gid, resource_gid=resource_gid, limit=limit, offset=offset) - pprint(api_response) -except ApiException as e: - print("Exception when calling AuditLogAPIApi->get_audit_log_events: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **start_at** | **datetime**| Filter to events created after this time (inclusive). | [optional] - **end_at** | **datetime**| Filter to events created before this time (exclusive). | [optional] - **event_type** | **str**| Filter to events of this type. Refer to the [supported audit log events](/docs/audit-log-events#supported-audit-log-events) for a full list of values. | [optional] - **actor_type** | **str**| Filter to events with an actor of this type. This only needs to be included if querying for actor types without an ID. If `actor_gid` is included, this should be excluded. | [optional] - **actor_gid** | **str**| Filter to events triggered by the actor with this ID. | [optional] - **resource_gid** | **str**| Filter to events with this resource ID. | [optional] - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - -### Return type - -[**AuditLogEventArray**](AuditLogEventArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/AuditLogAPIApi.yaml b/docs/AuditLogAPIApi.yaml deleted file mode 100644 index b03b744a..00000000 --- a/docs/AuditLogAPIApi.yaml +++ /dev/null @@ -1,29 +0,0 @@ -AuditLogAPIApi: - get_audit_log_events: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.AuditLogAPIApi(api_client) - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - start_at = '2013-10-20T19:20:30+01:00' # datetime | Filter to events created after this time (inclusive). (optional) - end_at = '2013-10-20T19:20:30+01:00' # datetime | Filter to events created before this time (exclusive). (optional) - event_type = 'event_type_example' # str | Filter to events of this type. Refer to the [supported audit log events](/docs/audit-log-events#supported-audit-log-events) for a full list of values. (optional) - actor_type = 'actor_type_example' # str | Filter to events with an actor of this type. This only needs to be included if querying for actor types without an ID. If `actor_gid` is included, this should be excluded. (optional) - actor_gid = 'actor_gid_example' # str | Filter to events triggered by the actor with this ID. (optional) - resource_gid = 'resource_gid_example' # str | Filter to events with this resource ID. (optional) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - - try: - # Get audit log events - api_response = api_instance.get_audit_log_events(workspace_gid, start_at=start_at, end_at=end_at, event_type=event_type, actor_type=actor_type, actor_gid=actor_gid, resource_gid=resource_gid, limit=limit, offset=offset) - pprint(api_response) - except ApiException as e: - print("Exception when calling AuditLogAPIApi->get_audit_log_events: %s\n" % e) diff --git a/docs/AuditLogEvent.md b/docs/AuditLogEvent.md deleted file mode 100644 index efa83a37..00000000 --- a/docs/AuditLogEvent.md +++ /dev/null @@ -1,16 +0,0 @@ -# AuditLogEvent - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the `AuditLogEvent`, as a string. | [optional] -**created_at** | **datetime** | The time the event was created. | [optional] -**event_type** | **str** | The type of the event. | [optional] -**event_category** | **str** | The category that this `event_type` belongs to. | [optional] -**actor** | [**AuditLogEventActor**](AuditLogEventActor.md) | | [optional] -**resource** | [**AuditLogEventResource**](AuditLogEventResource.md) | | [optional] -**details** | **object** | Event specific details. The schema will vary depending on the `event_type`. | [optional] -**context** | [**AuditLogEventContext**](AuditLogEventContext.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AuditLogEventActor.md b/docs/AuditLogEventActor.md deleted file mode 100644 index dcdc4f03..00000000 --- a/docs/AuditLogEventActor.md +++ /dev/null @@ -1,12 +0,0 @@ -# AuditLogEventActor - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**actor_type** | **str** | The type of actor. Can be one of `user`, `asana`, `asana_support`, `anonymous`, or `external_administrator`. | [optional] -**gid** | **str** | Globally unique identifier of the actor, if it is a user. | [optional] -**name** | **str** | The name of the actor, if it is a user. | [optional] -**email** | **str** | The email of the actor, if it is a user. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AuditLogEventArray.md b/docs/AuditLogEventArray.md deleted file mode 100644 index 7580a0b4..00000000 --- a/docs/AuditLogEventArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# AuditLogEventArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[AuditLogEvent]**](AuditLogEvent.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AuditLogEventContext.md b/docs/AuditLogEventContext.md deleted file mode 100644 index 9d66be07..00000000 --- a/docs/AuditLogEventContext.md +++ /dev/null @@ -1,13 +0,0 @@ -# AuditLogEventContext - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**context_type** | **str** | The type of context. Can be one of `web`, `desktop`, `mobile`, `asana_support`, `asana`, `email`, or `api`. | [optional] -**api_authentication_method** | **str** | The authentication method used in the context of an API request. Only present if the `context_type` is `api`. Can be one of `cookie`, `oauth`, `personal_access_token`, or `service_account`. | [optional] -**client_ip_address** | **str** | The IP address of the client that initiated the event, if applicable. | [optional] -**user_agent** | **str** | The user agent of the client that initiated the event, if applicable. | [optional] -**oauth_app_name** | **str** | The name of the OAuth App that initiated the event. Only present if the `api_authentication_method` is `oauth`. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AuditLogEventDetails.md b/docs/AuditLogEventDetails.md deleted file mode 100644 index 955d2497..00000000 --- a/docs/AuditLogEventDetails.md +++ /dev/null @@ -1,8 +0,0 @@ -# AuditLogEventDetails - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/AuditLogEventResource.md b/docs/AuditLogEventResource.md deleted file mode 100644 index e057b21c..00000000 --- a/docs/AuditLogEventResource.md +++ /dev/null @@ -1,13 +0,0 @@ -# AuditLogEventResource - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**resource_type** | **str** | The type of resource. | [optional] -**resource_subtype** | **str** | The subtype of resource. Most resources will not have a subtype. | [optional] -**gid** | **str** | Globally unique identifier of the resource. | [optional] -**name** | **str** | The name of the resource. | [optional] -**email** | **str** | The email of the resource, if applicable. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/BatchAPIApi.md b/docs/BatchAPIApi.md deleted file mode 100644 index be932bbb..00000000 --- a/docs/BatchAPIApi.md +++ /dev/null @@ -1,61 +0,0 @@ -# asana.BatchAPIApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_batch_request**](BatchAPIApi.md#create_batch_request) | **POST** /batch | Submit parallel requests - -# **create_batch_request** -> BatchResponseArray create_batch_request(body, opt_fields=opt_fields) - -Submit parallel requests - -Make multiple requests in parallel to Asana's API. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.BatchAPIApi(api_client) -body = asana.BatchBody({"param1": "value1", "param2": "value2",}) # BatchBody | The requests to batch together via the Batch API. -opt_fields = ["body","headers","status_code"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Submit parallel requests - api_response = api_instance.create_batch_request(body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling BatchAPIApi->create_batch_request: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**BatchBody**](BatchBody.md)| The requests to batch together via the Batch API. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**BatchResponseArray**](BatchResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/BatchAPIApi.yaml b/docs/BatchAPIApi.yaml deleted file mode 100644 index 38a61181..00000000 --- a/docs/BatchAPIApi.yaml +++ /dev/null @@ -1,22 +0,0 @@ -BatchAPIApi: - create_batch_request: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.BatchAPIApi(api_client) - body = asana.BatchBody({"param1": "value1", "param2": "value2",}) # BatchBody | The requests to batch together via the Batch API. - opt_fields = ["body","headers","status_code"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Submit parallel requests - api_response = api_instance.create_batch_request(body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling BatchAPIApi->create_batch_request: %s\n" % e) diff --git a/docs/BatchBody.md b/docs/BatchBody.md deleted file mode 100644 index 61d67702..00000000 --- a/docs/BatchBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# BatchBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**BatchRequest**](BatchRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/BatchRequest.md b/docs/BatchRequest.md deleted file mode 100644 index af2de2fe..00000000 --- a/docs/BatchRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# BatchRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**actions** | [**list[BatchRequestActions]**](BatchRequestActions.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/BatchRequestAction.md b/docs/BatchRequestAction.md deleted file mode 100644 index 5f7d1b8c..00000000 --- a/docs/BatchRequestAction.md +++ /dev/null @@ -1,12 +0,0 @@ -# BatchRequestAction - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**relative_path** | **str** | The path of the desired endpoint relative to the API’s base URL. Query parameters are not accepted here; put them in `data` instead. | -**method** | **str** | The HTTP method you wish to emulate for the action. | -**data** | **object** | For `GET` requests, this should be a map of query parameters you would have normally passed in the URL. Options and pagination are not accepted here; put them in `options` instead. For `POST`, `PATCH`, and `PUT` methods, this should be the content you would have normally put in the data field of the body. | [optional] -**options** | [**BatchRequestOptions**](BatchRequestOptions.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/BatchRequestActions.md b/docs/BatchRequestActions.md deleted file mode 100644 index ce0be0e8..00000000 --- a/docs/BatchRequestActions.md +++ /dev/null @@ -1,12 +0,0 @@ -# BatchRequestActions - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**relative_path** | **str** | The path of the desired endpoint relative to the API’s base URL. Query parameters are not accepted here; put them in `data` instead. | -**method** | **str** | The HTTP method you wish to emulate for the action. | -**data** | **object** | For `GET` requests, this should be a map of query parameters you would have normally passed in the URL. Options and pagination are not accepted here; put them in `options` instead. For `POST`, `PATCH`, and `PUT` methods, this should be the content you would have normally put in the data field of the body. | [optional] -**options** | [**BatchRequestOptions**](BatchRequestOptions.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/BatchRequestOptions.md b/docs/BatchRequestOptions.md deleted file mode 100644 index 039e810b..00000000 --- a/docs/BatchRequestOptions.md +++ /dev/null @@ -1,11 +0,0 @@ -# BatchRequestOptions - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**limit** | **int** | Pagination limit for the request. | [optional] -**offset** | **int** | Pagination offset for the request. | [optional] -**fields** | **list[str]** | The fields to retrieve in the request. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/BatchResponse.md b/docs/BatchResponse.md deleted file mode 100644 index 46995336..00000000 --- a/docs/BatchResponse.md +++ /dev/null @@ -1,11 +0,0 @@ -# BatchResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**status_code** | **int** | The HTTP status code that the invoked endpoint returned. | [optional] -**headers** | **object** | A map of HTTP headers specific to this result. This is primarily used for returning a `Location` header to accompany a `201 Created` result. The parent HTTP response will contain all common headers. | [optional] -**body** | **object** | The JSON body that the invoked endpoint returned. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/BatchResponseArray.md b/docs/BatchResponseArray.md deleted file mode 100644 index a9296f18..00000000 --- a/docs/BatchResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# BatchResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[BatchResponse]**](BatchResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CreateMembershipRequest.md b/docs/CreateMembershipRequest.md deleted file mode 100644 index da108013..00000000 --- a/docs/CreateMembershipRequest.md +++ /dev/null @@ -1,11 +0,0 @@ -# CreateMembershipRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**is_active** | **bool** | *Optional*. Denotes if a member is active. Applies to all memberships | [optional] -**member** | **str** | The gid of the user or team | [optional] -**parent** | **str** | The gid of the `goal` | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CreateTimeTrackingEntryRequest.md b/docs/CreateTimeTrackingEntryRequest.md deleted file mode 100644 index 9ab8bb19..00000000 --- a/docs/CreateTimeTrackingEntryRequest.md +++ /dev/null @@ -1,10 +0,0 @@ -# CreateTimeTrackingEntryRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**duration_minutes** | **int** | Time in minutes tracked by the entry. Must be greater than 0 | [optional] -**entered_on** | **date** | *Optional*. The day that this entry is logged on. Defaults to today if not specified | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldBase.md b/docs/CustomFieldBase.md deleted file mode 100644 index 0527f808..00000000 --- a/docs/CustomFieldBase.md +++ /dev/null @@ -1,31 +0,0 @@ -# CustomFieldBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the custom field. | [optional] -**resource_subtype** | **str** | The type of the custom field. Must be one of the given values. | [optional] -**type** | **str** | *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. | [optional] -**enum_options** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). | [optional] -**enabled** | **bool** | *Conditional*. Determines if the custom field is enabled or not. | [optional] -**is_formula_field** | **bool** | *Conditional*. This flag describes whether a custom field is a formula custom field. | [optional] -**date_value** | [**CustomFieldBaseDateValue**](CustomFieldBaseDateValue.md) | | [optional] -**enum_value** | [**CustomFieldBaseEnumValue**](CustomFieldBaseEnumValue.md) | | [optional] -**multi_enum_values** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. | [optional] -**number_value** | **float** | *Conditional*. This number is the value of a `number` custom field. | [optional] -**text_value** | **str** | *Conditional*. This string is the value of a `text` custom field. | [optional] -**display_value** | **str** | A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. | [optional] -**description** | **str** | [Opt In](/docs/inputoutput-options). The description of the custom field. | [optional] -**precision** | **int** | Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. | [optional] -**format** | **str** | The format of this custom field. | [optional] -**currency_code** | **str** | ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. | [optional] -**custom_label** | **str** | This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. | [optional] -**custom_label_position** | **str** | Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. | [optional] -**is_global_to_workspace** | **bool** | This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. | [optional] -**has_notifications_enabled** | **bool** | *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. | [optional] -**asana_created_field** | **str** | *Conditional*. A unique identifier to associate this field with the template source of truth. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldBaseDateValue.md b/docs/CustomFieldBaseDateValue.md deleted file mode 100644 index 91b3cbcb..00000000 --- a/docs/CustomFieldBaseDateValue.md +++ /dev/null @@ -1,10 +0,0 @@ -# CustomFieldBaseDateValue - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**_date** | **str** | A string representing the date in YYYY-MM-DD format. | [optional] -**date_time** | **str** | A string representing the date in ISO 8601 format. If no time value is selected, the value of `date-time` will be `null`. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldBaseEnumOptions.md b/docs/CustomFieldBaseEnumOptions.md deleted file mode 100644 index 2a6964cd..00000000 --- a/docs/CustomFieldBaseEnumOptions.md +++ /dev/null @@ -1,13 +0,0 @@ -# CustomFieldBaseEnumOptions - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the enum option. | [optional] -**enabled** | **bool** | Whether or not the enum option is a selectable value for the custom field. | [optional] -**color** | **str** | The color of the enum option. Defaults to ‘none’. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldBaseEnumValue.md b/docs/CustomFieldBaseEnumValue.md deleted file mode 100644 index 4bc7ef55..00000000 --- a/docs/CustomFieldBaseEnumValue.md +++ /dev/null @@ -1,13 +0,0 @@ -# CustomFieldBaseEnumValue - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the enum option. | [optional] -**enabled** | **bool** | Whether or not the enum option is a selectable value for the custom field. | [optional] -**color** | **str** | The color of the enum option. Defaults to ‘none’. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldCompact.md b/docs/CustomFieldCompact.md deleted file mode 100644 index 4b4e19f2..00000000 --- a/docs/CustomFieldCompact.md +++ /dev/null @@ -1,22 +0,0 @@ -# CustomFieldCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the custom field. | [optional] -**resource_subtype** | **str** | The type of the custom field. Must be one of the given values. | [optional] -**type** | **str** | *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. | [optional] -**enum_options** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). | [optional] -**enabled** | **bool** | *Conditional*. Determines if the custom field is enabled or not. | [optional] -**is_formula_field** | **bool** | *Conditional*. This flag describes whether a custom field is a formula custom field. | [optional] -**date_value** | [**CustomFieldBaseDateValue**](CustomFieldBaseDateValue.md) | | [optional] -**enum_value** | [**CustomFieldBaseEnumValue**](CustomFieldBaseEnumValue.md) | | [optional] -**multi_enum_values** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. | [optional] -**number_value** | **float** | *Conditional*. This number is the value of a `number` custom field. | [optional] -**text_value** | **str** | *Conditional*. This string is the value of a `text` custom field. | [optional] -**display_value** | **str** | A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldGidEnumOptionsBody.md b/docs/CustomFieldGidEnumOptionsBody.md deleted file mode 100644 index 36daa270..00000000 --- a/docs/CustomFieldGidEnumOptionsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# CustomFieldGidEnumOptionsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**EnumOptionRequest**](EnumOptionRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldRequest.md b/docs/CustomFieldRequest.md deleted file mode 100644 index b594ae23..00000000 --- a/docs/CustomFieldRequest.md +++ /dev/null @@ -1,34 +0,0 @@ -# CustomFieldRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the custom field. | [optional] -**resource_subtype** | **str** | The type of the custom field. Must be one of the given values. | [optional] -**type** | **str** | *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. | [optional] -**enum_options** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). | [optional] -**enabled** | **bool** | *Conditional*. Determines if the custom field is enabled or not. | [optional] -**is_formula_field** | **bool** | *Conditional*. This flag describes whether a custom field is a formula custom field. | [optional] -**date_value** | [**CustomFieldBaseDateValue**](CustomFieldBaseDateValue.md) | | [optional] -**enum_value** | [**CustomFieldBaseEnumValue**](CustomFieldBaseEnumValue.md) | | [optional] -**multi_enum_values** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. | [optional] -**number_value** | **float** | *Conditional*. This number is the value of a `number` custom field. | [optional] -**text_value** | **str** | *Conditional*. This string is the value of a `text` custom field. | [optional] -**display_value** | **str** | A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. | [optional] -**description** | **str** | [Opt In](/docs/inputoutput-options). The description of the custom field. | [optional] -**precision** | **int** | Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. | [optional] -**format** | **str** | The format of this custom field. | [optional] -**currency_code** | **str** | ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. | [optional] -**custom_label** | **str** | This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. | [optional] -**custom_label_position** | **str** | Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. | [optional] -**is_global_to_workspace** | **bool** | This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. | [optional] -**has_notifications_enabled** | **bool** | *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. | [optional] -**asana_created_field** | **str** | *Conditional*. A unique identifier to associate this field with the template source of truth. | [optional] -**workspace** | **str** | *Create-Only* The workspace to create a custom field in. | -**owned_by_app** | **bool** | *Allow-listed*. Instructs the API that this Custom Field is app-owned. This parameter is allow-listed to specific apps at this point in time. For apps that are not allow-listed, providing this parameter will result in a `403 Forbidden`. | [optional] -**people_value** | **list[str]** | *Conditional*. Only relevant for custom fields of type `people`. This array of user GIDs reflects the users to be written to a `people` custom field. Note that *write* operations will replace existing users (if any) in the custom field with the users specified in this array. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldResponse.md b/docs/CustomFieldResponse.md deleted file mode 100644 index 4787b4a8..00000000 --- a/docs/CustomFieldResponse.md +++ /dev/null @@ -1,34 +0,0 @@ -# CustomFieldResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the custom field. | [optional] -**resource_subtype** | **str** | The type of the custom field. Must be one of the given values. | [optional] -**type** | **str** | *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. | [optional] -**enum_options** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). | [optional] -**enabled** | **bool** | *Conditional*. Determines if the custom field is enabled or not. | [optional] -**is_formula_field** | **bool** | *Conditional*. This flag describes whether a custom field is a formula custom field. | [optional] -**date_value** | [**CustomFieldBaseDateValue**](CustomFieldBaseDateValue.md) | | [optional] -**enum_value** | [**CustomFieldBaseEnumValue**](CustomFieldBaseEnumValue.md) | | [optional] -**multi_enum_values** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. | [optional] -**number_value** | **float** | *Conditional*. This number is the value of a `number` custom field. | [optional] -**text_value** | **str** | *Conditional*. This string is the value of a `text` custom field. | [optional] -**display_value** | **str** | A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. | [optional] -**description** | **str** | [Opt In](/docs/inputoutput-options). The description of the custom field. | [optional] -**precision** | **int** | Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. | [optional] -**format** | **str** | The format of this custom field. | [optional] -**currency_code** | **str** | ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. | [optional] -**custom_label** | **str** | This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. | [optional] -**custom_label_position** | **str** | Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. | [optional] -**is_global_to_workspace** | **bool** | This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. | [optional] -**has_notifications_enabled** | **bool** | *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. | [optional] -**asana_created_field** | **str** | *Conditional*. A unique identifier to associate this field with the template source of truth. | [optional] -**is_value_read_only** | **bool** | *Conditional*. This flag describes whether a custom field is read only. | [optional] -**created_by** | [**CustomFieldResponseCreatedBy**](CustomFieldResponseCreatedBy.md) | | [optional] -**people_value** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | *Conditional*. Only relevant for custom fields of type `people`. This array of [compact user](/reference/users) objects reflects the values of a `people` custom field. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldResponseArray.md b/docs/CustomFieldResponseArray.md deleted file mode 100644 index 399951db..00000000 --- a/docs/CustomFieldResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# CustomFieldResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[CustomFieldResponse]**](CustomFieldResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldResponseCreatedBy.md b/docs/CustomFieldResponseCreatedBy.md deleted file mode 100644 index 10e8eecf..00000000 --- a/docs/CustomFieldResponseCreatedBy.md +++ /dev/null @@ -1,11 +0,0 @@ -# CustomFieldResponseCreatedBy - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | *Read-only except when same user as requester*. The user’s name. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldResponseData.md b/docs/CustomFieldResponseData.md deleted file mode 100644 index 950ffc03..00000000 --- a/docs/CustomFieldResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# CustomFieldResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**CustomFieldResponse**](CustomFieldResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldResponsePeopleValue.md b/docs/CustomFieldResponsePeopleValue.md deleted file mode 100644 index 1a1d602d..00000000 --- a/docs/CustomFieldResponsePeopleValue.md +++ /dev/null @@ -1,11 +0,0 @@ -# CustomFieldResponsePeopleValue - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | *Read-only except when same user as requester*. The user’s name. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldSettingBase.md b/docs/CustomFieldSettingBase.md deleted file mode 100644 index 7d127d95..00000000 --- a/docs/CustomFieldSettingBase.md +++ /dev/null @@ -1,10 +0,0 @@ -# CustomFieldSettingBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldSettingCompact.md b/docs/CustomFieldSettingCompact.md deleted file mode 100644 index 1e2f39c3..00000000 --- a/docs/CustomFieldSettingCompact.md +++ /dev/null @@ -1,10 +0,0 @@ -# CustomFieldSettingCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldSettingResponse.md b/docs/CustomFieldSettingResponse.md deleted file mode 100644 index b90ffd41..00000000 --- a/docs/CustomFieldSettingResponse.md +++ /dev/null @@ -1,14 +0,0 @@ -# CustomFieldSettingResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**project** | [**CustomFieldSettingResponseProject**](CustomFieldSettingResponseProject.md) | | [optional] -**is_important** | **bool** | `is_important` is used in the Asana web application to determine if this custom field is displayed in the list/grid view of a project or portfolio. | [optional] -**parent** | [**CustomFieldSettingResponseParent**](CustomFieldSettingResponseParent.md) | | [optional] -**custom_field** | [**CustomFieldSettingResponseCustomField**](CustomFieldSettingResponseCustomField.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldSettingResponseArray.md b/docs/CustomFieldSettingResponseArray.md deleted file mode 100644 index 0a4f8e20..00000000 --- a/docs/CustomFieldSettingResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# CustomFieldSettingResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[CustomFieldSettingResponse]**](CustomFieldSettingResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldSettingResponseCustomField.md b/docs/CustomFieldSettingResponseCustomField.md deleted file mode 100644 index 35a5e890..00000000 --- a/docs/CustomFieldSettingResponseCustomField.md +++ /dev/null @@ -1,34 +0,0 @@ -# CustomFieldSettingResponseCustomField - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the custom field. | [optional] -**resource_subtype** | **str** | The type of the custom field. Must be one of the given values. | [optional] -**type** | **str** | *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. | [optional] -**enum_options** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). | [optional] -**enabled** | **bool** | *Conditional*. Determines if the custom field is enabled or not. | [optional] -**is_formula_field** | **bool** | *Conditional*. This flag describes whether a custom field is a formula custom field. | [optional] -**date_value** | [**CustomFieldBaseDateValue**](CustomFieldBaseDateValue.md) | | [optional] -**enum_value** | [**CustomFieldBaseEnumValue**](CustomFieldBaseEnumValue.md) | | [optional] -**multi_enum_values** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. | [optional] -**number_value** | **float** | *Conditional*. This number is the value of a `number` custom field. | [optional] -**text_value** | **str** | *Conditional*. This string is the value of a `text` custom field. | [optional] -**display_value** | **str** | A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. | [optional] -**description** | **str** | [Opt In](/docs/inputoutput-options). The description of the custom field. | [optional] -**precision** | **int** | Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. | [optional] -**format** | **str** | The format of this custom field. | [optional] -**currency_code** | **str** | ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. | [optional] -**custom_label** | **str** | This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. | [optional] -**custom_label_position** | **str** | Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. | [optional] -**is_global_to_workspace** | **bool** | This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. | [optional] -**has_notifications_enabled** | **bool** | *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. | [optional] -**asana_created_field** | **str** | *Conditional*. A unique identifier to associate this field with the template source of truth. | [optional] -**is_value_read_only** | **bool** | *Conditional*. This flag describes whether a custom field is read only. | [optional] -**created_by** | [**CustomFieldResponseCreatedBy**](CustomFieldResponseCreatedBy.md) | | [optional] -**people_value** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | *Conditional*. Only relevant for custom fields of type `people`. This array of [compact user](/reference/users) objects reflects the values of a `people` custom field. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldSettingResponseData.md b/docs/CustomFieldSettingResponseData.md deleted file mode 100644 index b84a606c..00000000 --- a/docs/CustomFieldSettingResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# CustomFieldSettingResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**CustomFieldSettingResponse**](CustomFieldSettingResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldSettingResponseParent.md b/docs/CustomFieldSettingResponseParent.md deleted file mode 100644 index c80f620b..00000000 --- a/docs/CustomFieldSettingResponseParent.md +++ /dev/null @@ -1,11 +0,0 @@ -# CustomFieldSettingResponseParent - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldSettingResponseProject.md b/docs/CustomFieldSettingResponseProject.md deleted file mode 100644 index 0213fd99..00000000 --- a/docs/CustomFieldSettingResponseProject.md +++ /dev/null @@ -1,11 +0,0 @@ -# CustomFieldSettingResponseProject - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldSettingsApi.md b/docs/CustomFieldSettingsApi.md deleted file mode 100644 index 7e3ea2d0..00000000 --- a/docs/CustomFieldSettingsApi.md +++ /dev/null @@ -1,123 +0,0 @@ -# asana.CustomFieldSettingsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**get_custom_field_settings_for_portfolio**](CustomFieldSettingsApi.md#get_custom_field_settings_for_portfolio) | **GET** /portfolios/{portfolio_gid}/custom_field_settings | Get a portfolio's custom fields -[**get_custom_field_settings_for_project**](CustomFieldSettingsApi.md#get_custom_field_settings_for_project) | **GET** /projects/{project_gid}/custom_field_settings | Get a project's custom fields - -# **get_custom_field_settings_for_portfolio** -> CustomFieldSettingResponseArray get_custom_field_settings_for_portfolio(portfolio_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get a portfolio's custom fields - -Returns a list of all of the custom fields settings on a portfolio, in compact form. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.CustomFieldSettingsApi(api_client) -portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["custom_field","custom_field.asana_created_field","custom_field.created_by","custom_field.created_by.name","custom_field.currency_code","custom_field.custom_label","custom_field.custom_label_position","custom_field.date_value","custom_field.date_value.date","custom_field.date_value.date_time","custom_field.description","custom_field.display_value","custom_field.enabled","custom_field.enum_options","custom_field.enum_options.color","custom_field.enum_options.enabled","custom_field.enum_options.name","custom_field.enum_value","custom_field.enum_value.color","custom_field.enum_value.enabled","custom_field.enum_value.name","custom_field.format","custom_field.has_notifications_enabled","custom_field.is_formula_field","custom_field.is_global_to_workspace","custom_field.is_value_read_only","custom_field.multi_enum_values","custom_field.multi_enum_values.color","custom_field.multi_enum_values.enabled","custom_field.multi_enum_values.name","custom_field.name","custom_field.number_value","custom_field.people_value","custom_field.people_value.name","custom_field.precision","custom_field.resource_subtype","custom_field.text_value","custom_field.type","is_important","offset","parent","parent.name","path","project","project.name","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a portfolio's custom fields - api_response = api_instance.get_custom_field_settings_for_portfolio(portfolio_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling CustomFieldSettingsApi->get_custom_field_settings_for_portfolio: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **portfolio_gid** | **str**| Globally unique identifier for the portfolio. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**CustomFieldSettingResponseArray**](CustomFieldSettingResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_custom_field_settings_for_project** -> CustomFieldSettingResponseArray get_custom_field_settings_for_project(project_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get a project's custom fields - -Returns a list of all of the custom fields settings on a project, in compact form. Note that, as in all queries to collections which return compact representation, `opt_fields` can be used to include more data than is returned in the compact representation. See the [documentation for input/output options](https://developers.asana.com/docs/inputoutput-options) for more information. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.CustomFieldSettingsApi(api_client) -project_gid = '1331' # str | Globally unique identifier for the project. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["custom_field","custom_field.asana_created_field","custom_field.created_by","custom_field.created_by.name","custom_field.currency_code","custom_field.custom_label","custom_field.custom_label_position","custom_field.date_value","custom_field.date_value.date","custom_field.date_value.date_time","custom_field.description","custom_field.display_value","custom_field.enabled","custom_field.enum_options","custom_field.enum_options.color","custom_field.enum_options.enabled","custom_field.enum_options.name","custom_field.enum_value","custom_field.enum_value.color","custom_field.enum_value.enabled","custom_field.enum_value.name","custom_field.format","custom_field.has_notifications_enabled","custom_field.is_formula_field","custom_field.is_global_to_workspace","custom_field.is_value_read_only","custom_field.multi_enum_values","custom_field.multi_enum_values.color","custom_field.multi_enum_values.enabled","custom_field.multi_enum_values.name","custom_field.name","custom_field.number_value","custom_field.people_value","custom_field.people_value.name","custom_field.precision","custom_field.resource_subtype","custom_field.text_value","custom_field.type","is_important","offset","parent","parent.name","path","project","project.name","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a project's custom fields - api_response = api_instance.get_custom_field_settings_for_project(project_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling CustomFieldSettingsApi->get_custom_field_settings_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_gid** | **str**| Globally unique identifier for the project. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**CustomFieldSettingResponseArray**](CustomFieldSettingResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldSettingsApi.yaml b/docs/CustomFieldSettingsApi.yaml deleted file mode 100644 index 2d71a3ca..00000000 --- a/docs/CustomFieldSettingsApi.yaml +++ /dev/null @@ -1,47 +0,0 @@ -CustomFieldSettingsApi: - get_custom_field_settings_for_portfolio: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.CustomFieldSettingsApi(api_client) - portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["custom_field","custom_field.asana_created_field","custom_field.created_by","custom_field.created_by.name","custom_field.currency_code","custom_field.custom_label","custom_field.custom_label_position","custom_field.date_value","custom_field.date_value.date","custom_field.date_value.date_time","custom_field.description","custom_field.display_value","custom_field.enabled","custom_field.enum_options","custom_field.enum_options.color","custom_field.enum_options.enabled","custom_field.enum_options.name","custom_field.enum_value","custom_field.enum_value.color","custom_field.enum_value.enabled","custom_field.enum_value.name","custom_field.format","custom_field.has_notifications_enabled","custom_field.is_formula_field","custom_field.is_global_to_workspace","custom_field.is_value_read_only","custom_field.multi_enum_values","custom_field.multi_enum_values.color","custom_field.multi_enum_values.enabled","custom_field.multi_enum_values.name","custom_field.name","custom_field.number_value","custom_field.people_value","custom_field.people_value.name","custom_field.precision","custom_field.resource_subtype","custom_field.text_value","custom_field.type","is_important","offset","parent","parent.name","path","project","project.name","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a portfolio's custom fields - api_response = api_instance.get_custom_field_settings_for_portfolio(portfolio_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling CustomFieldSettingsApi->get_custom_field_settings_for_portfolio: %s\n" % e) - get_custom_field_settings_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.CustomFieldSettingsApi(api_client) - project_gid = '1331' # str | Globally unique identifier for the project. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["custom_field","custom_field.asana_created_field","custom_field.created_by","custom_field.created_by.name","custom_field.currency_code","custom_field.custom_label","custom_field.custom_label_position","custom_field.date_value","custom_field.date_value.date","custom_field.date_value.date_time","custom_field.description","custom_field.display_value","custom_field.enabled","custom_field.enum_options","custom_field.enum_options.color","custom_field.enum_options.enabled","custom_field.enum_options.name","custom_field.enum_value","custom_field.enum_value.color","custom_field.enum_value.enabled","custom_field.enum_value.name","custom_field.format","custom_field.has_notifications_enabled","custom_field.is_formula_field","custom_field.is_global_to_workspace","custom_field.is_value_read_only","custom_field.multi_enum_values","custom_field.multi_enum_values.color","custom_field.multi_enum_values.enabled","custom_field.multi_enum_values.name","custom_field.name","custom_field.number_value","custom_field.people_value","custom_field.people_value.name","custom_field.precision","custom_field.resource_subtype","custom_field.text_value","custom_field.type","is_important","offset","parent","parent.name","path","project","project.name","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a project's custom fields - api_response = api_instance.get_custom_field_settings_for_project(project_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling CustomFieldSettingsApi->get_custom_field_settings_for_project: %s\n" % e) diff --git a/docs/CustomFieldsApi.md b/docs/CustomFieldsApi.md deleted file mode 100644 index 418b7358..00000000 --- a/docs/CustomFieldsApi.md +++ /dev/null @@ -1,449 +0,0 @@ -# asana.CustomFieldsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_custom_field**](CustomFieldsApi.md#create_custom_field) | **POST** /custom_fields | Create a custom field -[**create_enum_option_for_custom_field**](CustomFieldsApi.md#create_enum_option_for_custom_field) | **POST** /custom_fields/{custom_field_gid}/enum_options | Create an enum option -[**delete_custom_field**](CustomFieldsApi.md#delete_custom_field) | **DELETE** /custom_fields/{custom_field_gid} | Delete a custom field -[**get_custom_field**](CustomFieldsApi.md#get_custom_field) | **GET** /custom_fields/{custom_field_gid} | Get a custom field -[**get_custom_fields_for_workspace**](CustomFieldsApi.md#get_custom_fields_for_workspace) | **GET** /workspaces/{workspace_gid}/custom_fields | Get a workspace's custom fields -[**insert_enum_option_for_custom_field**](CustomFieldsApi.md#insert_enum_option_for_custom_field) | **POST** /custom_fields/{custom_field_gid}/enum_options/insert | Reorder a custom field's enum -[**update_custom_field**](CustomFieldsApi.md#update_custom_field) | **PUT** /custom_fields/{custom_field_gid} | Update a custom field -[**update_enum_option**](CustomFieldsApi.md#update_enum_option) | **PUT** /enum_options/{enum_option_gid} | Update an enum option - -# **create_custom_field** -> CustomFieldResponseData create_custom_field(body, opt_fields=opt_fields) - -Create a custom field - -Creates a new custom field in a workspace. Every custom field is required to be created in a specific workspace, and this workspace cannot be changed once set. A custom field’s name must be unique within a workspace and not conflict with names of existing task properties such as `Due Date` or `Assignee`. A custom field’s type must be one of `text`, `enum`, `multi_enum`, `number`, `date`, or `people`. Returns the full record of the newly created custom field. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.CustomFieldsApi(api_client) -body = asana.CustomFieldsBody({"param1": "value1", "param2": "value2",}) # CustomFieldsBody | The custom field object to create. -opt_fields = ["asana_created_field","created_by","created_by.name","currency_code","custom_label","custom_label_position","date_value","date_value.date","date_value.date_time","description","display_value","enabled","enum_options","enum_options.color","enum_options.enabled","enum_options.name","enum_value","enum_value.color","enum_value.enabled","enum_value.name","format","has_notifications_enabled","is_formula_field","is_global_to_workspace","is_value_read_only","multi_enum_values","multi_enum_values.color","multi_enum_values.enabled","multi_enum_values.name","name","number_value","people_value","people_value.name","precision","resource_subtype","text_value","type"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a custom field - api_response = api_instance.create_custom_field(body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling CustomFieldsApi->create_custom_field: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**CustomFieldsBody**](CustomFieldsBody.md)| The custom field object to create. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**CustomFieldResponseData**](CustomFieldResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **create_enum_option_for_custom_field** -> EnumOptionData create_enum_option_for_custom_field(custom_field_gid, body=body, opt_fields=opt_fields) - -Create an enum option - -Creates an enum option and adds it to this custom field’s list of enum options. A custom field can have at most 500 enum options (including disabled options). By default new enum options are inserted at the end of a custom field’s list. Locked custom fields can only have enum options added by the user who locked the field. Returns the full record of the newly created enum option. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.CustomFieldsApi(api_client) -custom_field_gid = '12345' # str | Globally unique identifier for the custom field. -body = asana.CustomFieldGidEnumOptionsBody({"param1": "value1", "param2": "value2",}) # CustomFieldGidEnumOptionsBody | The enum option object to create. (optional) -opt_fields = ["color","enabled","name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create an enum option - api_response = api_instance.create_enum_option_for_custom_field(custom_field_gid, body=body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling CustomFieldsApi->create_enum_option_for_custom_field: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **custom_field_gid** | **str**| Globally unique identifier for the custom field. | - **body** | [**CustomFieldGidEnumOptionsBody**](CustomFieldGidEnumOptionsBody.md)| The enum option object to create. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**EnumOptionData**](EnumOptionData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_custom_field** -> EmptyResponseData delete_custom_field(custom_field_gid) - -Delete a custom field - -A specific, existing custom field can be deleted by making a DELETE request on the URL for that custom field. Locked custom fields can only be deleted by the user who locked the field. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.CustomFieldsApi(api_client) -custom_field_gid = '12345' # str | Globally unique identifier for the custom field. - -try: - # Delete a custom field - api_response = api_instance.delete_custom_field(custom_field_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling CustomFieldsApi->delete_custom_field: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **custom_field_gid** | **str**| Globally unique identifier for the custom field. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_custom_field** -> CustomFieldResponseData get_custom_field(custom_field_gid, opt_fields=opt_fields) - -Get a custom field - -Get the complete definition of a custom field’s metadata. Since custom fields can be defined for one of a number of types, and these types have different data and behaviors, there are fields that are relevant to a particular type. For instance, as noted above, enum_options is only relevant for the enum type and defines the set of choices that the enum could represent. The examples below show some of these type-specific custom field definitions. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.CustomFieldsApi(api_client) -custom_field_gid = '12345' # str | Globally unique identifier for the custom field. -opt_fields = ["asana_created_field","created_by","created_by.name","currency_code","custom_label","custom_label_position","date_value","date_value.date","date_value.date_time","description","display_value","enabled","enum_options","enum_options.color","enum_options.enabled","enum_options.name","enum_value","enum_value.color","enum_value.enabled","enum_value.name","format","has_notifications_enabled","is_formula_field","is_global_to_workspace","is_value_read_only","multi_enum_values","multi_enum_values.color","multi_enum_values.enabled","multi_enum_values.name","name","number_value","people_value","people_value.name","precision","resource_subtype","text_value","type"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a custom field - api_response = api_instance.get_custom_field(custom_field_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling CustomFieldsApi->get_custom_field: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **custom_field_gid** | **str**| Globally unique identifier for the custom field. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**CustomFieldResponseData**](CustomFieldResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_custom_fields_for_workspace** -> CustomFieldResponseArray get_custom_fields_for_workspace(workspace_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get a workspace's custom fields - -Returns a list of the compact representation of all of the custom fields in a workspace. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.CustomFieldsApi(api_client) -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["asana_created_field","created_by","created_by.name","currency_code","custom_label","custom_label_position","date_value","date_value.date","date_value.date_time","description","display_value","enabled","enum_options","enum_options.color","enum_options.enabled","enum_options.name","enum_value","enum_value.color","enum_value.enabled","enum_value.name","format","has_notifications_enabled","is_formula_field","is_global_to_workspace","is_value_read_only","multi_enum_values","multi_enum_values.color","multi_enum_values.enabled","multi_enum_values.name","name","number_value","offset","path","people_value","people_value.name","precision","resource_subtype","text_value","type","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a workspace's custom fields - api_response = api_instance.get_custom_fields_for_workspace(workspace_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling CustomFieldsApi->get_custom_fields_for_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**CustomFieldResponseArray**](CustomFieldResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **insert_enum_option_for_custom_field** -> EnumOptionData insert_enum_option_for_custom_field(custom_field_gid, body=body, opt_fields=opt_fields) - -Reorder a custom field's enum - -Moves a particular enum option to be either before or after another specified enum option in the custom field. Locked custom fields can only be reordered by the user who locked the field. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.CustomFieldsApi(api_client) -custom_field_gid = '12345' # str | Globally unique identifier for the custom field. -body = asana.EnumOptionsInsertBody({"param1": "value1", "param2": "value2",}) # EnumOptionsInsertBody | The enum option object to create. (optional) -opt_fields = ["color","enabled","name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Reorder a custom field's enum - api_response = api_instance.insert_enum_option_for_custom_field(custom_field_gid, body=body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling CustomFieldsApi->insert_enum_option_for_custom_field: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **custom_field_gid** | **str**| Globally unique identifier for the custom field. | - **body** | [**EnumOptionsInsertBody**](EnumOptionsInsertBody.md)| The enum option object to create. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**EnumOptionData**](EnumOptionData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_custom_field** -> CustomFieldResponseData update_custom_field(custom_field_gid, body=body, opt_fields=opt_fields) - -Update a custom field - -A specific, existing custom field can be updated by making a PUT request on the URL for that custom field. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the custom field. A custom field’s `type` cannot be updated. An enum custom field’s `enum_options` cannot be updated with this endpoint. Instead see “Work With Enum Options” for information on how to update `enum_options`. Locked custom fields can only be updated by the user who locked the field. Returns the complete updated custom field record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.CustomFieldsApi(api_client) -custom_field_gid = '12345' # str | Globally unique identifier for the custom field. -body = asana.CustomFieldsCustomFieldGidBody({"param1": "value1", "param2": "value2",}) # CustomFieldsCustomFieldGidBody | The custom field object with all updated properties. (optional) -opt_fields = ["asana_created_field","created_by","created_by.name","currency_code","custom_label","custom_label_position","date_value","date_value.date","date_value.date_time","description","display_value","enabled","enum_options","enum_options.color","enum_options.enabled","enum_options.name","enum_value","enum_value.color","enum_value.enabled","enum_value.name","format","has_notifications_enabled","is_formula_field","is_global_to_workspace","is_value_read_only","multi_enum_values","multi_enum_values.color","multi_enum_values.enabled","multi_enum_values.name","name","number_value","people_value","people_value.name","precision","resource_subtype","text_value","type"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a custom field - api_response = api_instance.update_custom_field(custom_field_gid, body=body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling CustomFieldsApi->update_custom_field: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **custom_field_gid** | **str**| Globally unique identifier for the custom field. | - **body** | [**CustomFieldsCustomFieldGidBody**](CustomFieldsCustomFieldGidBody.md)| The custom field object with all updated properties. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**CustomFieldResponseData**](CustomFieldResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_enum_option** -> EnumOptionData update_enum_option(enum_option_gid, body=body, opt_fields=opt_fields) - -Update an enum option - -Updates an existing enum option. Enum custom fields require at least one enabled enum option. Locked custom fields can only be updated by the user who locked the field. Returns the full record of the updated enum option. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.CustomFieldsApi(api_client) -enum_option_gid = '124578' # str | Globally unique identifier for the enum option. -body = asana.EnumOptionsEnumOptionGidBody({"param1": "value1", "param2": "value2",}) # EnumOptionsEnumOptionGidBody | The enum option object to update (optional) -opt_fields = ["color","enabled","name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update an enum option - api_response = api_instance.update_enum_option(enum_option_gid, body=body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling CustomFieldsApi->update_enum_option: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **enum_option_gid** | **str**| Globally unique identifier for the enum option. | - **body** | [**EnumOptionsEnumOptionGidBody**](EnumOptionsEnumOptionGidBody.md)| The enum option object to update | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**EnumOptionData**](EnumOptionData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldsApi.yaml b/docs/CustomFieldsApi.yaml deleted file mode 100644 index c6a9ccf7..00000000 --- a/docs/CustomFieldsApi.yaml +++ /dev/null @@ -1,174 +0,0 @@ -CustomFieldsApi: - create_custom_field: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.CustomFieldsApi(api_client) - body = asana.CustomFieldsBody({"param1": "value1", "param2": "value2",}) # CustomFieldsBody | The custom field object to create. - opt_fields = ["asana_created_field","created_by","created_by.name","currency_code","custom_label","custom_label_position","date_value","date_value.date","date_value.date_time","description","display_value","enabled","enum_options","enum_options.color","enum_options.enabled","enum_options.name","enum_value","enum_value.color","enum_value.enabled","enum_value.name","format","has_notifications_enabled","is_formula_field","is_global_to_workspace","is_value_read_only","multi_enum_values","multi_enum_values.color","multi_enum_values.enabled","multi_enum_values.name","name","number_value","people_value","people_value.name","precision","resource_subtype","text_value","type"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a custom field - api_response = api_instance.create_custom_field(body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling CustomFieldsApi->create_custom_field: %s\n" % e) - create_enum_option_for_custom_field: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.CustomFieldsApi(api_client) - custom_field_gid = '12345' # str | Globally unique identifier for the custom field. - body = asana.CustomFieldGidEnumOptionsBody({"param1": "value1", "param2": "value2",}) # CustomFieldGidEnumOptionsBody | The enum option object to create. (optional) - opt_fields = ["color","enabled","name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create an enum option - api_response = api_instance.create_enum_option_for_custom_field(custom_field_gid, body=body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling CustomFieldsApi->create_enum_option_for_custom_field: %s\n" % e) - delete_custom_field: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.CustomFieldsApi(api_client) - custom_field_gid = '12345' # str | Globally unique identifier for the custom field. - - try: - # Delete a custom field - api_response = api_instance.delete_custom_field(custom_field_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling CustomFieldsApi->delete_custom_field: %s\n" % e) - get_custom_field: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.CustomFieldsApi(api_client) - custom_field_gid = '12345' # str | Globally unique identifier for the custom field. - opt_fields = ["asana_created_field","created_by","created_by.name","currency_code","custom_label","custom_label_position","date_value","date_value.date","date_value.date_time","description","display_value","enabled","enum_options","enum_options.color","enum_options.enabled","enum_options.name","enum_value","enum_value.color","enum_value.enabled","enum_value.name","format","has_notifications_enabled","is_formula_field","is_global_to_workspace","is_value_read_only","multi_enum_values","multi_enum_values.color","multi_enum_values.enabled","multi_enum_values.name","name","number_value","people_value","people_value.name","precision","resource_subtype","text_value","type"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a custom field - api_response = api_instance.get_custom_field(custom_field_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling CustomFieldsApi->get_custom_field: %s\n" % e) - get_custom_fields_for_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.CustomFieldsApi(api_client) - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["asana_created_field","created_by","created_by.name","currency_code","custom_label","custom_label_position","date_value","date_value.date","date_value.date_time","description","display_value","enabled","enum_options","enum_options.color","enum_options.enabled","enum_options.name","enum_value","enum_value.color","enum_value.enabled","enum_value.name","format","has_notifications_enabled","is_formula_field","is_global_to_workspace","is_value_read_only","multi_enum_values","multi_enum_values.color","multi_enum_values.enabled","multi_enum_values.name","name","number_value","offset","path","people_value","people_value.name","precision","resource_subtype","text_value","type","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a workspace's custom fields - api_response = api_instance.get_custom_fields_for_workspace(workspace_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling CustomFieldsApi->get_custom_fields_for_workspace: %s\n" % e) - insert_enum_option_for_custom_field: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.CustomFieldsApi(api_client) - custom_field_gid = '12345' # str | Globally unique identifier for the custom field. - body = asana.EnumOptionsInsertBody({"param1": "value1", "param2": "value2",}) # EnumOptionsInsertBody | The enum option object to create. (optional) - opt_fields = ["color","enabled","name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Reorder a custom field's enum - api_response = api_instance.insert_enum_option_for_custom_field(custom_field_gid, body=body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling CustomFieldsApi->insert_enum_option_for_custom_field: %s\n" % e) - update_custom_field: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.CustomFieldsApi(api_client) - custom_field_gid = '12345' # str | Globally unique identifier for the custom field. - body = asana.CustomFieldsCustomFieldGidBody({"param1": "value1", "param2": "value2",}) # CustomFieldsCustomFieldGidBody | The custom field object with all updated properties. (optional) - opt_fields = ["asana_created_field","created_by","created_by.name","currency_code","custom_label","custom_label_position","date_value","date_value.date","date_value.date_time","description","display_value","enabled","enum_options","enum_options.color","enum_options.enabled","enum_options.name","enum_value","enum_value.color","enum_value.enabled","enum_value.name","format","has_notifications_enabled","is_formula_field","is_global_to_workspace","is_value_read_only","multi_enum_values","multi_enum_values.color","multi_enum_values.enabled","multi_enum_values.name","name","number_value","people_value","people_value.name","precision","resource_subtype","text_value","type"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a custom field - api_response = api_instance.update_custom_field(custom_field_gid, body=body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling CustomFieldsApi->update_custom_field: %s\n" % e) - update_enum_option: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.CustomFieldsApi(api_client) - enum_option_gid = '124578' # str | Globally unique identifier for the enum option. - body = asana.EnumOptionsEnumOptionGidBody({"param1": "value1", "param2": "value2",}) # EnumOptionsEnumOptionGidBody | The enum option object to update (optional) - opt_fields = ["color","enabled","name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update an enum option - api_response = api_instance.update_enum_option(enum_option_gid, body=body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling CustomFieldsApi->update_enum_option: %s\n" % e) diff --git a/docs/CustomFieldsBody.md b/docs/CustomFieldsBody.md deleted file mode 100644 index 32f1638d..00000000 --- a/docs/CustomFieldsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# CustomFieldsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**CustomFieldRequest**](CustomFieldRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/CustomFieldsCustomFieldGidBody.md b/docs/CustomFieldsCustomFieldGidBody.md deleted file mode 100644 index a843cf24..00000000 --- a/docs/CustomFieldsCustomFieldGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# CustomFieldsCustomFieldGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**CustomFieldRequest**](CustomFieldRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/DateVariableCompact.md b/docs/DateVariableCompact.md deleted file mode 100644 index 33fad87a..00000000 --- a/docs/DateVariableCompact.md +++ /dev/null @@ -1,11 +0,0 @@ -# DateVariableCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the date field in the project template. A value of `1` refers to the project start date, while `2` refers to the project due date. | [optional] -**name** | **str** | The name of the date variable. | [optional] -**description** | **str** | The description of what the date variable is used for when instantiating a project. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/DateVariableRequest.md b/docs/DateVariableRequest.md deleted file mode 100644 index 1011e169..00000000 --- a/docs/DateVariableRequest.md +++ /dev/null @@ -1,10 +0,0 @@ -# DateVariableRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the date field in the project template. A value of `1` refers to the project start date, while `2` refers to the project due date. | [optional] -**value** | **datetime** | The date with which the date variable should be replaced when instantiating a project. This takes a date with `YYYY-MM-DD` format. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EmptyResponse.md b/docs/EmptyResponse.md deleted file mode 100644 index 10bb0a97..00000000 --- a/docs/EmptyResponse.md +++ /dev/null @@ -1,8 +0,0 @@ -# EmptyResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EmptyResponseData.md b/docs/EmptyResponseData.md deleted file mode 100644 index 5ef373cd..00000000 --- a/docs/EmptyResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# EmptyResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**EmptyResponse**](EmptyResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EnumOption.md b/docs/EnumOption.md deleted file mode 100644 index 923f16ac..00000000 --- a/docs/EnumOption.md +++ /dev/null @@ -1,13 +0,0 @@ -# EnumOption - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the enum option. | [optional] -**enabled** | **bool** | Whether or not the enum option is a selectable value for the custom field. | [optional] -**color** | **str** | The color of the enum option. Defaults to ‘none’. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EnumOptionBase.md b/docs/EnumOptionBase.md deleted file mode 100644 index 81cb3851..00000000 --- a/docs/EnumOptionBase.md +++ /dev/null @@ -1,13 +0,0 @@ -# EnumOptionBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the enum option. | [optional] -**enabled** | **bool** | Whether or not the enum option is a selectable value for the custom field. | [optional] -**color** | **str** | The color of the enum option. Defaults to ‘none’. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EnumOptionData.md b/docs/EnumOptionData.md deleted file mode 100644 index 4f5583c5..00000000 --- a/docs/EnumOptionData.md +++ /dev/null @@ -1,9 +0,0 @@ -# EnumOptionData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**EnumOption**](EnumOption.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EnumOptionInsertRequest.md b/docs/EnumOptionInsertRequest.md deleted file mode 100644 index 2638f49c..00000000 --- a/docs/EnumOptionInsertRequest.md +++ /dev/null @@ -1,11 +0,0 @@ -# EnumOptionInsertRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**enum_option** | **str** | The gid of the enum option to relocate. | -**before_enum_option** | **str** | An existing enum option within this custom field before which the new enum option should be inserted. Cannot be provided together with after_enum_option. | [optional] -**after_enum_option** | **str** | An existing enum option within this custom field after which the new enum option should be inserted. Cannot be provided together with before_enum_option. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EnumOptionRequest.md b/docs/EnumOptionRequest.md deleted file mode 100644 index 61a89da3..00000000 --- a/docs/EnumOptionRequest.md +++ /dev/null @@ -1,15 +0,0 @@ -# EnumOptionRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the enum option. | [optional] -**enabled** | **bool** | Whether or not the enum option is a selectable value for the custom field. | [optional] -**color** | **str** | The color of the enum option. Defaults to ‘none’. | [optional] -**insert_before** | **str** | An existing enum option within this custom field before which the new enum option should be inserted. Cannot be provided together with after_enum_option. | [optional] -**insert_after** | **str** | An existing enum option within this custom field after which the new enum option should be inserted. Cannot be provided together with before_enum_option. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EnumOptionsEnumOptionGidBody.md b/docs/EnumOptionsEnumOptionGidBody.md deleted file mode 100644 index 77b63fac..00000000 --- a/docs/EnumOptionsEnumOptionGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# EnumOptionsEnumOptionGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**EnumOptionBase**](EnumOptionBase.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EnumOptionsInsertBody.md b/docs/EnumOptionsInsertBody.md deleted file mode 100644 index 7da2e3db..00000000 --- a/docs/EnumOptionsInsertBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# EnumOptionsInsertBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**EnumOptionInsertRequest**](EnumOptionInsertRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/Error.md b/docs/Error.md deleted file mode 100644 index 292e8f2c..00000000 --- a/docs/Error.md +++ /dev/null @@ -1,11 +0,0 @@ -# Error - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**message** | **str** | Message providing more detail about the error that occurred, if available. | [optional] -**help** | **str** | Additional information directing developers to resources on how to address and fix the problem, if available. | [optional] -**phrase** | **str** | *500 errors only*. A unique error phrase which can be used when contacting developer support to help identify the exact occurrence of the problem in Asana’s logs. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ErrorResponse.md b/docs/ErrorResponse.md deleted file mode 100644 index 2538de5a..00000000 --- a/docs/ErrorResponse.md +++ /dev/null @@ -1,9 +0,0 @@ -# ErrorResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**errors** | [**list[ErrorResponseErrors]**](ErrorResponseErrors.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ErrorResponseErrors.md b/docs/ErrorResponseErrors.md deleted file mode 100644 index 4d98efde..00000000 --- a/docs/ErrorResponseErrors.md +++ /dev/null @@ -1,11 +0,0 @@ -# ErrorResponseErrors - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**message** | **str** | Message providing more detail about the error that occurred, if available. | [optional] -**help** | **str** | Additional information directing developers to resources on how to address and fix the problem, if available. | [optional] -**phrase** | **str** | *500 errors only*. A unique error phrase which can be used when contacting developer support to help identify the exact occurrence of the problem in Asana’s logs. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EventResponse.md b/docs/EventResponse.md deleted file mode 100644 index 2e9a201a..00000000 --- a/docs/EventResponse.md +++ /dev/null @@ -1,15 +0,0 @@ -# EventResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**user** | [**EventResponseUser**](EventResponseUser.md) | | [optional] -**resource** | [**EventResponseResource**](EventResponseResource.md) | | [optional] -**type** | **str** | *Deprecated: Refer to the resource_type of the resource.* The type of the resource that generated the event. | [optional] -**action** | **str** | The type of action taken on the **resource** that triggered the event. This can be one of `changed`, `added`, `removed`, `deleted`, or `undeleted` depending on the nature of the event. | [optional] -**parent** | [**EventResponseParent**](EventResponseParent.md) | | [optional] -**created_at** | **datetime** | The timestamp when the event occurred. | [optional] -**change** | [**EventResponseChange**](EventResponseChange.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EventResponseArray.md b/docs/EventResponseArray.md deleted file mode 100644 index 3f8d143d..00000000 --- a/docs/EventResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# EventResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[EventResponse]**](EventResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EventResponseChange.md b/docs/EventResponseChange.md deleted file mode 100644 index 72fa02a0..00000000 --- a/docs/EventResponseChange.md +++ /dev/null @@ -1,13 +0,0 @@ -# EventResponseChange - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**field** | **str** | The name of the field that has changed in the resource. | [optional] -**action** | **str** | The type of action taken on the **field** which has been changed. This can be one of `changed`, `added`, or `removed` depending on the nature of the change. | [optional] -**new_value** | **object** | *Conditional.* This property is only present when the value of the event's `change.action` is `changed` _and_ the `new_value` is an Asana resource. This will be only the `gid` and `resource_type` of the resource when the events come from webhooks; this will be the compact representation (and can have fields expanded with [opt_fields](/docs/inputoutput-options)) when using the [get events](/reference/getevents) endpoint. | [optional] -**added_value** | **object** | *Conditional.* This property is only present when the value of the event's `change.action` is `added` _and_ the `added_value` is an Asana resource. This will be only the `gid` and `resource_type` of the resource when the events come from webhooks; this will be the compact representation (and can have fields expanded with [opt_fields](/docs/inputoutput-options)) when using the [get events](/reference/getevents) endpoint. | [optional] -**removed_value** | **object** | *Conditional.* This property is only present when the value of the event's `change.action` is `removed` _and_ the `removed_value` is an Asana resource. This will be only the `gid` and `resource_type` of the resource when the events come from webhooks; this will be the compact representation (and can have fields expanded with [opt_fields](/docs/inputoutput-options)) when using the [get events](/reference/getevents) endpoint. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EventResponseParent.md b/docs/EventResponseParent.md deleted file mode 100644 index 657eb4ff..00000000 --- a/docs/EventResponseParent.md +++ /dev/null @@ -1,11 +0,0 @@ -# EventResponseParent - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the object. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EventResponseResource.md b/docs/EventResponseResource.md deleted file mode 100644 index e2932417..00000000 --- a/docs/EventResponseResource.md +++ /dev/null @@ -1,11 +0,0 @@ -# EventResponseResource - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the object. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EventResponseUser.md b/docs/EventResponseUser.md deleted file mode 100644 index 02daeeea..00000000 --- a/docs/EventResponseUser.md +++ /dev/null @@ -1,11 +0,0 @@ -# EventResponseUser - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | *Read-only except when same user as requester*. The user’s name. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/EventsApi.md b/docs/EventsApi.md deleted file mode 100644 index 905f3b45..00000000 --- a/docs/EventsApi.md +++ /dev/null @@ -1,63 +0,0 @@ -# asana.EventsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**get_events**](EventsApi.md#get_events) | **GET** /events | Get events on a resource - -# **get_events** -> EventResponseArray get_events(resource, sync=sync, opt_fields=opt_fields) - -Get events on a resource - -Returns the full record for all events that have occurred since the sync token was created. A `GET` request to the endpoint `/[path_to_resource]/events` can be made in lieu of including the resource ID in the data for the request. Asana limits a single sync token to 100 events. If more than 100 events exist for a given resource, `has_more: true` will be returned in the response, indicating that there are more events to pull. *Note: The resource returned will be the resource that triggered the event. This may be different from the one that the events were requested for. For example, a subscription to a project will contain events for tasks contained within the project.* - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.EventsApi(api_client) -resource = '12345' # str | A resource ID to subscribe to. The resource can be a task or project. -sync = 'de4774f6915eae04714ca93bb2f5ee81' # str | A sync token received from the last request, or none on first sync. Events will be returned from the point in time that the sync token was generated. *Note: On your first request, omit the sync token. The response will be the same as for an expired sync token, and will include a new valid sync token.If the sync token is too old (which may happen from time to time) the API will return a `412 Precondition Failed` error, and include a fresh sync token in the response.* (optional) -opt_fields = ["action","change","change.action","change.added_value","change.field","change.new_value","change.removed_value","created_at","parent","parent.name","resource","resource.name","type","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get events on a resource - api_response = api_instance.get_events(resource, sync=sync, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling EventsApi->get_events: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **resource** | **str**| A resource ID to subscribe to. The resource can be a task or project. | - **sync** | **str**| A sync token received from the last request, or none on first sync. Events will be returned from the point in time that the sync token was generated. *Note: On your first request, omit the sync token. The response will be the same as for an expired sync token, and will include a new valid sync token.If the sync token is too old (which may happen from time to time) the API will return a `412 Precondition Failed` error, and include a fresh sync token in the response.* | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**EventResponseArray**](EventResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/EventsApi.yaml b/docs/EventsApi.yaml deleted file mode 100644 index c6e27a7a..00000000 --- a/docs/EventsApi.yaml +++ /dev/null @@ -1,23 +0,0 @@ -EventsApi: - get_events: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.EventsApi(api_client) - resource = '12345' # str | A resource ID to subscribe to. The resource can be a task or project. - sync = 'de4774f6915eae04714ca93bb2f5ee81' # str | A sync token received from the last request, or none on first sync. Events will be returned from the point in time that the sync token was generated. *Note: On your first request, omit the sync token. The response will be the same as for an expired sync token, and will include a new valid sync token.If the sync token is too old (which may happen from time to time) the API will return a `412 Precondition Failed` error, and include a fresh sync token in the response.* (optional) - opt_fields = ["action","change","change.action","change.added_value","change.field","change.new_value","change.removed_value","created_at","parent","parent.name","resource","resource.name","type","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get events on a resource - api_response = api_instance.get_events(resource, sync=sync, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling EventsApi->get_events: %s\n" % e) diff --git a/docs/GoalAddSubgoalRequest.md b/docs/GoalAddSubgoalRequest.md deleted file mode 100644 index 07136c5b..00000000 --- a/docs/GoalAddSubgoalRequest.md +++ /dev/null @@ -1,11 +0,0 @@ -# GoalAddSubgoalRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**subgoal** | **str** | The goal gid to add as subgoal to a parent goal | -**insert_before** | **str** | An id of a subgoal of this parent goal. The new subgoal will be added before the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. | [optional] -**insert_after** | **str** | An id of a subgoal of this parent goal. The new subgoal will be added after the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalAddSupportingRelationshipRequest.md b/docs/GoalAddSupportingRelationshipRequest.md deleted file mode 100644 index c1371080..00000000 --- a/docs/GoalAddSupportingRelationshipRequest.md +++ /dev/null @@ -1,12 +0,0 @@ -# GoalAddSupportingRelationshipRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**supporting_resource** | **str** | The gid of the supporting resource to add to the parent goal. Must be the gid of a goal, project, or portfolio. | -**insert_before** | **str** | An id of a subgoal of this parent goal. The new subgoal will be added before the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. Currently only supported when adding a subgoal. | [optional] -**insert_after** | **str** | An id of a subgoal of this parent goal. The new subgoal will be added after the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. Currently only supported when adding a subgoal. | [optional] -**contribution_weight** | **float** | The weight that the supporting resource's progress will contribute to the supported goal's progress. This can only be 0 or 1. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalAddSupportingWorkRequest.md b/docs/GoalAddSupportingWorkRequest.md deleted file mode 100644 index b264afa3..00000000 --- a/docs/GoalAddSupportingWorkRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalAddSupportingWorkRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**supporting_work** | **str** | The project/portfolio gid to add as supporting work for a goal | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalBase.md b/docs/GoalBase.md deleted file mode 100644 index 031acb1f..00000000 --- a/docs/GoalBase.md +++ /dev/null @@ -1,17 +0,0 @@ -# GoalBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the goal. | [optional] -**html_notes** | **str** | The notes of the goal with formatting as HTML. | [optional] -**notes** | **str** | Free-form textual information associated with the goal (i.e. its description). | [optional] -**due_on** | **str** | The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. | [optional] -**start_on** | **str** | The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. | [optional] -**is_workspace_level** | **bool** | *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. | [optional] -**liked** | **bool** | True if the goal is liked by the authorized user, false if not. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalCompact.md b/docs/GoalCompact.md deleted file mode 100644 index a1aa3d15..00000000 --- a/docs/GoalCompact.md +++ /dev/null @@ -1,12 +0,0 @@ -# GoalCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the goal. | [optional] -**owner** | [**CustomFieldResponseCreatedBy**](CustomFieldResponseCreatedBy.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalGidAddFollowersBody.md b/docs/GoalGidAddFollowersBody.md deleted file mode 100644 index 9aec52e4..00000000 --- a/docs/GoalGidAddFollowersBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalGidAddFollowersBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskAddFollowersRequest**](TaskAddFollowersRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalGidAddSupportingRelationshipBody.md b/docs/GoalGidAddSupportingRelationshipBody.md deleted file mode 100644 index cb09e617..00000000 --- a/docs/GoalGidAddSupportingRelationshipBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalGidAddSupportingRelationshipBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**GoalAddSupportingRelationshipRequest**](GoalAddSupportingRelationshipRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalGidRemoveFollowersBody.md b/docs/GoalGidRemoveFollowersBody.md deleted file mode 100644 index dde144a6..00000000 --- a/docs/GoalGidRemoveFollowersBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalGidRemoveFollowersBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskAddFollowersRequest**](TaskAddFollowersRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalGidRemoveSupportingRelationshipBody.md b/docs/GoalGidRemoveSupportingRelationshipBody.md deleted file mode 100644 index 43905aff..00000000 --- a/docs/GoalGidRemoveSupportingRelationshipBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalGidRemoveSupportingRelationshipBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**GoalRemoveSupportingRelationshipRequest**](GoalRemoveSupportingRelationshipRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalGidSetMetricBody.md b/docs/GoalGidSetMetricBody.md deleted file mode 100644 index e30fdc0f..00000000 --- a/docs/GoalGidSetMetricBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalGidSetMetricBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**GoalMetricRequest**](GoalMetricRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalGidSetMetricCurrentValueBody.md b/docs/GoalGidSetMetricCurrentValueBody.md deleted file mode 100644 index e278c73a..00000000 --- a/docs/GoalGidSetMetricCurrentValueBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalGidSetMetricCurrentValueBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**GoalMetricCurrentValueRequest**](GoalMetricCurrentValueRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalMembershipBase.md b/docs/GoalMembershipBase.md deleted file mode 100644 index c57e0dde..00000000 --- a/docs/GoalMembershipBase.md +++ /dev/null @@ -1,15 +0,0 @@ -# GoalMembershipBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**resource_subtype** | **str** | The type of membership. | [optional] -**member** | [**MembershipCompactMember**](MembershipCompactMember.md) | | [optional] -**parent** | [**MembershipCompactParent**](MembershipCompactParent.md) | | [optional] -**role** | **str** | Describes if the member is a commenter or editor in goal. | [optional] -**goal** | [**MembershipCompactGoal**](MembershipCompactGoal.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalMembershipBaseGoal.md b/docs/GoalMembershipBaseGoal.md deleted file mode 100644 index a927477e..00000000 --- a/docs/GoalMembershipBaseGoal.md +++ /dev/null @@ -1,12 +0,0 @@ -# GoalMembershipBaseGoal - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the goal. | [optional] -**owner** | [**CustomFieldResponseCreatedBy**](CustomFieldResponseCreatedBy.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalMembershipCompact.md b/docs/GoalMembershipCompact.md deleted file mode 100644 index 42430748..00000000 --- a/docs/GoalMembershipCompact.md +++ /dev/null @@ -1,17 +0,0 @@ -# GoalMembershipCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**resource_subtype** | **str** | The type of membership. | [optional] -**member** | [**MembershipCompactMember**](MembershipCompactMember.md) | | [optional] -**parent** | [**MembershipCompactParent**](MembershipCompactParent.md) | | [optional] -**role** | **str** | Describes if the member is a commenter or editor in goal. | [optional] -**goal** | [**MembershipCompactGoal**](MembershipCompactGoal.md) | | [optional] -**is_commenter** | **bool** | *Deprecated: new integrations should prefer the `role` field.* Describes if the member is comment only in goal. | [optional] -**is_editor** | **bool** | *Deprecated: new integrations should prefer the `role` field.* Describes if the member is editor in goal. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalMembershipResponse.md b/docs/GoalMembershipResponse.md deleted file mode 100644 index 6c63fb62..00000000 --- a/docs/GoalMembershipResponse.md +++ /dev/null @@ -1,17 +0,0 @@ -# GoalMembershipResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**resource_subtype** | **str** | The type of membership. | [optional] -**member** | [**MembershipCompactMember**](MembershipCompactMember.md) | | [optional] -**parent** | [**MembershipCompactParent**](MembershipCompactParent.md) | | [optional] -**role** | **str** | Describes if the member is a commenter or editor in goal. | [optional] -**goal** | [**MembershipCompactGoal**](MembershipCompactGoal.md) | | [optional] -**user** | [**GoalMembershipResponseUser**](GoalMembershipResponseUser.md) | | [optional] -**workspace** | [**GoalMembershipResponseWorkspace**](GoalMembershipResponseWorkspace.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalMembershipResponseUser.md b/docs/GoalMembershipResponseUser.md deleted file mode 100644 index 670263b5..00000000 --- a/docs/GoalMembershipResponseUser.md +++ /dev/null @@ -1,11 +0,0 @@ -# GoalMembershipResponseUser - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | *Read-only except when same user as requester*. The user’s name. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalMembershipResponseWorkspace.md b/docs/GoalMembershipResponseWorkspace.md deleted file mode 100644 index 53624a37..00000000 --- a/docs/GoalMembershipResponseWorkspace.md +++ /dev/null @@ -1,11 +0,0 @@ -# GoalMembershipResponseWorkspace - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the workspace. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalMetricBase.md b/docs/GoalMetricBase.md deleted file mode 100644 index 7aed1b5e..00000000 --- a/docs/GoalMetricBase.md +++ /dev/null @@ -1,19 +0,0 @@ -# GoalMetricBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**precision** | **int** | *Conditional*. Only relevant for goal metrics of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. | [optional] -**unit** | **str** | A supported unit of measure for the goal metric, or none. | [optional] -**currency_code** | **str** | ISO 4217 currency code to format this custom field. This will be null if the `unit` is not `currency`. | [optional] -**initial_number_value** | **float** | This number is the start value of a goal metric of type number. | [optional] -**target_number_value** | **float** | This number is the end value of a goal metric of type number. This number cannot equal `initial_number_value`. | [optional] -**current_number_value** | **float** | This number is the current value of a goal metric of type number. | [optional] -**current_display_value** | **str** | This string is the current value of a goal metric of type string. | [optional] -**progress_source** | **str** | This field defines how the progress value of a goal metric is being calculated. A goal's progress can be provided manually by the user, calculated automatically from contributing subgoals or projects, or managed by an integration with an external data source, such as Salesforce. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalMetricCurrentValueRequest.md b/docs/GoalMetricCurrentValueRequest.md deleted file mode 100644 index 06c94527..00000000 --- a/docs/GoalMetricCurrentValueRequest.md +++ /dev/null @@ -1,11 +0,0 @@ -# GoalMetricCurrentValueRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**current_number_value** | **float** | *Conditional*. This number is the current value of a goal metric of type number. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalMetricRequest.md b/docs/GoalMetricRequest.md deleted file mode 100644 index 9e982403..00000000 --- a/docs/GoalMetricRequest.md +++ /dev/null @@ -1,19 +0,0 @@ -# GoalMetricRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**precision** | **int** | *Conditional*. Only relevant for goal metrics of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. | [optional] -**unit** | **str** | A supported unit of measure for the goal metric, or none. | [optional] -**currency_code** | **str** | ISO 4217 currency code to format this custom field. This will be null if the `unit` is not `currency`. | [optional] -**initial_number_value** | **float** | This number is the start value of a goal metric of type number. | [optional] -**target_number_value** | **float** | This number is the end value of a goal metric of type number. This number cannot equal `initial_number_value`. | [optional] -**current_number_value** | **float** | This number is the current value of a goal metric of type number. | [optional] -**current_display_value** | **str** | This string is the current value of a goal metric of type string. | [optional] -**progress_source** | **str** | This field defines how the progress value of a goal metric is being calculated. A goal's progress can be provided manually by the user, calculated automatically from contributing subgoals or projects, or managed by an integration with an external data source, such as Salesforce. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalRelationshipBase.md b/docs/GoalRelationshipBase.md deleted file mode 100644 index f7002e05..00000000 --- a/docs/GoalRelationshipBase.md +++ /dev/null @@ -1,14 +0,0 @@ -# GoalRelationshipBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**supporting_resource** | [**GoalRelationshipBaseSupportingResource**](GoalRelationshipBaseSupportingResource.md) | | [optional] -**contribution_weight** | **float** | The weight that the supporting resource's progress contributes to the supported goal's progress. This can only be 0 or 1. | [optional] -**supported_goal** | [**GoalRelationshipBaseSupportedGoal**](GoalRelationshipBaseSupportedGoal.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalRelationshipBaseSupportedGoal.md b/docs/GoalRelationshipBaseSupportedGoal.md deleted file mode 100644 index a3c16f1d..00000000 --- a/docs/GoalRelationshipBaseSupportedGoal.md +++ /dev/null @@ -1,12 +0,0 @@ -# GoalRelationshipBaseSupportedGoal - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the goal. | [optional] -**owner** | [**CustomFieldResponseCreatedBy**](CustomFieldResponseCreatedBy.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalRelationshipBaseSupportingResource.md b/docs/GoalRelationshipBaseSupportingResource.md deleted file mode 100644 index 09bbb14f..00000000 --- a/docs/GoalRelationshipBaseSupportingResource.md +++ /dev/null @@ -1,11 +0,0 @@ -# GoalRelationshipBaseSupportingResource - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalRelationshipCompact.md b/docs/GoalRelationshipCompact.md deleted file mode 100644 index 87a8933b..00000000 --- a/docs/GoalRelationshipCompact.md +++ /dev/null @@ -1,13 +0,0 @@ -# GoalRelationshipCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**supporting_resource** | [**GoalRelationshipBaseSupportingResource**](GoalRelationshipBaseSupportingResource.md) | | [optional] -**contribution_weight** | **float** | The weight that the supporting resource's progress contributes to the supported goal's progress. This can only be 0 or 1. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalRelationshipRequest.md b/docs/GoalRelationshipRequest.md deleted file mode 100644 index 4a50e7b7..00000000 --- a/docs/GoalRelationshipRequest.md +++ /dev/null @@ -1,14 +0,0 @@ -# GoalRelationshipRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**supporting_resource** | [**GoalRelationshipBaseSupportingResource**](GoalRelationshipBaseSupportingResource.md) | | [optional] -**contribution_weight** | **float** | The weight that the supporting resource's progress contributes to the supported goal's progress. This can only be 0 or 1. | [optional] -**supported_goal** | [**GoalRelationshipBaseSupportedGoal**](GoalRelationshipBaseSupportedGoal.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalRelationshipResponse.md b/docs/GoalRelationshipResponse.md deleted file mode 100644 index 018ad087..00000000 --- a/docs/GoalRelationshipResponse.md +++ /dev/null @@ -1,14 +0,0 @@ -# GoalRelationshipResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**supporting_resource** | [**GoalRelationshipBaseSupportingResource**](GoalRelationshipBaseSupportingResource.md) | | [optional] -**contribution_weight** | **float** | The weight that the supporting resource's progress contributes to the supported goal's progress. This can only be 0 or 1. | [optional] -**supported_goal** | [**GoalRelationshipBaseSupportedGoal**](GoalRelationshipBaseSupportedGoal.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalRelationshipResponseArray.md b/docs/GoalRelationshipResponseArray.md deleted file mode 100644 index 60bb59c3..00000000 --- a/docs/GoalRelationshipResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# GoalRelationshipResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[GoalRelationshipResponse]**](GoalRelationshipResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalRelationshipResponseData.md b/docs/GoalRelationshipResponseData.md deleted file mode 100644 index 009ab1d4..00000000 --- a/docs/GoalRelationshipResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalRelationshipResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**GoalRelationshipResponse**](GoalRelationshipResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalRelationshipsApi.md b/docs/GoalRelationshipsApi.md deleted file mode 100644 index 52ce2d97..00000000 --- a/docs/GoalRelationshipsApi.md +++ /dev/null @@ -1,287 +0,0 @@ -# asana.GoalRelationshipsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**add_supporting_relationship**](GoalRelationshipsApi.md#add_supporting_relationship) | **POST** /goals/{goal_gid}/addSupportingRelationship | Add a supporting goal relationship -[**get_goal_relationship**](GoalRelationshipsApi.md#get_goal_relationship) | **GET** /goal_relationships/{goal_relationship_gid} | Get a goal relationship -[**get_goal_relationships**](GoalRelationshipsApi.md#get_goal_relationships) | **GET** /goal_relationships | Get goal relationships -[**remove_supporting_relationship**](GoalRelationshipsApi.md#remove_supporting_relationship) | **POST** /goals/{goal_gid}/removeSupportingRelationship | Removes a supporting goal relationship -[**update_goal_relationship**](GoalRelationshipsApi.md#update_goal_relationship) | **PUT** /goal_relationships/{goal_relationship_gid} | Update a goal relationship - -# **add_supporting_relationship** -> GoalRelationshipResponseData add_supporting_relationship(body, goal_gid, opt_fields=opt_fields) - -Add a supporting goal relationship - -Creates a goal relationship by adding a supporting resource to a given goal. Returns the newly created goal relationship record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalRelationshipsApi(api_client) -body = asana.GoalGidAddSupportingRelationshipBody({"param1": "value1", "param2": "value2",}) # GoalGidAddSupportingRelationshipBody | The supporting resource to be added to the goal -goal_gid = '12345' # str | Globally unique identifier for the goal. -opt_fields = ["contribution_weight","resource_subtype","supported_goal","supported_goal.name","supported_goal.owner","supported_goal.owner.name","supporting_resource","supporting_resource.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Add a supporting goal relationship - api_response = api_instance.add_supporting_relationship(body, goal_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalRelationshipsApi->add_supporting_relationship: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**GoalGidAddSupportingRelationshipBody**](GoalGidAddSupportingRelationshipBody.md)| The supporting resource to be added to the goal | - **goal_gid** | **str**| Globally unique identifier for the goal. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**GoalRelationshipResponseData**](GoalRelationshipResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_goal_relationship** -> GoalRelationshipResponseData get_goal_relationship(goal_relationship_gid, opt_fields=opt_fields) - -Get a goal relationship - -Returns the complete updated goal relationship record for a single goal relationship. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalRelationshipsApi(api_client) -goal_relationship_gid = '12345' # str | Globally unique identifier for the goal relationship. -opt_fields = ["contribution_weight","resource_subtype","supported_goal","supported_goal.name","supported_goal.owner","supported_goal.owner.name","supporting_resource","supporting_resource.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a goal relationship - api_response = api_instance.get_goal_relationship(goal_relationship_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalRelationshipsApi->get_goal_relationship: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **goal_relationship_gid** | **str**| Globally unique identifier for the goal relationship. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**GoalRelationshipResponseData**](GoalRelationshipResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_goal_relationships** -> GoalRelationshipResponseArray get_goal_relationships(supported_goal, limit=limit, offset=offset, resource_subtype=resource_subtype, opt_fields=opt_fields) - -Get goal relationships - -Returns compact goal relationship records. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalRelationshipsApi(api_client) -supported_goal = '12345' # str | Globally unique identifier for the supported goal in the goal relationship. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -resource_subtype = 'subgoal' # str | If provided, filter to goal relationships with a given resource_subtype. (optional) -opt_fields = ["contribution_weight","offset","path","resource_subtype","supported_goal","supported_goal.name","supported_goal.owner","supported_goal.owner.name","supporting_resource","supporting_resource.name","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get goal relationships - api_response = api_instance.get_goal_relationships(supported_goal, limit=limit, offset=offset, resource_subtype=resource_subtype, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalRelationshipsApi->get_goal_relationships: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **supported_goal** | **str**| Globally unique identifier for the supported goal in the goal relationship. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **resource_subtype** | **str**| If provided, filter to goal relationships with a given resource_subtype. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**GoalRelationshipResponseArray**](GoalRelationshipResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_supporting_relationship** -> EmptyResponseData remove_supporting_relationship(body, goal_gid) - -Removes a supporting goal relationship - -Removes a goal relationship for a given parent goal. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalRelationshipsApi(api_client) -body = asana.GoalGidRemoveSupportingRelationshipBody({"param1": "value1", "param2": "value2",}) # GoalGidRemoveSupportingRelationshipBody | The supporting resource to be removed from the goal -goal_gid = '12345' # str | Globally unique identifier for the goal. - -try: - # Removes a supporting goal relationship - api_response = api_instance.remove_supporting_relationship(body, goal_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalRelationshipsApi->remove_supporting_relationship: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**GoalGidRemoveSupportingRelationshipBody**](GoalGidRemoveSupportingRelationshipBody.md)| The supporting resource to be removed from the goal | - **goal_gid** | **str**| Globally unique identifier for the goal. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_goal_relationship** -> GoalRelationshipResponseData update_goal_relationship(body, goal_relationship_gid, opt_fields=opt_fields) - -Update a goal relationship - -An existing goal relationship can be updated by making a PUT request on the URL for that goal relationship. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. Returns the complete updated goal relationship record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalRelationshipsApi(api_client) -body = asana.GoalRelationshipsGoalRelationshipGidBody({"param1": "value1", "param2": "value2",}) # GoalRelationshipsGoalRelationshipGidBody | The updated fields for the goal relationship. -goal_relationship_gid = '12345' # str | Globally unique identifier for the goal relationship. -opt_fields = ["contribution_weight","resource_subtype","supported_goal","supported_goal.name","supported_goal.owner","supported_goal.owner.name","supporting_resource","supporting_resource.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a goal relationship - api_response = api_instance.update_goal_relationship(body, goal_relationship_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalRelationshipsApi->update_goal_relationship: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**GoalRelationshipsGoalRelationshipGidBody**](GoalRelationshipsGoalRelationshipGidBody.md)| The updated fields for the goal relationship. | - **goal_relationship_gid** | **str**| Globally unique identifier for the goal relationship. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**GoalRelationshipResponseData**](GoalRelationshipResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/GoalRelationshipsApi.yaml b/docs/GoalRelationshipsApi.yaml deleted file mode 100644 index 20f6c82e..00000000 --- a/docs/GoalRelationshipsApi.yaml +++ /dev/null @@ -1,111 +0,0 @@ -GoalRelationshipsApi: - add_supporting_relationship: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalRelationshipsApi(api_client) - body = asana.GoalGidAddSupportingRelationshipBody({"param1": "value1", "param2": "value2",}) # GoalGidAddSupportingRelationshipBody | The supporting resource to be added to the goal - goal_gid = '12345' # str | Globally unique identifier for the goal. - opt_fields = ["contribution_weight","resource_subtype","supported_goal","supported_goal.name","supported_goal.owner","supported_goal.owner.name","supporting_resource","supporting_resource.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Add a supporting goal relationship - api_response = api_instance.add_supporting_relationship(body, goal_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalRelationshipsApi->add_supporting_relationship: %s\n" % e) - get_goal_relationship: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalRelationshipsApi(api_client) - goal_relationship_gid = '12345' # str | Globally unique identifier for the goal relationship. - opt_fields = ["contribution_weight","resource_subtype","supported_goal","supported_goal.name","supported_goal.owner","supported_goal.owner.name","supporting_resource","supporting_resource.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a goal relationship - api_response = api_instance.get_goal_relationship(goal_relationship_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalRelationshipsApi->get_goal_relationship: %s\n" % e) - get_goal_relationships: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalRelationshipsApi(api_client) - supported_goal = '12345' # str | Globally unique identifier for the supported goal in the goal relationship. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - resource_subtype = 'subgoal' # str | If provided, filter to goal relationships with a given resource_subtype. (optional) - opt_fields = ["contribution_weight","offset","path","resource_subtype","supported_goal","supported_goal.name","supported_goal.owner","supported_goal.owner.name","supporting_resource","supporting_resource.name","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get goal relationships - api_response = api_instance.get_goal_relationships(supported_goal, limit=limit, offset=offset, resource_subtype=resource_subtype, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalRelationshipsApi->get_goal_relationships: %s\n" % e) - remove_supporting_relationship: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalRelationshipsApi(api_client) - body = asana.GoalGidRemoveSupportingRelationshipBody({"param1": "value1", "param2": "value2",}) # GoalGidRemoveSupportingRelationshipBody | The supporting resource to be removed from the goal - goal_gid = '12345' # str | Globally unique identifier for the goal. - - try: - # Removes a supporting goal relationship - api_response = api_instance.remove_supporting_relationship(body, goal_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalRelationshipsApi->remove_supporting_relationship: %s\n" % e) - update_goal_relationship: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalRelationshipsApi(api_client) - body = asana.GoalRelationshipsGoalRelationshipGidBody({"param1": "value1", "param2": "value2",}) # GoalRelationshipsGoalRelationshipGidBody | The updated fields for the goal relationship. - goal_relationship_gid = '12345' # str | Globally unique identifier for the goal relationship. - opt_fields = ["contribution_weight","resource_subtype","supported_goal","supported_goal.name","supported_goal.owner","supported_goal.owner.name","supporting_resource","supporting_resource.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a goal relationship - api_response = api_instance.update_goal_relationship(body, goal_relationship_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalRelationshipsApi->update_goal_relationship: %s\n" % e) diff --git a/docs/GoalRelationshipsGoalRelationshipGidBody.md b/docs/GoalRelationshipsGoalRelationshipGidBody.md deleted file mode 100644 index b590d197..00000000 --- a/docs/GoalRelationshipsGoalRelationshipGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalRelationshipsGoalRelationshipGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**GoalRelationshipRequest**](GoalRelationshipRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalRemoveSubgoalRequest.md b/docs/GoalRemoveSubgoalRequest.md deleted file mode 100644 index 1f656ddc..00000000 --- a/docs/GoalRemoveSubgoalRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalRemoveSubgoalRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**subgoal** | **str** | The goal gid to remove as subgoal from the parent goal | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalRemoveSupportingRelationshipRequest.md b/docs/GoalRemoveSupportingRelationshipRequest.md deleted file mode 100644 index 479a9f2e..00000000 --- a/docs/GoalRemoveSupportingRelationshipRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalRemoveSupportingRelationshipRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**supporting_resource** | **str** | The gid of the supporting resource to remove from the parent goal. Must be the gid of a goal, project, or portfolio. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalRequest.md b/docs/GoalRequest.md deleted file mode 100644 index 420b723b..00000000 --- a/docs/GoalRequest.md +++ /dev/null @@ -1,22 +0,0 @@ -# GoalRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the goal. | [optional] -**html_notes** | **str** | The notes of the goal with formatting as HTML. | [optional] -**notes** | **str** | Free-form textual information associated with the goal (i.e. its description). | [optional] -**due_on** | **str** | The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. | [optional] -**start_on** | **str** | The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. | [optional] -**is_workspace_level** | **bool** | *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. | [optional] -**liked** | **bool** | True if the goal is liked by the authorized user, false if not. | [optional] -**team** | **str** | *Conditional*. This property is only present when the `workspace` provided is an organization. | [optional] -**workspace** | **str** | The `gid` of a workspace. | [optional] -**time_period** | **str** | The `gid` of a time period. | [optional] -**owner** | **str** | The `gid` of a user. | [optional] -**followers** | **list[str]** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalRequestBase.md b/docs/GoalRequestBase.md deleted file mode 100644 index 60419d35..00000000 --- a/docs/GoalRequestBase.md +++ /dev/null @@ -1,21 +0,0 @@ -# GoalRequestBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the goal. | [optional] -**html_notes** | **str** | The notes of the goal with formatting as HTML. | [optional] -**notes** | **str** | Free-form textual information associated with the goal (i.e. its description). | [optional] -**due_on** | **str** | The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. | [optional] -**start_on** | **str** | The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. | [optional] -**is_workspace_level** | **bool** | *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. | [optional] -**liked** | **bool** | True if the goal is liked by the authorized user, false if not. | [optional] -**team** | **str** | *Conditional*. This property is only present when the `workspace` provided is an organization. | [optional] -**workspace** | **str** | The `gid` of a workspace. | [optional] -**time_period** | **str** | The `gid` of a time period. | [optional] -**owner** | **str** | The `gid` of a user. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalResponse.md b/docs/GoalResponse.md deleted file mode 100644 index 695ae5f2..00000000 --- a/docs/GoalResponse.md +++ /dev/null @@ -1,27 +0,0 @@ -# GoalResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the goal. | [optional] -**html_notes** | **str** | The notes of the goal with formatting as HTML. | [optional] -**notes** | **str** | Free-form textual information associated with the goal (i.e. its description). | [optional] -**due_on** | **str** | The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. | [optional] -**start_on** | **str** | The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. | [optional] -**is_workspace_level** | **bool** | *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. | [optional] -**liked** | **bool** | True if the goal is liked by the authorized user, false if not. | [optional] -**likes** | [**list[GoalResponseLikes]**](GoalResponseLikes.md) | Array of likes for users who have liked this goal. | [optional] -**num_likes** | **int** | The number of users who have liked this goal. | [optional] -**team** | [**GoalResponseTeam**](GoalResponseTeam.md) | | [optional] -**workspace** | [**GoalResponseWorkspace**](GoalResponseWorkspace.md) | | [optional] -**followers** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | Array of users who are members of this goal. | [optional] -**time_period** | [**GoalResponseTimePeriod**](GoalResponseTimePeriod.md) | | [optional] -**metric** | [**GoalResponseMetric**](GoalResponseMetric.md) | | [optional] -**owner** | [**CustomFieldResponseCreatedBy**](CustomFieldResponseCreatedBy.md) | | [optional] -**current_status_update** | [**GoalResponseCurrentStatusUpdate**](GoalResponseCurrentStatusUpdate.md) | | [optional] -**status** | **str** | The current status of this goal. When the goal is open, its status can be `green`, `yellow`, and `red` to reflect \"On Track\", \"At Risk\", and \"Off Track\", respectively. When the goal is closed, the value can be `missed`, `achieved`, `partial`, or `dropped`. *Note* you can only write to this property if `metric` is set. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalResponseArray.md b/docs/GoalResponseArray.md deleted file mode 100644 index 5bddd98d..00000000 --- a/docs/GoalResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# GoalResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[GoalResponse]**](GoalResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalResponseCurrentStatusUpdate.md b/docs/GoalResponseCurrentStatusUpdate.md deleted file mode 100644 index acdb83f5..00000000 --- a/docs/GoalResponseCurrentStatusUpdate.md +++ /dev/null @@ -1,12 +0,0 @@ -# GoalResponseCurrentStatusUpdate - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the status update. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalResponseData.md b/docs/GoalResponseData.md deleted file mode 100644 index 23f30ff8..00000000 --- a/docs/GoalResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**GoalResponse**](GoalResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalResponseLikes.md b/docs/GoalResponseLikes.md deleted file mode 100644 index 09f73fd6..00000000 --- a/docs/GoalResponseLikes.md +++ /dev/null @@ -1,10 +0,0 @@ -# GoalResponseLikes - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the object, as a string. | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalResponseMetric.md b/docs/GoalResponseMetric.md deleted file mode 100644 index 55d66690..00000000 --- a/docs/GoalResponseMetric.md +++ /dev/null @@ -1,20 +0,0 @@ -# GoalResponseMetric - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**precision** | **int** | *Conditional*. Only relevant for goal metrics of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. | [optional] -**unit** | **str** | A supported unit of measure for the goal metric, or none. | [optional] -**currency_code** | **str** | ISO 4217 currency code to format this custom field. This will be null if the `unit` is not `currency`. | [optional] -**initial_number_value** | **float** | This number is the start value of a goal metric of type number. | [optional] -**target_number_value** | **float** | This number is the end value of a goal metric of type number. This number cannot equal `initial_number_value`. | [optional] -**current_number_value** | **float** | This number is the current value of a goal metric of type number. | [optional] -**current_display_value** | **str** | This string is the current value of a goal metric of type string. | [optional] -**progress_source** | **str** | This field defines how the progress value of a goal metric is being calculated. A goal's progress can be provided manually by the user, calculated automatically from contributing subgoals or projects, or managed by an integration with an external data source, such as Salesforce. | [optional] -**can_manage** | **bool** | *Conditional*. Only relevant for `progress_source` of type `external`. This boolean indicates whether the requester has the ability to update the current value of this metric. This returns `true` if the external metric was created by the requester, `false` otherwise. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalResponseTeam.md b/docs/GoalResponseTeam.md deleted file mode 100644 index 4f947173..00000000 --- a/docs/GoalResponseTeam.md +++ /dev/null @@ -1,11 +0,0 @@ -# GoalResponseTeam - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the team. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalResponseTimePeriod.md b/docs/GoalResponseTimePeriod.md deleted file mode 100644 index 04b8211f..00000000 --- a/docs/GoalResponseTimePeriod.md +++ /dev/null @@ -1,14 +0,0 @@ -# GoalResponseTimePeriod - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**end_on** | **str** | The localized end date of the time period in `YYYY-MM-DD` format. | [optional] -**start_on** | **str** | The localized start date of the time period in `YYYY-MM-DD` format. | [optional] -**period** | **str** | The cadence and index of the time period. The value is one of: `FY`, `H1`, `H2`, `Q1`, `Q2`, `Q3`, or `Q4`. | [optional] -**display_name** | **str** | A string representing the cadence code and the fiscal year. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalResponseWorkspace.md b/docs/GoalResponseWorkspace.md deleted file mode 100644 index 47fc3e7d..00000000 --- a/docs/GoalResponseWorkspace.md +++ /dev/null @@ -1,11 +0,0 @@ -# GoalResponseWorkspace - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the workspace. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalUpdateRequest.md b/docs/GoalUpdateRequest.md deleted file mode 100644 index e17845d5..00000000 --- a/docs/GoalUpdateRequest.md +++ /dev/null @@ -1,22 +0,0 @@ -# GoalUpdateRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the goal. | [optional] -**html_notes** | **str** | The notes of the goal with formatting as HTML. | [optional] -**notes** | **str** | Free-form textual information associated with the goal (i.e. its description). | [optional] -**due_on** | **str** | The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. | [optional] -**start_on** | **str** | The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. | [optional] -**is_workspace_level** | **bool** | *Conditional*. This property is only present when the `workspace` provided is an organization. Whether the goal belongs to the `workspace` (and is listed as part of the workspace’s goals) or not. If it isn’t a workspace-level goal, it is a team-level goal, and is associated with the goal’s team. | [optional] -**liked** | **bool** | True if the goal is liked by the authorized user, false if not. | [optional] -**team** | **str** | *Conditional*. This property is only present when the `workspace` provided is an organization. | [optional] -**workspace** | **str** | The `gid` of a workspace. | [optional] -**time_period** | **str** | The `gid` of a time period. | [optional] -**owner** | **str** | The `gid` of a user. | [optional] -**status** | **str** | The current status of this goal. When the goal is open, its status can be `green`, `yellow`, and `red` to reflect \"On Track\", \"At Risk\", and \"Off Track\", respectively. When the goal is closed, the value can be `missed`, `achieved`, `partial`, or `dropped`. *Note* you can only write to this property if `metric` is set. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalsApi.md b/docs/GoalsApi.md deleted file mode 100644 index a4175e5e..00000000 --- a/docs/GoalsApi.md +++ /dev/null @@ -1,569 +0,0 @@ -# asana.GoalsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**add_followers**](GoalsApi.md#add_followers) | **POST** /goals/{goal_gid}/addFollowers | Add a collaborator to a goal -[**create_goal**](GoalsApi.md#create_goal) | **POST** /goals | Create a goal -[**create_goal_metric**](GoalsApi.md#create_goal_metric) | **POST** /goals/{goal_gid}/setMetric | Create a goal metric -[**delete_goal**](GoalsApi.md#delete_goal) | **DELETE** /goals/{goal_gid} | Delete a goal -[**get_goal**](GoalsApi.md#get_goal) | **GET** /goals/{goal_gid} | Get a goal -[**get_goals**](GoalsApi.md#get_goals) | **GET** /goals | Get goals -[**get_parent_goals_for_goal**](GoalsApi.md#get_parent_goals_for_goal) | **GET** /goals/{goal_gid}/parentGoals | Get parent goals from a goal -[**remove_followers**](GoalsApi.md#remove_followers) | **POST** /goals/{goal_gid}/removeFollowers | Remove a collaborator from a goal -[**update_goal**](GoalsApi.md#update_goal) | **PUT** /goals/{goal_gid} | Update a goal -[**update_goal_metric**](GoalsApi.md#update_goal_metric) | **POST** /goals/{goal_gid}/setMetricCurrentValue | Update a goal metric - -# **add_followers** -> GoalResponseData add_followers(body, goal_gid, opt_fields=opt_fields) - -Add a collaborator to a goal - -Adds followers to a goal. Returns the goal the followers were added to. Each goal can be associated with zero or more followers in the system. Requests to add/remove followers, if successful, will return the complete updated goal record, described above. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalsApi(api_client) -body = asana.GoalGidAddFollowersBody({"param1": "value1", "param2": "value2",}) # GoalGidAddFollowersBody | The followers to be added as collaborators -goal_gid = '12345' # str | Globally unique identifier for the goal. -opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Add a collaborator to a goal - api_response = api_instance.add_followers(body, goal_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalsApi->add_followers: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**GoalGidAddFollowersBody**](GoalGidAddFollowersBody.md)| The followers to be added as collaborators | - **goal_gid** | **str**| Globally unique identifier for the goal. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**GoalResponseData**](GoalResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **create_goal** -> GoalResponseData create_goal(body, opt_fields=opt_fields) - -Create a goal - -Creates a new goal in a workspace or team. Returns the full record of the newly created goal. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalsApi(api_client) -body = asana.GoalsBody({"param1": "value1", "param2": "value2",}) # GoalsBody | The goal to create. -opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a goal - api_response = api_instance.create_goal(body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalsApi->create_goal: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**GoalsBody**](GoalsBody.md)| The goal to create. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**GoalResponseData**](GoalResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **create_goal_metric** -> GoalResponseData create_goal_metric(body, goal_gid, opt_fields=opt_fields) - -Create a goal metric - -Creates and adds a goal metric to a specified goal. Note that this replaces an existing goal metric if one already exists. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalsApi(api_client) -body = asana.GoalGidSetMetricBody({"param1": "value1", "param2": "value2",}) # GoalGidSetMetricBody | The goal metric to create. -goal_gid = '12345' # str | Globally unique identifier for the goal. -opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a goal metric - api_response = api_instance.create_goal_metric(body, goal_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalsApi->create_goal_metric: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**GoalGidSetMetricBody**](GoalGidSetMetricBody.md)| The goal metric to create. | - **goal_gid** | **str**| Globally unique identifier for the goal. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**GoalResponseData**](GoalResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_goal** -> EmptyResponseData delete_goal(goal_gid) - -Delete a goal - -A specific, existing goal can be deleted by making a DELETE request on the URL for that goal. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalsApi(api_client) -goal_gid = '12345' # str | Globally unique identifier for the goal. - -try: - # Delete a goal - api_response = api_instance.delete_goal(goal_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalsApi->delete_goal: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **goal_gid** | **str**| Globally unique identifier for the goal. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_goal** -> GoalResponseData get_goal(goal_gid, opt_fields=opt_fields) - -Get a goal - -Returns the complete goal record for a single goal. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalsApi(api_client) -goal_gid = '12345' # str | Globally unique identifier for the goal. -opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a goal - api_response = api_instance.get_goal(goal_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalsApi->get_goal: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **goal_gid** | **str**| Globally unique identifier for the goal. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**GoalResponseData**](GoalResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_goals** -> GoalResponseArray get_goals(portfolio=portfolio, project=project, is_workspace_level=is_workspace_level, team=team, workspace=workspace, time_periods=time_periods, limit=limit, offset=offset, opt_fields=opt_fields) - -Get goals - -Returns compact goal records. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalsApi(api_client) -portfolio = '159874' # str | Globally unique identifier for supporting portfolio. (optional) -project = '512241' # str | Globally unique identifier for supporting project. (optional) -is_workspace_level = false # bool | Filter to goals with is_workspace_level set to query value. Must be used with the workspace parameter. (optional) -team = '31326' # str | Globally unique identifier for the team. (optional) -workspace = '31326' # str | Globally unique identifier for the workspace. (optional) -time_periods = ['221693,506165'] # list[str] | Globally unique identifiers for the time periods. (optional) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","offset","owner","owner.name","path","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get goals - api_response = api_instance.get_goals(portfolio=portfolio, project=project, is_workspace_level=is_workspace_level, team=team, workspace=workspace, time_periods=time_periods, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalsApi->get_goals: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **portfolio** | **str**| Globally unique identifier for supporting portfolio. | [optional] - **project** | **str**| Globally unique identifier for supporting project. | [optional] - **is_workspace_level** | **bool**| Filter to goals with is_workspace_level set to query value. Must be used with the workspace parameter. | [optional] - **team** | **str**| Globally unique identifier for the team. | [optional] - **workspace** | **str**| Globally unique identifier for the workspace. | [optional] - **time_periods** | [**list[str]**](str.md)| Globally unique identifiers for the time periods. | [optional] - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**GoalResponseArray**](GoalResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_parent_goals_for_goal** -> GoalResponseArray get_parent_goals_for_goal(goal_gid, opt_fields=opt_fields) - -Get parent goals from a goal - -Returns a compact representation of all of the parent goals of a goal. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalsApi(api_client) -goal_gid = '12345' # str | Globally unique identifier for the goal. -opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get parent goals from a goal - api_response = api_instance.get_parent_goals_for_goal(goal_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalsApi->get_parent_goals_for_goal: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **goal_gid** | **str**| Globally unique identifier for the goal. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**GoalResponseArray**](GoalResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_followers** -> GoalResponseData remove_followers(body, goal_gid, opt_fields=opt_fields) - -Remove a collaborator from a goal - -Removes followers from a goal. Returns the goal the followers were removed from. Each goal can be associated with zero or more followers in the system. Requests to add/remove followers, if successful, will return the complete updated goal record, described above. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalsApi(api_client) -body = asana.GoalGidRemoveFollowersBody({"param1": "value1", "param2": "value2",}) # GoalGidRemoveFollowersBody | The followers to be removed as collaborators -goal_gid = '12345' # str | Globally unique identifier for the goal. -opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Remove a collaborator from a goal - api_response = api_instance.remove_followers(body, goal_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalsApi->remove_followers: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**GoalGidRemoveFollowersBody**](GoalGidRemoveFollowersBody.md)| The followers to be removed as collaborators | - **goal_gid** | **str**| Globally unique identifier for the goal. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**GoalResponseData**](GoalResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_goal** -> GoalResponseData update_goal(body, goal_gid, opt_fields=opt_fields) - -Update a goal - -An existing goal can be updated by making a PUT request on the URL for that goal. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. Returns the complete updated goal record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalsApi(api_client) -body = asana.GoalsGoalGidBody({"param1": "value1", "param2": "value2",}) # GoalsGoalGidBody | The updated fields for the goal. -goal_gid = '12345' # str | Globally unique identifier for the goal. -opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a goal - api_response = api_instance.update_goal(body, goal_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalsApi->update_goal: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**GoalsGoalGidBody**](GoalsGoalGidBody.md)| The updated fields for the goal. | - **goal_gid** | **str**| Globally unique identifier for the goal. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**GoalResponseData**](GoalResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_goal_metric** -> GoalResponseData update_goal_metric(body, goal_gid, opt_fields=opt_fields) - -Update a goal metric - -Updates a goal's existing metric's `current_number_value` if one exists, otherwise responds with a 400 status code. Returns the complete updated goal metric record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.GoalsApi(api_client) -body = asana.GoalGidSetMetricCurrentValueBody({"param1": "value1", "param2": "value2",}) # GoalGidSetMetricCurrentValueBody | The updated fields for the goal metric. -goal_gid = '12345' # str | Globally unique identifier for the goal. -opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a goal metric - api_response = api_instance.update_goal_metric(body, goal_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling GoalsApi->update_goal_metric: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**GoalGidSetMetricCurrentValueBody**](GoalGidSetMetricCurrentValueBody.md)| The updated fields for the goal metric. | - **goal_gid** | **str**| Globally unique identifier for the goal. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**GoalResponseData**](GoalResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/GoalsApi.yaml b/docs/GoalsApi.yaml deleted file mode 100644 index 3fbbd149..00000000 --- a/docs/GoalsApi.yaml +++ /dev/null @@ -1,222 +0,0 @@ -GoalsApi: - add_followers: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalsApi(api_client) - body = asana.GoalGidAddFollowersBody({"param1": "value1", "param2": "value2",}) # GoalGidAddFollowersBody | The followers to be added as collaborators - goal_gid = '12345' # str | Globally unique identifier for the goal. - opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Add a collaborator to a goal - api_response = api_instance.add_followers(body, goal_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalsApi->add_followers: %s\n" % e) - create_goal: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalsApi(api_client) - body = asana.GoalsBody({"param1": "value1", "param2": "value2",}) # GoalsBody | The goal to create. - opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a goal - api_response = api_instance.create_goal(body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalsApi->create_goal: %s\n" % e) - create_goal_metric: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalsApi(api_client) - body = asana.GoalGidSetMetricBody({"param1": "value1", "param2": "value2",}) # GoalGidSetMetricBody | The goal metric to create. - goal_gid = '12345' # str | Globally unique identifier for the goal. - opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a goal metric - api_response = api_instance.create_goal_metric(body, goal_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalsApi->create_goal_metric: %s\n" % e) - delete_goal: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalsApi(api_client) - goal_gid = '12345' # str | Globally unique identifier for the goal. - - try: - # Delete a goal - api_response = api_instance.delete_goal(goal_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalsApi->delete_goal: %s\n" % e) - get_goal: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalsApi(api_client) - goal_gid = '12345' # str | Globally unique identifier for the goal. - opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a goal - api_response = api_instance.get_goal(goal_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalsApi->get_goal: %s\n" % e) - get_goals: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalsApi(api_client) - portfolio = '159874' # str | Globally unique identifier for supporting portfolio. (optional) - project = '512241' # str | Globally unique identifier for supporting project. (optional) - is_workspace_level = false # bool | Filter to goals with is_workspace_level set to query value. Must be used with the workspace parameter. (optional) - team = '31326' # str | Globally unique identifier for the team. (optional) - workspace = '31326' # str | Globally unique identifier for the workspace. (optional) - time_periods = ['221693,506165'] # list[str] | Globally unique identifiers for the time periods. (optional) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","offset","owner","owner.name","path","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get goals - api_response = api_instance.get_goals(portfolio=portfolio, project=project, is_workspace_level=is_workspace_level, team=team, workspace=workspace, time_periods=time_periods, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalsApi->get_goals: %s\n" % e) - get_parent_goals_for_goal: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalsApi(api_client) - goal_gid = '12345' # str | Globally unique identifier for the goal. - opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get parent goals from a goal - api_response = api_instance.get_parent_goals_for_goal(goal_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalsApi->get_parent_goals_for_goal: %s\n" % e) - remove_followers: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalsApi(api_client) - body = asana.GoalGidRemoveFollowersBody({"param1": "value1", "param2": "value2",}) # GoalGidRemoveFollowersBody | The followers to be removed as collaborators - goal_gid = '12345' # str | Globally unique identifier for the goal. - opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Remove a collaborator from a goal - api_response = api_instance.remove_followers(body, goal_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalsApi->remove_followers: %s\n" % e) - update_goal: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalsApi(api_client) - body = asana.GoalsGoalGidBody({"param1": "value1", "param2": "value2",}) # GoalsGoalGidBody | The updated fields for the goal. - goal_gid = '12345' # str | Globally unique identifier for the goal. - opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a goal - api_response = api_instance.update_goal(body, goal_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalsApi->update_goal: %s\n" % e) - update_goal_metric: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.GoalsApi(api_client) - body = asana.GoalGidSetMetricCurrentValueBody({"param1": "value1", "param2": "value2",}) # GoalGidSetMetricCurrentValueBody | The updated fields for the goal metric. - goal_gid = '12345' # str | Globally unique identifier for the goal. - opt_fields = ["current_status_update","current_status_update.resource_subtype","current_status_update.title","due_on","followers","followers.name","html_notes","is_workspace_level","liked","likes","likes.user","likes.user.name","metric","metric.can_manage","metric.currency_code","metric.current_display_value","metric.current_number_value","metric.initial_number_value","metric.precision","metric.progress_source","metric.resource_subtype","metric.target_number_value","metric.unit","name","notes","num_likes","owner","owner.name","start_on","status","team","team.name","time_period","time_period.display_name","time_period.end_on","time_period.period","time_period.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a goal metric - api_response = api_instance.update_goal_metric(body, goal_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling GoalsApi->update_goal_metric: %s\n" % e) diff --git a/docs/GoalsBody.md b/docs/GoalsBody.md deleted file mode 100644 index 768c60b9..00000000 --- a/docs/GoalsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**GoalRequest**](GoalRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/GoalsGoalGidBody.md b/docs/GoalsGoalGidBody.md deleted file mode 100644 index a38d3d51..00000000 --- a/docs/GoalsGoalGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# GoalsGoalGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**GoalUpdateRequest**](GoalUpdateRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/InlineResponse412.md b/docs/InlineResponse412.md deleted file mode 100644 index 813bbc49..00000000 --- a/docs/InlineResponse412.md +++ /dev/null @@ -1,10 +0,0 @@ -# InlineResponse412 - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**errors** | [**list[InlineResponse412Errors]**](InlineResponse412Errors.md) | | [optional] -**sync** | **str** | A sync token to be used with the next call to the /events endpoint. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/InlineResponse412Errors.md b/docs/InlineResponse412Errors.md deleted file mode 100644 index 844b42fa..00000000 --- a/docs/InlineResponse412Errors.md +++ /dev/null @@ -1,9 +0,0 @@ -# InlineResponse412Errors - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**message** | **str** | Message providing more detail about the error that occurred, if available. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/JobBase.md b/docs/JobBase.md deleted file mode 100644 index ddf55da6..00000000 --- a/docs/JobBase.md +++ /dev/null @@ -1,15 +0,0 @@ -# JobBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**status** | **str** | The current status of this job. The value is one of: `not_started`, `in_progress`, `succeeded`, or `failed`. | [optional] -**new_project** | [**JobBaseNewProject**](JobBaseNewProject.md) | | [optional] -**new_task** | [**JobBaseNewTask**](JobBaseNewTask.md) | | [optional] -**new_project_template** | [**JobBaseNewProjectTemplate**](JobBaseNewProjectTemplate.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/JobBaseNewProject.md b/docs/JobBaseNewProject.md deleted file mode 100644 index d23e6fec..00000000 --- a/docs/JobBaseNewProject.md +++ /dev/null @@ -1,11 +0,0 @@ -# JobBaseNewProject - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/JobBaseNewProjectTemplate.md b/docs/JobBaseNewProjectTemplate.md deleted file mode 100644 index b14313d5..00000000 --- a/docs/JobBaseNewProjectTemplate.md +++ /dev/null @@ -1,11 +0,0 @@ -# JobBaseNewProjectTemplate - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project template. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/JobBaseNewTask.md b/docs/JobBaseNewTask.md deleted file mode 100644 index 17f3ea54..00000000 --- a/docs/JobBaseNewTask.md +++ /dev/null @@ -1,13 +0,0 @@ -# JobBaseNewTask - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the task. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. | [optional] -**created_by** | [**AttachmentResponseParentCreatedBy**](AttachmentResponseParentCreatedBy.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/JobCompact.md b/docs/JobCompact.md deleted file mode 100644 index 9ac54137..00000000 --- a/docs/JobCompact.md +++ /dev/null @@ -1,15 +0,0 @@ -# JobCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**status** | **str** | The current status of this job. The value is one of: `not_started`, `in_progress`, `succeeded`, or `failed`. | [optional] -**new_project** | [**JobBaseNewProject**](JobBaseNewProject.md) | | [optional] -**new_task** | [**JobBaseNewTask**](JobBaseNewTask.md) | | [optional] -**new_project_template** | [**JobBaseNewProjectTemplate**](JobBaseNewProjectTemplate.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/JobResponse.md b/docs/JobResponse.md deleted file mode 100644 index 26ebc0cf..00000000 --- a/docs/JobResponse.md +++ /dev/null @@ -1,15 +0,0 @@ -# JobResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**status** | **str** | The current status of this job. The value is one of: `not_started`, `in_progress`, `succeeded`, or `failed`. | [optional] -**new_project** | [**JobBaseNewProject**](JobBaseNewProject.md) | | [optional] -**new_task** | [**JobBaseNewTask**](JobBaseNewTask.md) | | [optional] -**new_project_template** | [**JobBaseNewProjectTemplate**](JobBaseNewProjectTemplate.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/JobResponseData.md b/docs/JobResponseData.md deleted file mode 100644 index d31bdb30..00000000 --- a/docs/JobResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# JobResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**JobResponse**](JobResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/JobsApi.md b/docs/JobsApi.md deleted file mode 100644 index a199969b..00000000 --- a/docs/JobsApi.md +++ /dev/null @@ -1,61 +0,0 @@ -# asana.JobsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**get_job**](JobsApi.md#get_job) | **GET** /jobs/{job_gid} | Get a job by id - -# **get_job** -> JobResponseData get_job(job_gid, opt_fields=opt_fields) - -Get a job by id - -Returns the full record for a job. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.JobsApi(api_client) -job_gid = '12345' # str | Globally unique identifier for the job. -opt_fields = ["new_project","new_project.name","new_project_template","new_project_template.name","new_task","new_task.created_by","new_task.name","new_task.resource_subtype","resource_subtype","status"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a job by id - api_response = api_instance.get_job(job_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling JobsApi->get_job: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **job_gid** | **str**| Globally unique identifier for the job. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**JobResponseData**](JobResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/JobsApi.yaml b/docs/JobsApi.yaml deleted file mode 100644 index cbf4a3a4..00000000 --- a/docs/JobsApi.yaml +++ /dev/null @@ -1,22 +0,0 @@ -JobsApi: - get_job: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.JobsApi(api_client) - job_gid = '12345' # str | Globally unique identifier for the job. - opt_fields = ["new_project","new_project.name","new_project_template","new_project_template.name","new_task","new_task.created_by","new_task.name","new_task.resource_subtype","resource_subtype","status"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a job by id - api_response = api_instance.get_job(job_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling JobsApi->get_job: %s\n" % e) diff --git a/docs/Like.md b/docs/Like.md deleted file mode 100644 index b471aea4..00000000 --- a/docs/Like.md +++ /dev/null @@ -1,10 +0,0 @@ -# Like - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the object, as a string. | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/MemberCompact.md b/docs/MemberCompact.md deleted file mode 100644 index 817012d9..00000000 --- a/docs/MemberCompact.md +++ /dev/null @@ -1,11 +0,0 @@ -# MemberCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The type of the member (team or user) | [optional] -**name** | **str** | The name of the member | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/MembershipCompact.md b/docs/MembershipCompact.md deleted file mode 100644 index 3456fcb2..00000000 --- a/docs/MembershipCompact.md +++ /dev/null @@ -1,8 +0,0 @@ -# MembershipCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/MembershipCompactGoal.md b/docs/MembershipCompactGoal.md deleted file mode 100644 index 9176e1db..00000000 --- a/docs/MembershipCompactGoal.md +++ /dev/null @@ -1,12 +0,0 @@ -# MembershipCompactGoal - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the goal. | [optional] -**owner** | [**CustomFieldResponseCreatedBy**](CustomFieldResponseCreatedBy.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/MembershipCompactMember.md b/docs/MembershipCompactMember.md deleted file mode 100644 index 339689f5..00000000 --- a/docs/MembershipCompactMember.md +++ /dev/null @@ -1,11 +0,0 @@ -# MembershipCompactMember - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The type of the member (team or user) | [optional] -**name** | **str** | The name of the member | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/MembershipCompactParent.md b/docs/MembershipCompactParent.md deleted file mode 100644 index 417d9799..00000000 --- a/docs/MembershipCompactParent.md +++ /dev/null @@ -1,12 +0,0 @@ -# MembershipCompactParent - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the goal. | [optional] -**owner** | [**CustomFieldResponseCreatedBy**](CustomFieldResponseCreatedBy.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/MembershipRequest.md b/docs/MembershipRequest.md deleted file mode 100644 index 7c6c2a43..00000000 --- a/docs/MembershipRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# MembershipRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**is_active** | **bool** | *Optional*. Denotes if a member is active. Applies to all memberships | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/MembershipResponse.md b/docs/MembershipResponse.md deleted file mode 100644 index fe169a71..00000000 --- a/docs/MembershipResponse.md +++ /dev/null @@ -1,8 +0,0 @@ -# MembershipResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/MembershipResponseArray.md b/docs/MembershipResponseArray.md deleted file mode 100644 index cf2f4013..00000000 --- a/docs/MembershipResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# MembershipResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[MembershipResponse]**](MembershipResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/MembershipResponseData.md b/docs/MembershipResponseData.md deleted file mode 100644 index 6f31f657..00000000 --- a/docs/MembershipResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# MembershipResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**MembershipResponse**](MembershipResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/MembershipsApi.md b/docs/MembershipsApi.md deleted file mode 100644 index 6e77466d..00000000 --- a/docs/MembershipsApi.md +++ /dev/null @@ -1,225 +0,0 @@ -# asana.MembershipsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_membership**](MembershipsApi.md#create_membership) | **POST** /memberships | Create a membership -[**delete_membership**](MembershipsApi.md#delete_membership) | **DELETE** /memberships/{membership_gid} | Delete a membership -[**get_membership**](MembershipsApi.md#get_membership) | **GET** /memberships/{membership_gid} | Get a membership -[**get_memberships**](MembershipsApi.md#get_memberships) | **GET** /memberships | Get multiple memberships - -# **create_membership** -> MembershipResponseData create_membership(body=body) - -Create a membership - -Creates a new membership in a `goal`. `Teams` or `users` can be a member of `goals`. Returns the full record of the newly created membership. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.MembershipsApi(api_client) -body = asana.MembershipsBody({"param1": "value1", "param2": "value2",}) # MembershipsBody | The updated fields for the membership. (optional) - -try: - # Create a membership - api_response = api_instance.create_membership(body=body) - pprint(api_response) -except ApiException as e: - print("Exception when calling MembershipsApi->create_membership: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**MembershipsBody**](MembershipsBody.md)| The updated fields for the membership. | [optional] - -### Return type - -[**MembershipResponseData**](MembershipResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_membership** -> EmptyResponseData delete_membership(membership_gid) - -Delete a membership - -A specific, existing membership can be deleted by making a `DELETE` request on the URL for that membership. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.MembershipsApi(api_client) -membership_gid = '12345' # str | Globally unique identifier for the membership. - -try: - # Delete a membership - api_response = api_instance.delete_membership(membership_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling MembershipsApi->delete_membership: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **membership_gid** | **str**| Globally unique identifier for the membership. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_membership** -> ProjectMembershipCompactResponseData get_membership(membership_gid, opt_fields=opt_fields) - -Get a membership - -Returns compact `project_membership` record for a single membership. `GET` only supports project memberships currently - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.MembershipsApi(api_client) -membership_gid = '12345' # str | Globally unique identifier for the membership. -opt_fields = ["access_level","member","member.name","parent","parent.name","resource_subtype"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a membership - api_response = api_instance.get_membership(membership_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling MembershipsApi->get_membership: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **membership_gid** | **str**| Globally unique identifier for the membership. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectMembershipCompactResponseData**](ProjectMembershipCompactResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_memberships** -> MembershipResponseArray get_memberships(parent=parent, member=member, limit=limit, offset=offset, opt_fields=opt_fields) - -Get multiple memberships - -Returns compact `goal_membership` or `project_membership` records. The possible types for `parent` in this request are `goal` or `project`. An additional member (user GID or team GID) can be passed in to filter to a specific membership. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.MembershipsApi(api_client) -parent = '159874' # str | Globally unique identifier for `goal` or `project`. (optional) -member = '1061493' # str | Globally unique identifier for `team` or `user`. (optional) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["offset","path","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get multiple memberships - api_response = api_instance.get_memberships(parent=parent, member=member, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling MembershipsApi->get_memberships: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **parent** | **str**| Globally unique identifier for `goal` or `project`. | [optional] - **member** | **str**| Globally unique identifier for `team` or `user`. | [optional] - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**MembershipResponseArray**](MembershipResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/MembershipsApi.yaml b/docs/MembershipsApi.yaml deleted file mode 100644 index 467cc810..00000000 --- a/docs/MembershipsApi.yaml +++ /dev/null @@ -1,86 +0,0 @@ -MembershipsApi: - create_membership: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.MembershipsApi(api_client) - body = asana.MembershipsBody({"param1": "value1", "param2": "value2",}) # MembershipsBody | The updated fields for the membership. (optional) - - try: - # Create a membership - api_response = api_instance.create_membership(body=body) - pprint(api_response) - except ApiException as e: - print("Exception when calling MembershipsApi->create_membership: %s\n" % e) - delete_membership: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.MembershipsApi(api_client) - membership_gid = '12345' # str | Globally unique identifier for the membership. - - try: - # Delete a membership - api_response = api_instance.delete_membership(membership_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling MembershipsApi->delete_membership: %s\n" % e) - get_membership: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.MembershipsApi(api_client) - membership_gid = '12345' # str | Globally unique identifier for the membership. - opt_fields = ["access_level","member","member.name","parent","parent.name","resource_subtype"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a membership - api_response = api_instance.get_membership(membership_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling MembershipsApi->get_membership: %s\n" % e) - get_memberships: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.MembershipsApi(api_client) - parent = '159874' # str | Globally unique identifier for `goal` or `project`. (optional) - member = '1061493' # str | Globally unique identifier for `team` or `user`. (optional) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["offset","path","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get multiple memberships - api_response = api_instance.get_memberships(parent=parent, member=member, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling MembershipsApi->get_memberships: %s\n" % e) diff --git a/docs/MembershipsBody.md b/docs/MembershipsBody.md deleted file mode 100644 index e5404466..00000000 --- a/docs/MembershipsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# MembershipsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**CreateMembershipRequest**](CreateMembershipRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ModifyDependenciesRequest.md b/docs/ModifyDependenciesRequest.md deleted file mode 100644 index ce34d554..00000000 --- a/docs/ModifyDependenciesRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# ModifyDependenciesRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**dependencies** | **list[str]** | An array of task gids that a task depends on. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ModifyDependentsRequest.md b/docs/ModifyDependentsRequest.md deleted file mode 100644 index 7aabf184..00000000 --- a/docs/ModifyDependentsRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# ModifyDependentsRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**dependents** | **list[str]** | An array of task gids that are dependents of the given task. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/NextPage.md b/docs/NextPage.md deleted file mode 100644 index 6ba7a7c5..00000000 --- a/docs/NextPage.md +++ /dev/null @@ -1,11 +0,0 @@ -# NextPage - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**offset** | **str** | Pagination offset for the request. | [optional] -**path** | **str** | A relative path containing the query parameters to fetch for next_page | [optional] -**uri** | **str** | A full uri containing the query parameters to fetch for next_page | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/OrganizationExportBase.md b/docs/OrganizationExportBase.md deleted file mode 100644 index 76cbe618..00000000 --- a/docs/OrganizationExportBase.md +++ /dev/null @@ -1,14 +0,0 @@ -# OrganizationExportBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**download_url** | **str** | Download this URL to retreive the full export of the organization in JSON format. It will be compressed in a gzip (.gz) container. *Note: May be null if the export is still in progress or failed. If present, this URL may only be valid for 1 hour from the time of retrieval. You should avoid persisting this URL somewhere and rather refresh on demand to ensure you do not keep stale URLs.* | [optional] -**state** | **str** | The current state of the export. | [optional] -**organization** | [**GoalResponseWorkspace**](GoalResponseWorkspace.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/OrganizationExportCompact.md b/docs/OrganizationExportCompact.md deleted file mode 100644 index 9efeb65a..00000000 --- a/docs/OrganizationExportCompact.md +++ /dev/null @@ -1,14 +0,0 @@ -# OrganizationExportCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**download_url** | **str** | Download this URL to retreive the full export of the organization in JSON format. It will be compressed in a gzip (.gz) container. *Note: May be null if the export is still in progress or failed. If present, this URL may only be valid for 1 hour from the time of retrieval. You should avoid persisting this URL somewhere and rather refresh on demand to ensure you do not keep stale URLs.* | [optional] -**state** | **str** | The current state of the export. | [optional] -**organization** | [**GoalResponseWorkspace**](GoalResponseWorkspace.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/OrganizationExportRequest.md b/docs/OrganizationExportRequest.md deleted file mode 100644 index 1a0aef60..00000000 --- a/docs/OrganizationExportRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# OrganizationExportRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**organization** | **str** | Globally unique identifier for the workspace or organization. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/OrganizationExportResponse.md b/docs/OrganizationExportResponse.md deleted file mode 100644 index 47b04e8d..00000000 --- a/docs/OrganizationExportResponse.md +++ /dev/null @@ -1,14 +0,0 @@ -# OrganizationExportResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**download_url** | **str** | Download this URL to retreive the full export of the organization in JSON format. It will be compressed in a gzip (.gz) container. *Note: May be null if the export is still in progress or failed. If present, this URL may only be valid for 1 hour from the time of retrieval. You should avoid persisting this URL somewhere and rather refresh on demand to ensure you do not keep stale URLs.* | [optional] -**state** | **str** | The current state of the export. | [optional] -**organization** | [**GoalResponseWorkspace**](GoalResponseWorkspace.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/OrganizationExportResponseData.md b/docs/OrganizationExportResponseData.md deleted file mode 100644 index eac8229d..00000000 --- a/docs/OrganizationExportResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# OrganizationExportResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**OrganizationExportResponse**](OrganizationExportResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/OrganizationExportsApi.md b/docs/OrganizationExportsApi.md deleted file mode 100644 index 71262036..00000000 --- a/docs/OrganizationExportsApi.md +++ /dev/null @@ -1,115 +0,0 @@ -# asana.OrganizationExportsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_organization_export**](OrganizationExportsApi.md#create_organization_export) | **POST** /organization_exports | Create an organization export request -[**get_organization_export**](OrganizationExportsApi.md#get_organization_export) | **GET** /organization_exports/{organization_export_gid} | Get details on an org export request - -# **create_organization_export** -> OrganizationExportResponseData create_organization_export(body, opt_fields=opt_fields) - -Create an organization export request - -This method creates a request to export an Organization. Asana will complete the export at some point after you create the request. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.OrganizationExportsApi(api_client) -body = asana.OrganizationExportsBody({"param1": "value1", "param2": "value2",}) # OrganizationExportsBody | The organization to export. -opt_fields = ["created_at","download_url","organization","organization.name","state"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create an organization export request - api_response = api_instance.create_organization_export(body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling OrganizationExportsApi->create_organization_export: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**OrganizationExportsBody**](OrganizationExportsBody.md)| The organization to export. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**OrganizationExportResponseData**](OrganizationExportResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_organization_export** -> OrganizationExportResponseData get_organization_export(organization_export_gid, opt_fields=opt_fields) - -Get details on an org export request - -Returns details of a previously-requested Organization export. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.OrganizationExportsApi(api_client) -organization_export_gid = '12345' # str | Globally unique identifier for the organization export. -opt_fields = ["created_at","download_url","organization","organization.name","state"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get details on an org export request - api_response = api_instance.get_organization_export(organization_export_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling OrganizationExportsApi->get_organization_export: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **organization_export_gid** | **str**| Globally unique identifier for the organization export. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**OrganizationExportResponseData**](OrganizationExportResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/OrganizationExportsApi.yaml b/docs/OrganizationExportsApi.yaml deleted file mode 100644 index 74dda461..00000000 --- a/docs/OrganizationExportsApi.yaml +++ /dev/null @@ -1,43 +0,0 @@ -OrganizationExportsApi: - create_organization_export: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.OrganizationExportsApi(api_client) - body = asana.OrganizationExportsBody({"param1": "value1", "param2": "value2",}) # OrganizationExportsBody | The organization to export. - opt_fields = ["created_at","download_url","organization","organization.name","state"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create an organization export request - api_response = api_instance.create_organization_export(body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling OrganizationExportsApi->create_organization_export: %s\n" % e) - get_organization_export: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.OrganizationExportsApi(api_client) - organization_export_gid = '12345' # str | Globally unique identifier for the organization export. - opt_fields = ["created_at","download_url","organization","organization.name","state"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get details on an org export request - api_response = api_instance.get_organization_export(organization_export_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling OrganizationExportsApi->get_organization_export: %s\n" % e) diff --git a/docs/OrganizationExportsBody.md b/docs/OrganizationExportsBody.md deleted file mode 100644 index 5b9e49d2..00000000 --- a/docs/OrganizationExportsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# OrganizationExportsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**OrganizationExportRequest**](OrganizationExportRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioAddItemRequest.md b/docs/PortfolioAddItemRequest.md deleted file mode 100644 index 7532932f..00000000 --- a/docs/PortfolioAddItemRequest.md +++ /dev/null @@ -1,11 +0,0 @@ -# PortfolioAddItemRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**item** | **str** | The item to add to the portfolio. | -**insert_before** | **str** | An id of an item in this portfolio. The new item will be added before the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. | [optional] -**insert_after** | **str** | An id of an item in this portfolio. The new item will be added after the one specified here. `insert_before` and `insert_after` parameters cannot both be specified. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioBase.md b/docs/PortfolioBase.md deleted file mode 100644 index 360422d9..00000000 --- a/docs/PortfolioBase.md +++ /dev/null @@ -1,12 +0,0 @@ -# PortfolioBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the portfolio. | [optional] -**color** | **str** | Color of the portfolio. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioCompact.md b/docs/PortfolioCompact.md deleted file mode 100644 index 5cd67b84..00000000 --- a/docs/PortfolioCompact.md +++ /dev/null @@ -1,11 +0,0 @@ -# PortfolioCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the portfolio. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioGidAddCustomFieldSettingBody.md b/docs/PortfolioGidAddCustomFieldSettingBody.md deleted file mode 100644 index e9a94da6..00000000 --- a/docs/PortfolioGidAddCustomFieldSettingBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# PortfolioGidAddCustomFieldSettingBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**AddCustomFieldSettingRequest**](AddCustomFieldSettingRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioGidAddItemBody.md b/docs/PortfolioGidAddItemBody.md deleted file mode 100644 index 748580ea..00000000 --- a/docs/PortfolioGidAddItemBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# PortfolioGidAddItemBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**PortfolioAddItemRequest**](PortfolioAddItemRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioGidAddMembersBody.md b/docs/PortfolioGidAddMembersBody.md deleted file mode 100644 index 6f08859f..00000000 --- a/docs/PortfolioGidAddMembersBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# PortfolioGidAddMembersBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**AddMembersRequest**](AddMembersRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioGidRemoveCustomFieldSettingBody.md b/docs/PortfolioGidRemoveCustomFieldSettingBody.md deleted file mode 100644 index 304b9749..00000000 --- a/docs/PortfolioGidRemoveCustomFieldSettingBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# PortfolioGidRemoveCustomFieldSettingBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**RemoveCustomFieldSettingRequest**](RemoveCustomFieldSettingRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioGidRemoveItemBody.md b/docs/PortfolioGidRemoveItemBody.md deleted file mode 100644 index 6fc54cba..00000000 --- a/docs/PortfolioGidRemoveItemBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# PortfolioGidRemoveItemBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**PortfolioRemoveItemRequest**](PortfolioRemoveItemRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioGidRemoveMembersBody.md b/docs/PortfolioGidRemoveMembersBody.md deleted file mode 100644 index 8e538480..00000000 --- a/docs/PortfolioGidRemoveMembersBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# PortfolioGidRemoveMembersBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**RemoveMembersRequest**](RemoveMembersRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioMembershipBase.md b/docs/PortfolioMembershipBase.md deleted file mode 100644 index 7c20b3bd..00000000 --- a/docs/PortfolioMembershipBase.md +++ /dev/null @@ -1,12 +0,0 @@ -# PortfolioMembershipBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**portfolio** | [**PortfolioMembershipBasePortfolio**](PortfolioMembershipBasePortfolio.md) | | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioMembershipBasePortfolio.md b/docs/PortfolioMembershipBasePortfolio.md deleted file mode 100644 index 1d9e4596..00000000 --- a/docs/PortfolioMembershipBasePortfolio.md +++ /dev/null @@ -1,11 +0,0 @@ -# PortfolioMembershipBasePortfolio - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the portfolio. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioMembershipCompact.md b/docs/PortfolioMembershipCompact.md deleted file mode 100644 index 8807395c..00000000 --- a/docs/PortfolioMembershipCompact.md +++ /dev/null @@ -1,12 +0,0 @@ -# PortfolioMembershipCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**portfolio** | [**PortfolioMembershipBasePortfolio**](PortfolioMembershipBasePortfolio.md) | | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioMembershipResponse.md b/docs/PortfolioMembershipResponse.md deleted file mode 100644 index 41d0da3f..00000000 --- a/docs/PortfolioMembershipResponse.md +++ /dev/null @@ -1,12 +0,0 @@ -# PortfolioMembershipResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**portfolio** | [**PortfolioMembershipBasePortfolio**](PortfolioMembershipBasePortfolio.md) | | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioMembershipResponseArray.md b/docs/PortfolioMembershipResponseArray.md deleted file mode 100644 index 7605890c..00000000 --- a/docs/PortfolioMembershipResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# PortfolioMembershipResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[PortfolioMembershipResponse]**](PortfolioMembershipResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioMembershipResponseData.md b/docs/PortfolioMembershipResponseData.md deleted file mode 100644 index dbc45b6b..00000000 --- a/docs/PortfolioMembershipResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# PortfolioMembershipResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**PortfolioMembershipResponse**](PortfolioMembershipResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioMembershipsApi.md b/docs/PortfolioMembershipsApi.md deleted file mode 100644 index e226b949..00000000 --- a/docs/PortfolioMembershipsApi.md +++ /dev/null @@ -1,183 +0,0 @@ -# asana.PortfolioMembershipsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**get_portfolio_membership**](PortfolioMembershipsApi.md#get_portfolio_membership) | **GET** /portfolio_memberships/{portfolio_membership_gid} | Get a portfolio membership -[**get_portfolio_memberships**](PortfolioMembershipsApi.md#get_portfolio_memberships) | **GET** /portfolio_memberships | Get multiple portfolio memberships -[**get_portfolio_memberships_for_portfolio**](PortfolioMembershipsApi.md#get_portfolio_memberships_for_portfolio) | **GET** /portfolios/{portfolio_gid}/portfolio_memberships | Get memberships from a portfolio - -# **get_portfolio_membership** -> PortfolioMembershipResponseData get_portfolio_membership(portfolio_membership_gid, opt_fields=opt_fields) - -Get a portfolio membership - -Returns the complete portfolio record for a single portfolio membership. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfolioMembershipsApi(api_client) -portfolio_membership_gid = '1331' # str | -opt_fields = ["portfolio","portfolio.name","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a portfolio membership - api_response = api_instance.get_portfolio_membership(portfolio_membership_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfolioMembershipsApi->get_portfolio_membership: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **portfolio_membership_gid** | **str**| | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**PortfolioMembershipResponseData**](PortfolioMembershipResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_portfolio_memberships** -> PortfolioMembershipResponseArray get_portfolio_memberships(portfolio=portfolio, workspace=workspace, user=user, limit=limit, offset=offset, opt_fields=opt_fields) - -Get multiple portfolio memberships - -Returns a list of portfolio memberships in compact representation. You must specify `portfolio`, `portfolio` and `user`, or `workspace` and `user`. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfolioMembershipsApi(api_client) -portfolio = '12345' # str | The portfolio to filter results on. (optional) -workspace = '12345' # str | The workspace to filter results on. (optional) -user = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (optional) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["offset","path","portfolio","portfolio.name","uri","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get multiple portfolio memberships - api_response = api_instance.get_portfolio_memberships(portfolio=portfolio, workspace=workspace, user=user, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfolioMembershipsApi->get_portfolio_memberships: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **portfolio** | **str**| The portfolio to filter results on. | [optional] - **workspace** | **str**| The workspace to filter results on. | [optional] - **user** | **str**| A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | [optional] - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**PortfolioMembershipResponseArray**](PortfolioMembershipResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_portfolio_memberships_for_portfolio** -> PortfolioMembershipResponseArray get_portfolio_memberships_for_portfolio(portfolio_gid, user=user, limit=limit, offset=offset, opt_fields=opt_fields) - -Get memberships from a portfolio - -Returns the compact portfolio membership records for the portfolio. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfolioMembershipsApi(api_client) -portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. -user = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (optional) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["offset","path","portfolio","portfolio.name","uri","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get memberships from a portfolio - api_response = api_instance.get_portfolio_memberships_for_portfolio(portfolio_gid, user=user, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfolioMembershipsApi->get_portfolio_memberships_for_portfolio: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **portfolio_gid** | **str**| Globally unique identifier for the portfolio. | - **user** | **str**| A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | [optional] - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**PortfolioMembershipResponseArray**](PortfolioMembershipResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/PortfolioMembershipsApi.yaml b/docs/PortfolioMembershipsApi.yaml deleted file mode 100644 index 2e5daeec..00000000 --- a/docs/PortfolioMembershipsApi.yaml +++ /dev/null @@ -1,71 +0,0 @@ -PortfolioMembershipsApi: - get_portfolio_membership: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfolioMembershipsApi(api_client) - portfolio_membership_gid = '1331' # str | - opt_fields = ["portfolio","portfolio.name","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a portfolio membership - api_response = api_instance.get_portfolio_membership(portfolio_membership_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfolioMembershipsApi->get_portfolio_membership: %s\n" % e) - get_portfolio_memberships: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfolioMembershipsApi(api_client) - portfolio = '12345' # str | The portfolio to filter results on. (optional) - workspace = '12345' # str | The workspace to filter results on. (optional) - user = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (optional) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["offset","path","portfolio","portfolio.name","uri","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get multiple portfolio memberships - api_response = api_instance.get_portfolio_memberships(portfolio=portfolio, workspace=workspace, user=user, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfolioMembershipsApi->get_portfolio_memberships: %s\n" % e) - get_portfolio_memberships_for_portfolio: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfolioMembershipsApi(api_client) - portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - user = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (optional) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["offset","path","portfolio","portfolio.name","uri","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get memberships from a portfolio - api_response = api_instance.get_portfolio_memberships_for_portfolio(portfolio_gid, user=user, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfolioMembershipsApi->get_portfolio_memberships_for_portfolio: %s\n" % e) diff --git a/docs/PortfolioRemoveItemRequest.md b/docs/PortfolioRemoveItemRequest.md deleted file mode 100644 index 3580c7c9..00000000 --- a/docs/PortfolioRemoveItemRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# PortfolioRemoveItemRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**item** | **str** | The item to remove from the portfolio. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioRequest.md b/docs/PortfolioRequest.md deleted file mode 100644 index 03014a8a..00000000 --- a/docs/PortfolioRequest.md +++ /dev/null @@ -1,15 +0,0 @@ -# PortfolioRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the portfolio. | [optional] -**color** | **str** | Color of the portfolio. | [optional] -**members** | **list[str]** | An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. | [optional] -**workspace** | **str** | Gid of an object. | [optional] -**public** | **bool** | True if the portfolio is public to its workspace members. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioResponse.md b/docs/PortfolioResponse.md deleted file mode 100644 index 58f60c96..00000000 --- a/docs/PortfolioResponse.md +++ /dev/null @@ -1,25 +0,0 @@ -# PortfolioResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the portfolio. | [optional] -**color** | **str** | Color of the portfolio. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**created_by** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**custom_field_settings** | [**list[PortfolioResponseCustomFieldSettings]**](PortfolioResponseCustomFieldSettings.md) | Array of custom field settings applied to the portfolio. | [optional] -**current_status_update** | [**PortfolioResponseCurrentStatusUpdate**](PortfolioResponseCurrentStatusUpdate.md) | | [optional] -**due_on** | **date** | The localized day on which this portfolio is due. This takes a date with format YYYY-MM-DD. | [optional] -**custom_fields** | [**list[PortfolioResponseCustomFields]**](PortfolioResponseCustomFields.md) | Array of Custom Fields. | [optional] -**members** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | | [optional] -**owner** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**start_on** | **date** | The day on which work for this portfolio begins, or null if the portfolio has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* | [optional] -**workspace** | [**PortfolioResponseWorkspace**](PortfolioResponseWorkspace.md) | | [optional] -**permalink_url** | **str** | A url that points directly to the object within Asana. | [optional] -**public** | **bool** | True if the portfolio is public to its workspace members. | [optional] -**project_templates** | [**list[JobBaseNewProjectTemplate]**](JobBaseNewProjectTemplate.md) | Array of project templates that are in the portfolio | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioResponseArray.md b/docs/PortfolioResponseArray.md deleted file mode 100644 index 03d34500..00000000 --- a/docs/PortfolioResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# PortfolioResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[PortfolioResponse]**](PortfolioResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioResponseCurrentStatusUpdate.md b/docs/PortfolioResponseCurrentStatusUpdate.md deleted file mode 100644 index 2dd1167a..00000000 --- a/docs/PortfolioResponseCurrentStatusUpdate.md +++ /dev/null @@ -1,12 +0,0 @@ -# PortfolioResponseCurrentStatusUpdate - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the status update. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioResponseCustomFieldSettings.md b/docs/PortfolioResponseCustomFieldSettings.md deleted file mode 100644 index 922faa77..00000000 --- a/docs/PortfolioResponseCustomFieldSettings.md +++ /dev/null @@ -1,14 +0,0 @@ -# PortfolioResponseCustomFieldSettings - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**project** | [**CustomFieldSettingResponseProject**](CustomFieldSettingResponseProject.md) | | [optional] -**is_important** | **bool** | `is_important` is used in the Asana web application to determine if this custom field is displayed in the list/grid view of a project or portfolio. | [optional] -**parent** | [**CustomFieldSettingResponseParent**](CustomFieldSettingResponseParent.md) | | [optional] -**custom_field** | [**CustomFieldSettingResponseCustomField**](CustomFieldSettingResponseCustomField.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioResponseCustomFields.md b/docs/PortfolioResponseCustomFields.md deleted file mode 100644 index 022cf727..00000000 --- a/docs/PortfolioResponseCustomFields.md +++ /dev/null @@ -1,22 +0,0 @@ -# PortfolioResponseCustomFields - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the custom field. | [optional] -**resource_subtype** | **str** | The type of the custom field. Must be one of the given values. | [optional] -**type** | **str** | *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. | [optional] -**enum_options** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). | [optional] -**enabled** | **bool** | *Conditional*. Determines if the custom field is enabled or not. | [optional] -**is_formula_field** | **bool** | *Conditional*. This flag describes whether a custom field is a formula custom field. | [optional] -**date_value** | [**CustomFieldBaseDateValue**](CustomFieldBaseDateValue.md) | | [optional] -**enum_value** | [**CustomFieldBaseEnumValue**](CustomFieldBaseEnumValue.md) | | [optional] -**multi_enum_values** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. | [optional] -**number_value** | **float** | *Conditional*. This number is the value of a `number` custom field. | [optional] -**text_value** | **str** | *Conditional*. This string is the value of a `text` custom field. | [optional] -**display_value** | **str** | A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioResponseData.md b/docs/PortfolioResponseData.md deleted file mode 100644 index 5784681d..00000000 --- a/docs/PortfolioResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# PortfolioResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**PortfolioResponse**](PortfolioResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfolioResponseWorkspace.md b/docs/PortfolioResponseWorkspace.md deleted file mode 100644 index e9214402..00000000 --- a/docs/PortfolioResponseWorkspace.md +++ /dev/null @@ -1,11 +0,0 @@ -# PortfolioResponseWorkspace - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the workspace. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfoliosApi.md b/docs/PortfoliosApi.md deleted file mode 100644 index 04f039e3..00000000 --- a/docs/PortfoliosApi.md +++ /dev/null @@ -1,669 +0,0 @@ -# asana.PortfoliosApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**add_custom_field_setting_for_portfolio**](PortfoliosApi.md#add_custom_field_setting_for_portfolio) | **POST** /portfolios/{portfolio_gid}/addCustomFieldSetting | Add a custom field to a portfolio -[**add_item_for_portfolio**](PortfoliosApi.md#add_item_for_portfolio) | **POST** /portfolios/{portfolio_gid}/addItem | Add a portfolio item -[**add_members_for_portfolio**](PortfoliosApi.md#add_members_for_portfolio) | **POST** /portfolios/{portfolio_gid}/addMembers | Add users to a portfolio -[**create_portfolio**](PortfoliosApi.md#create_portfolio) | **POST** /portfolios | Create a portfolio -[**delete_portfolio**](PortfoliosApi.md#delete_portfolio) | **DELETE** /portfolios/{portfolio_gid} | Delete a portfolio -[**get_items_for_portfolio**](PortfoliosApi.md#get_items_for_portfolio) | **GET** /portfolios/{portfolio_gid}/items | Get portfolio items -[**get_portfolio**](PortfoliosApi.md#get_portfolio) | **GET** /portfolios/{portfolio_gid} | Get a portfolio -[**get_portfolios**](PortfoliosApi.md#get_portfolios) | **GET** /portfolios | Get multiple portfolios -[**remove_custom_field_setting_for_portfolio**](PortfoliosApi.md#remove_custom_field_setting_for_portfolio) | **POST** /portfolios/{portfolio_gid}/removeCustomFieldSetting | Remove a custom field from a portfolio -[**remove_item_for_portfolio**](PortfoliosApi.md#remove_item_for_portfolio) | **POST** /portfolios/{portfolio_gid}/removeItem | Remove a portfolio item -[**remove_members_for_portfolio**](PortfoliosApi.md#remove_members_for_portfolio) | **POST** /portfolios/{portfolio_gid}/removeMembers | Remove users from a portfolio -[**update_portfolio**](PortfoliosApi.md#update_portfolio) | **PUT** /portfolios/{portfolio_gid} | Update a portfolio - -# **add_custom_field_setting_for_portfolio** -> CustomFieldSettingResponseData add_custom_field_setting_for_portfolio(body, portfolio_gid) - -Add a custom field to a portfolio - -Custom fields are associated with portfolios by way of custom field settings. This method creates a setting for the portfolio. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfoliosApi(api_client) -body = asana.PortfolioGidAddCustomFieldSettingBody({"param1": "value1", "param2": "value2",}) # PortfolioGidAddCustomFieldSettingBody | Information about the custom field setting. -portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - -try: - # Add a custom field to a portfolio - api_response = api_instance.add_custom_field_setting_for_portfolio(body, portfolio_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfoliosApi->add_custom_field_setting_for_portfolio: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**PortfolioGidAddCustomFieldSettingBody**](PortfolioGidAddCustomFieldSettingBody.md)| Information about the custom field setting. | - **portfolio_gid** | **str**| Globally unique identifier for the portfolio. | - -### Return type - -[**CustomFieldSettingResponseData**](CustomFieldSettingResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **add_item_for_portfolio** -> EmptyResponseData add_item_for_portfolio(body, portfolio_gid) - -Add a portfolio item - -Add an item to a portfolio. Returns an empty data block. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfoliosApi(api_client) -body = asana.PortfolioGidAddItemBody({"param1": "value1", "param2": "value2",}) # PortfolioGidAddItemBody | Information about the item being inserted. -portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - -try: - # Add a portfolio item - api_response = api_instance.add_item_for_portfolio(body, portfolio_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfoliosApi->add_item_for_portfolio: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**PortfolioGidAddItemBody**](PortfolioGidAddItemBody.md)| Information about the item being inserted. | - **portfolio_gid** | **str**| Globally unique identifier for the portfolio. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **add_members_for_portfolio** -> PortfolioResponseData add_members_for_portfolio(body, portfolio_gid, opt_fields=opt_fields) - -Add users to a portfolio - -Adds the specified list of users as members of the portfolio. Returns the updated portfolio record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfoliosApi(api_client) -body = asana.PortfolioGidAddMembersBody({"param1": "value1", "param2": "value2",}) # PortfolioGidAddMembersBody | Information about the members being added. -portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. -opt_fields = ["color","created_at","created_by","created_by.name","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","due_on","members","members.name","name","owner","owner.name","permalink_url","project_templates","project_templates.name","public","start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Add users to a portfolio - api_response = api_instance.add_members_for_portfolio(body, portfolio_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfoliosApi->add_members_for_portfolio: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**PortfolioGidAddMembersBody**](PortfolioGidAddMembersBody.md)| Information about the members being added. | - **portfolio_gid** | **str**| Globally unique identifier for the portfolio. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**PortfolioResponseData**](PortfolioResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **create_portfolio** -> PortfolioResponseData create_portfolio(body, opt_fields=opt_fields) - -Create a portfolio - -Creates a new portfolio in the given workspace with the supplied name. Note that portfolios created in the Asana UI may have some state (like the “Priority” custom field) which is automatically added to the portfolio when it is created. Portfolios created via our API will *not* be created with the same initial state to allow integrations to create their own starting state on a portfolio. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfoliosApi(api_client) -body = asana.PortfoliosBody({"param1": "value1", "param2": "value2",}) # PortfoliosBody | The portfolio to create. -opt_fields = ["color","created_at","created_by","created_by.name","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","due_on","members","members.name","name","owner","owner.name","permalink_url","project_templates","project_templates.name","public","start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a portfolio - api_response = api_instance.create_portfolio(body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfoliosApi->create_portfolio: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**PortfoliosBody**](PortfoliosBody.md)| The portfolio to create. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**PortfolioResponseData**](PortfolioResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_portfolio** -> EmptyResponseData delete_portfolio(portfolio_gid) - -Delete a portfolio - -An existing portfolio can be deleted by making a DELETE request on the URL for that portfolio. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfoliosApi(api_client) -portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - -try: - # Delete a portfolio - api_response = api_instance.delete_portfolio(portfolio_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfoliosApi->delete_portfolio: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **portfolio_gid** | **str**| Globally unique identifier for the portfolio. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_items_for_portfolio** -> ProjectResponseArray get_items_for_portfolio(portfolio_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get portfolio items - -Get a list of the items in compact form in a portfolio. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfoliosApi(api_client) -portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","offset","owner","path","permalink_url","project_brief","public","start_on","team","team.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get portfolio items - api_response = api_instance.get_items_for_portfolio(portfolio_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfoliosApi->get_items_for_portfolio: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **portfolio_gid** | **str**| Globally unique identifier for the portfolio. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseArray**](ProjectResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_portfolio** -> PortfolioResponseData get_portfolio(portfolio_gid, opt_fields=opt_fields) - -Get a portfolio - -Returns the complete portfolio record for a single portfolio. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfoliosApi(api_client) -portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. -opt_fields = ["color","created_at","created_by","created_by.name","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","due_on","members","members.name","name","owner","owner.name","permalink_url","project_templates","project_templates.name","public","start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a portfolio - api_response = api_instance.get_portfolio(portfolio_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfoliosApi->get_portfolio: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **portfolio_gid** | **str**| Globally unique identifier for the portfolio. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**PortfolioResponseData**](PortfolioResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_portfolios** -> PortfolioResponseArray get_portfolios(workspace, limit=limit, offset=offset, owner=owner, opt_fields=opt_fields) - -Get multiple portfolios - -Returns a list of the portfolios in compact representation that are owned by the current API user. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfoliosApi(api_client) -workspace = '1331' # str | The workspace or organization to filter portfolios on. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -owner = '14916' # str | The user who owns the portfolio. Currently, API users can only get a list of portfolios that they themselves own, unless the request is made from a Service Account. In the case of a Service Account, if this parameter is specified, then all portfolios owned by this parameter are returned. Otherwise, all portfolios across the workspace are returned. (optional) -opt_fields = ["color","created_at","created_by","created_by.name","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","due_on","members","members.name","name","offset","owner","owner.name","path","permalink_url","project_templates","project_templates.name","public","start_on","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get multiple portfolios - api_response = api_instance.get_portfolios(workspace, limit=limit, offset=offset, owner=owner, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfoliosApi->get_portfolios: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace** | **str**| The workspace or organization to filter portfolios on. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **owner** | **str**| The user who owns the portfolio. Currently, API users can only get a list of portfolios that they themselves own, unless the request is made from a Service Account. In the case of a Service Account, if this parameter is specified, then all portfolios owned by this parameter are returned. Otherwise, all portfolios across the workspace are returned. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**PortfolioResponseArray**](PortfolioResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_custom_field_setting_for_portfolio** -> EmptyResponseData remove_custom_field_setting_for_portfolio(body, portfolio_gid) - -Remove a custom field from a portfolio - -Removes a custom field setting from a portfolio. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfoliosApi(api_client) -body = asana.PortfolioGidRemoveCustomFieldSettingBody({"param1": "value1", "param2": "value2",}) # PortfolioGidRemoveCustomFieldSettingBody | Information about the custom field setting being removed. -portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - -try: - # Remove a custom field from a portfolio - api_response = api_instance.remove_custom_field_setting_for_portfolio(body, portfolio_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfoliosApi->remove_custom_field_setting_for_portfolio: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**PortfolioGidRemoveCustomFieldSettingBody**](PortfolioGidRemoveCustomFieldSettingBody.md)| Information about the custom field setting being removed. | - **portfolio_gid** | **str**| Globally unique identifier for the portfolio. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_item_for_portfolio** -> EmptyResponseData remove_item_for_portfolio(body, portfolio_gid) - -Remove a portfolio item - -Remove an item from a portfolio. Returns an empty data block. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfoliosApi(api_client) -body = asana.PortfolioGidRemoveItemBody({"param1": "value1", "param2": "value2",}) # PortfolioGidRemoveItemBody | Information about the item being removed. -portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - -try: - # Remove a portfolio item - api_response = api_instance.remove_item_for_portfolio(body, portfolio_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfoliosApi->remove_item_for_portfolio: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**PortfolioGidRemoveItemBody**](PortfolioGidRemoveItemBody.md)| Information about the item being removed. | - **portfolio_gid** | **str**| Globally unique identifier for the portfolio. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_members_for_portfolio** -> PortfolioResponseData remove_members_for_portfolio(body, portfolio_gid, opt_fields=opt_fields) - -Remove users from a portfolio - -Removes the specified list of users from members of the portfolio. Returns the updated portfolio record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfoliosApi(api_client) -body = asana.PortfolioGidRemoveMembersBody({"param1": "value1", "param2": "value2",}) # PortfolioGidRemoveMembersBody | Information about the members being removed. -portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. -opt_fields = ["color","created_at","created_by","created_by.name","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","due_on","members","members.name","name","owner","owner.name","permalink_url","project_templates","project_templates.name","public","start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Remove users from a portfolio - api_response = api_instance.remove_members_for_portfolio(body, portfolio_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfoliosApi->remove_members_for_portfolio: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**PortfolioGidRemoveMembersBody**](PortfolioGidRemoveMembersBody.md)| Information about the members being removed. | - **portfolio_gid** | **str**| Globally unique identifier for the portfolio. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**PortfolioResponseData**](PortfolioResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_portfolio** -> PortfolioResponseData update_portfolio(body, portfolio_gid, opt_fields=opt_fields) - -Update a portfolio - -An existing portfolio can be updated by making a PUT request on the URL for that portfolio. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. Returns the complete updated portfolio record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.PortfoliosApi(api_client) -body = asana.PortfoliosPortfolioGidBody({"param1": "value1", "param2": "value2",}) # PortfoliosPortfolioGidBody | The updated fields for the portfolio. -portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. -opt_fields = ["color","created_at","created_by","created_by.name","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","due_on","members","members.name","name","owner","owner.name","permalink_url","project_templates","project_templates.name","public","start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a portfolio - api_response = api_instance.update_portfolio(body, portfolio_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling PortfoliosApi->update_portfolio: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**PortfoliosPortfolioGidBody**](PortfoliosPortfolioGidBody.md)| The updated fields for the portfolio. | - **portfolio_gid** | **str**| Globally unique identifier for the portfolio. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**PortfolioResponseData**](PortfolioResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/PortfoliosApi.yaml b/docs/PortfoliosApi.yaml deleted file mode 100644 index 5fdcd6b1..00000000 --- a/docs/PortfoliosApi.yaml +++ /dev/null @@ -1,260 +0,0 @@ -PortfoliosApi: - add_custom_field_setting_for_portfolio: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfoliosApi(api_client) - body = asana.PortfolioGidAddCustomFieldSettingBody({"param1": "value1", "param2": "value2",}) # PortfolioGidAddCustomFieldSettingBody | Information about the custom field setting. - portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - - try: - # Add a custom field to a portfolio - api_response = api_instance.add_custom_field_setting_for_portfolio(body, portfolio_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfoliosApi->add_custom_field_setting_for_portfolio: %s\n" % e) - add_item_for_portfolio: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfoliosApi(api_client) - body = asana.PortfolioGidAddItemBody({"param1": "value1", "param2": "value2",}) # PortfolioGidAddItemBody | Information about the item being inserted. - portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - - try: - # Add a portfolio item - api_response = api_instance.add_item_for_portfolio(body, portfolio_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfoliosApi->add_item_for_portfolio: %s\n" % e) - add_members_for_portfolio: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfoliosApi(api_client) - body = asana.PortfolioGidAddMembersBody({"param1": "value1", "param2": "value2",}) # PortfolioGidAddMembersBody | Information about the members being added. - portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - opt_fields = ["color","created_at","created_by","created_by.name","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","due_on","members","members.name","name","owner","owner.name","permalink_url","project_templates","project_templates.name","public","start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Add users to a portfolio - api_response = api_instance.add_members_for_portfolio(body, portfolio_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfoliosApi->add_members_for_portfolio: %s\n" % e) - create_portfolio: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfoliosApi(api_client) - body = asana.PortfoliosBody({"param1": "value1", "param2": "value2",}) # PortfoliosBody | The portfolio to create. - opt_fields = ["color","created_at","created_by","created_by.name","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","due_on","members","members.name","name","owner","owner.name","permalink_url","project_templates","project_templates.name","public","start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a portfolio - api_response = api_instance.create_portfolio(body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfoliosApi->create_portfolio: %s\n" % e) - delete_portfolio: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfoliosApi(api_client) - portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - - try: - # Delete a portfolio - api_response = api_instance.delete_portfolio(portfolio_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfoliosApi->delete_portfolio: %s\n" % e) - get_items_for_portfolio: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfoliosApi(api_client) - portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","offset","owner","path","permalink_url","project_brief","public","start_on","team","team.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get portfolio items - api_response = api_instance.get_items_for_portfolio(portfolio_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfoliosApi->get_items_for_portfolio: %s\n" % e) - get_portfolio: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfoliosApi(api_client) - portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - opt_fields = ["color","created_at","created_by","created_by.name","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","due_on","members","members.name","name","owner","owner.name","permalink_url","project_templates","project_templates.name","public","start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a portfolio - api_response = api_instance.get_portfolio(portfolio_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfoliosApi->get_portfolio: %s\n" % e) - get_portfolios: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfoliosApi(api_client) - workspace = '1331' # str | The workspace or organization to filter portfolios on. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - owner = '14916' # str | The user who owns the portfolio. Currently, API users can only get a list of portfolios that they themselves own, unless the request is made from a Service Account. In the case of a Service Account, if this parameter is specified, then all portfolios owned by this parameter are returned. Otherwise, all portfolios across the workspace are returned. (optional) - opt_fields = ["color","created_at","created_by","created_by.name","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","due_on","members","members.name","name","offset","owner","owner.name","path","permalink_url","project_templates","project_templates.name","public","start_on","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get multiple portfolios - api_response = api_instance.get_portfolios(workspace, limit=limit, offset=offset, owner=owner, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfoliosApi->get_portfolios: %s\n" % e) - remove_custom_field_setting_for_portfolio: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfoliosApi(api_client) - body = asana.PortfolioGidRemoveCustomFieldSettingBody({"param1": "value1", "param2": "value2",}) # PortfolioGidRemoveCustomFieldSettingBody | Information about the custom field setting being removed. - portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - - try: - # Remove a custom field from a portfolio - api_response = api_instance.remove_custom_field_setting_for_portfolio(body, portfolio_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfoliosApi->remove_custom_field_setting_for_portfolio: %s\n" % e) - remove_item_for_portfolio: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfoliosApi(api_client) - body = asana.PortfolioGidRemoveItemBody({"param1": "value1", "param2": "value2",}) # PortfolioGidRemoveItemBody | Information about the item being removed. - portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - - try: - # Remove a portfolio item - api_response = api_instance.remove_item_for_portfolio(body, portfolio_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfoliosApi->remove_item_for_portfolio: %s\n" % e) - remove_members_for_portfolio: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfoliosApi(api_client) - body = asana.PortfolioGidRemoveMembersBody({"param1": "value1", "param2": "value2",}) # PortfolioGidRemoveMembersBody | Information about the members being removed. - portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - opt_fields = ["color","created_at","created_by","created_by.name","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","due_on","members","members.name","name","owner","owner.name","permalink_url","project_templates","project_templates.name","public","start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Remove users from a portfolio - api_response = api_instance.remove_members_for_portfolio(body, portfolio_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfoliosApi->remove_members_for_portfolio: %s\n" % e) - update_portfolio: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.PortfoliosApi(api_client) - body = asana.PortfoliosPortfolioGidBody({"param1": "value1", "param2": "value2",}) # PortfoliosPortfolioGidBody | The updated fields for the portfolio. - portfolio_gid = '12345' # str | Globally unique identifier for the portfolio. - opt_fields = ["color","created_at","created_by","created_by.name","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","due_on","members","members.name","name","owner","owner.name","permalink_url","project_templates","project_templates.name","public","start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a portfolio - api_response = api_instance.update_portfolio(body, portfolio_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling PortfoliosApi->update_portfolio: %s\n" % e) diff --git a/docs/PortfoliosBody.md b/docs/PortfoliosBody.md deleted file mode 100644 index 97a16fcc..00000000 --- a/docs/PortfoliosBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# PortfoliosBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**PortfolioRequest**](PortfolioRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/PortfoliosPortfolioGidBody.md b/docs/PortfoliosPortfolioGidBody.md deleted file mode 100644 index bd435975..00000000 --- a/docs/PortfoliosPortfolioGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# PortfoliosPortfolioGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**PortfolioRequest**](PortfolioRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/Preview.md b/docs/Preview.md deleted file mode 100644 index f93a760e..00000000 --- a/docs/Preview.md +++ /dev/null @@ -1,16 +0,0 @@ -# Preview - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**fallback** | **str** | Some fallback text to display if unable to display the full preview. | [optional] -**footer** | **str** | Text to display in the footer. | [optional] -**header** | **str** | Text to display in the header. | [optional] -**header_link** | **str** | Where the header will link to. | [optional] -**html_text** | **str** | HTML formatted text for the body of the preview. | [optional] -**text** | **str** | Text for the body of the preview. | [optional] -**title** | **str** | Text to display as the title. | [optional] -**title_link** | **str** | Where to title will link to. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectBase.md b/docs/ProjectBase.md deleted file mode 100644 index 627a39ed..00000000 --- a/docs/ProjectBase.md +++ /dev/null @@ -1,29 +0,0 @@ -# ProjectBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] -**archived** | **bool** | True if the project is archived, false if not. Archived projects do not show in the UI by default and may be treated differently for queries. | [optional] -**color** | **str** | Color of the project. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**current_status** | [**ProjectBaseCurrentStatus**](ProjectBaseCurrentStatus.md) | | [optional] -**current_status_update** | [**ProjectBaseCurrentStatusUpdate**](ProjectBaseCurrentStatusUpdate.md) | | [optional] -**custom_field_settings** | [**list[PortfolioResponseCustomFieldSettings]**](PortfolioResponseCustomFieldSettings.md) | Array of Custom Field Settings (in compact form). | [optional] -**default_view** | **str** | The default view (list, board, calendar, or timeline) of a project. | [optional] -**due_date** | **date** | *Deprecated: new integrations should prefer the `due_on` field.* | [optional] -**due_on** | **date** | The day on which this project is due. This takes a date with format YYYY-MM-DD. | [optional] -**html_notes** | **str** | [Opt In](/docs/inputoutput-options). The notes of the project with formatting as HTML. | [optional] -**members** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | Array of users who are members of this project. | [optional] -**modified_at** | **datetime** | The time at which this project was last modified. *Note: This does not currently reflect any changes in associations such as tasks or comments that may have been added or removed from the project.* | [optional] -**notes** | **str** | Free-form textual information associated with the project (ie., its description). | [optional] -**public** | **bool** | True if the project is public to its team. | [optional] -**start_on** | **date** | The day on which work for this project begins, or null if the project has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* | [optional] -**default_access_level** | **str** | The default access for users or teams who join or are added as members to the project. | [optional] -**minimum_access_level_for_customization** | **str** | The minimum access level needed for project members to modify this project's workflow and appearance. | [optional] -**minimum_access_level_for_sharing** | **str** | The minimum access level needed for project members to share the project and manage project memberships. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectBaseCurrentStatus.md b/docs/ProjectBaseCurrentStatus.md deleted file mode 100644 index 42d0843b..00000000 --- a/docs/ProjectBaseCurrentStatus.md +++ /dev/null @@ -1,18 +0,0 @@ -# ProjectBaseCurrentStatus - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the project status update. | [optional] -**text** | **str** | The text content of the status update. | [optional] -**html_text** | **str** | [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. | [optional] -**color** | **str** | The color associated with the status update. | [optional] -**author** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**created_by** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**modified_at** | **datetime** | The time at which this project status was last modified. *Note: This does not currently reflect any changes in associations such as comments that may have been added or removed from the project status.* | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectBaseCurrentStatusUpdate.md b/docs/ProjectBaseCurrentStatusUpdate.md deleted file mode 100644 index 9a6d3026..00000000 --- a/docs/ProjectBaseCurrentStatusUpdate.md +++ /dev/null @@ -1,12 +0,0 @@ -# ProjectBaseCurrentStatusUpdate - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the status update. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectBaseWorkspace.md b/docs/ProjectBaseWorkspace.md deleted file mode 100644 index ff191f12..00000000 --- a/docs/ProjectBaseWorkspace.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectBaseWorkspace - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the workspace. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectBriefBase.md b/docs/ProjectBriefBase.md deleted file mode 100644 index 28b25f1b..00000000 --- a/docs/ProjectBriefBase.md +++ /dev/null @@ -1,12 +0,0 @@ -# ProjectBriefBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the project brief. | [optional] -**html_text** | **str** | HTML formatted text for the project brief. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectBriefCompact.md b/docs/ProjectBriefCompact.md deleted file mode 100644 index f9f759f6..00000000 --- a/docs/ProjectBriefCompact.md +++ /dev/null @@ -1,10 +0,0 @@ -# ProjectBriefCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectBriefRequest.md b/docs/ProjectBriefRequest.md deleted file mode 100644 index 571813b6..00000000 --- a/docs/ProjectBriefRequest.md +++ /dev/null @@ -1,13 +0,0 @@ -# ProjectBriefRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the project brief. | [optional] -**html_text** | **str** | HTML formatted text for the project brief. | [optional] -**text** | **str** | The plain text of the project brief. When writing to a project brief, you can specify either `html_text` (preferred) or `text`, but not both. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectBriefResponse.md b/docs/ProjectBriefResponse.md deleted file mode 100644 index d3e1f602..00000000 --- a/docs/ProjectBriefResponse.md +++ /dev/null @@ -1,15 +0,0 @@ -# ProjectBriefResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the project brief. | [optional] -**html_text** | **str** | HTML formatted text for the project brief. | [optional] -**text** | **str** | [Opt In](/docs/inputoutput-options). The plain text of the project brief. | [optional] -**permalink_url** | **str** | A url that points directly to the object within Asana. | [optional] -**project** | [**ProjectBriefResponseProject**](ProjectBriefResponseProject.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectBriefResponseData.md b/docs/ProjectBriefResponseData.md deleted file mode 100644 index 4b16f93a..00000000 --- a/docs/ProjectBriefResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectBriefResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectBriefResponse**](ProjectBriefResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectBriefResponseProject.md b/docs/ProjectBriefResponseProject.md deleted file mode 100644 index 544b5281..00000000 --- a/docs/ProjectBriefResponseProject.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectBriefResponseProject - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectBriefsApi.md b/docs/ProjectBriefsApi.md deleted file mode 100644 index 6c86118b..00000000 --- a/docs/ProjectBriefsApi.md +++ /dev/null @@ -1,225 +0,0 @@ -# asana.ProjectBriefsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_project_brief**](ProjectBriefsApi.md#create_project_brief) | **POST** /projects/{project_gid}/project_briefs | Create a project brief -[**delete_project_brief**](ProjectBriefsApi.md#delete_project_brief) | **DELETE** /project_briefs/{project_brief_gid} | Delete a project brief -[**get_project_brief**](ProjectBriefsApi.md#get_project_brief) | **GET** /project_briefs/{project_brief_gid} | Get a project brief -[**update_project_brief**](ProjectBriefsApi.md#update_project_brief) | **PUT** /project_briefs/{project_brief_gid} | Update a project brief - -# **create_project_brief** -> ProjectBriefResponseData create_project_brief(body, project_gid, opt_fields=opt_fields) - -Create a project brief - -Creates a new project brief. Returns the full record of the newly created project brief. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectBriefsApi(api_client) -body = asana.ProjectGidProjectBriefsBody({"param1": "value1", "param2": "value2",}) # ProjectGidProjectBriefsBody | The project brief to create. -project_gid = '1331' # str | Globally unique identifier for the project. -opt_fields = ["html_text","permalink_url","project","project.name","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a project brief - api_response = api_instance.create_project_brief(body, project_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectBriefsApi->create_project_brief: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ProjectGidProjectBriefsBody**](ProjectGidProjectBriefsBody.md)| The project brief to create. | - **project_gid** | **str**| Globally unique identifier for the project. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectBriefResponseData**](ProjectBriefResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_project_brief** -> EmptyResponseData delete_project_brief(project_brief_gid) - -Delete a project brief - -Deletes a specific, existing project brief. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectBriefsApi(api_client) -project_brief_gid = '12345' # str | Globally unique identifier for the project brief. - -try: - # Delete a project brief - api_response = api_instance.delete_project_brief(project_brief_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectBriefsApi->delete_project_brief: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_brief_gid** | **str**| Globally unique identifier for the project brief. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_project_brief** -> ProjectBriefResponseData get_project_brief(project_brief_gid, opt_fields=opt_fields) - -Get a project brief - -Get the full record for a project brief. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectBriefsApi(api_client) -project_brief_gid = '12345' # str | Globally unique identifier for the project brief. -opt_fields = ["html_text","permalink_url","project","project.name","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a project brief - api_response = api_instance.get_project_brief(project_brief_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectBriefsApi->get_project_brief: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_brief_gid** | **str**| Globally unique identifier for the project brief. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectBriefResponseData**](ProjectBriefResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_project_brief** -> ProjectBriefResponseData update_project_brief(body, project_brief_gid, opt_fields=opt_fields) - -Update a project brief - -An existing project brief can be updated by making a PUT request on the URL for that project brief. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. Returns the complete updated project brief record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectBriefsApi(api_client) -body = asana.ProjectBriefsProjectBriefGidBody({"param1": "value1", "param2": "value2",}) # ProjectBriefsProjectBriefGidBody | The updated fields for the project brief. -project_brief_gid = '12345' # str | Globally unique identifier for the project brief. -opt_fields = ["html_text","permalink_url","project","project.name","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a project brief - api_response = api_instance.update_project_brief(body, project_brief_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectBriefsApi->update_project_brief: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ProjectBriefsProjectBriefGidBody**](ProjectBriefsProjectBriefGidBody.md)| The updated fields for the project brief. | - **project_brief_gid** | **str**| Globally unique identifier for the project brief. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectBriefResponseData**](ProjectBriefResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/ProjectBriefsApi.yaml b/docs/ProjectBriefsApi.yaml deleted file mode 100644 index 6adf3599..00000000 --- a/docs/ProjectBriefsApi.yaml +++ /dev/null @@ -1,86 +0,0 @@ -ProjectBriefsApi: - create_project_brief: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectBriefsApi(api_client) - body = asana.ProjectGidProjectBriefsBody({"param1": "value1", "param2": "value2",}) # ProjectGidProjectBriefsBody | The project brief to create. - project_gid = '1331' # str | Globally unique identifier for the project. - opt_fields = ["html_text","permalink_url","project","project.name","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a project brief - api_response = api_instance.create_project_brief(body, project_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectBriefsApi->create_project_brief: %s\n" % e) - delete_project_brief: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectBriefsApi(api_client) - project_brief_gid = '12345' # str | Globally unique identifier for the project brief. - - try: - # Delete a project brief - api_response = api_instance.delete_project_brief(project_brief_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectBriefsApi->delete_project_brief: %s\n" % e) - get_project_brief: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectBriefsApi(api_client) - project_brief_gid = '12345' # str | Globally unique identifier for the project brief. - opt_fields = ["html_text","permalink_url","project","project.name","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a project brief - api_response = api_instance.get_project_brief(project_brief_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectBriefsApi->get_project_brief: %s\n" % e) - update_project_brief: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectBriefsApi(api_client) - body = asana.ProjectBriefsProjectBriefGidBody({"param1": "value1", "param2": "value2",}) # ProjectBriefsProjectBriefGidBody | The updated fields for the project brief. - project_brief_gid = '12345' # str | Globally unique identifier for the project brief. - opt_fields = ["html_text","permalink_url","project","project.name","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a project brief - api_response = api_instance.update_project_brief(body, project_brief_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectBriefsApi->update_project_brief: %s\n" % e) diff --git a/docs/ProjectBriefsProjectBriefGidBody.md b/docs/ProjectBriefsProjectBriefGidBody.md deleted file mode 100644 index 91ee79a6..00000000 --- a/docs/ProjectBriefsProjectBriefGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectBriefsProjectBriefGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectBriefRequest**](ProjectBriefRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectCompact.md b/docs/ProjectCompact.md deleted file mode 100644 index b816e824..00000000 --- a/docs/ProjectCompact.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectDuplicateRequest.md b/docs/ProjectDuplicateRequest.md deleted file mode 100644 index b9b96dcc..00000000 --- a/docs/ProjectDuplicateRequest.md +++ /dev/null @@ -1,12 +0,0 @@ -# ProjectDuplicateRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **str** | The name of the new project. | -**team** | **str** | Sets the team of the new project. If team is not defined, the new project will be in the same team as the the original project. | [optional] -**include** | **str** | A comma-separated list of elements that will be duplicated to the new project. Tasks are always included. ##### Fields - forms - members - notes - task_assignee - task_attachments - task_dates - task_dependencies - task_followers - task_notes - task_projects - task_subtasks - task_tags | [optional] -**schedule_dates** | [**ProjectDuplicateRequestScheduleDates**](ProjectDuplicateRequestScheduleDates.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectDuplicateRequestScheduleDates.md b/docs/ProjectDuplicateRequestScheduleDates.md deleted file mode 100644 index 61bbf74a..00000000 --- a/docs/ProjectDuplicateRequestScheduleDates.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectDuplicateRequestScheduleDates - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**should_skip_weekends** | **bool** | Determines if the auto-shifted dates should skip weekends. | -**due_on** | **str** | Sets the last due date in the duplicated project to the given date. The rest of the due dates will be offset by the same amount as the due dates in the original project. | [optional] -**start_on** | **str** | Sets the first start date in the duplicated project to the given date. The rest of the start dates will be offset by the same amount as the start dates in the original project. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectGidAddCustomFieldSettingBody.md b/docs/ProjectGidAddCustomFieldSettingBody.md deleted file mode 100644 index e1ccc8cd..00000000 --- a/docs/ProjectGidAddCustomFieldSettingBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectGidAddCustomFieldSettingBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**AddCustomFieldSettingRequest**](AddCustomFieldSettingRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectGidAddFollowersBody.md b/docs/ProjectGidAddFollowersBody.md deleted file mode 100644 index 5f87fe20..00000000 --- a/docs/ProjectGidAddFollowersBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectGidAddFollowersBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**AddFollowersRequest**](AddFollowersRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectGidAddMembersBody.md b/docs/ProjectGidAddMembersBody.md deleted file mode 100644 index 6d700d60..00000000 --- a/docs/ProjectGidAddMembersBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectGidAddMembersBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**AddMembersRequest**](AddMembersRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectGidDuplicateBody.md b/docs/ProjectGidDuplicateBody.md deleted file mode 100644 index 2aa8793a..00000000 --- a/docs/ProjectGidDuplicateBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectGidDuplicateBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectDuplicateRequest**](ProjectDuplicateRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectGidProjectBriefsBody.md b/docs/ProjectGidProjectBriefsBody.md deleted file mode 100644 index abe70627..00000000 --- a/docs/ProjectGidProjectBriefsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectGidProjectBriefsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectBriefRequest**](ProjectBriefRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectGidProjectStatusesBody.md b/docs/ProjectGidProjectStatusesBody.md deleted file mode 100644 index 8f3cd148..00000000 --- a/docs/ProjectGidProjectStatusesBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectGidProjectStatusesBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectStatusRequest**](ProjectStatusRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectGidRemoveCustomFieldSettingBody.md b/docs/ProjectGidRemoveCustomFieldSettingBody.md deleted file mode 100644 index 3623ad86..00000000 --- a/docs/ProjectGidRemoveCustomFieldSettingBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectGidRemoveCustomFieldSettingBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**RemoveCustomFieldSettingRequest**](RemoveCustomFieldSettingRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectGidRemoveFollowersBody.md b/docs/ProjectGidRemoveFollowersBody.md deleted file mode 100644 index 0ff3fc47..00000000 --- a/docs/ProjectGidRemoveFollowersBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectGidRemoveFollowersBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**RemoveFollowersRequest**](RemoveFollowersRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectGidRemoveMembersBody.md b/docs/ProjectGidRemoveMembersBody.md deleted file mode 100644 index 79be9b5f..00000000 --- a/docs/ProjectGidRemoveMembersBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectGidRemoveMembersBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**RemoveMembersRequest**](RemoveMembersRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectGidSaveAsTemplateBody.md b/docs/ProjectGidSaveAsTemplateBody.md deleted file mode 100644 index 3f4bd01c..00000000 --- a/docs/ProjectGidSaveAsTemplateBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectGidSaveAsTemplateBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectSaveAsTemplateRequest**](ProjectSaveAsTemplateRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectGidSectionsBody.md b/docs/ProjectGidSectionsBody.md deleted file mode 100644 index 70814106..00000000 --- a/docs/ProjectGidSectionsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectGidSectionsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**SectionRequest**](SectionRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectMembershipBase.md b/docs/ProjectMembershipBase.md deleted file mode 100644 index 319d5abc..00000000 --- a/docs/ProjectMembershipBase.md +++ /dev/null @@ -1,13 +0,0 @@ -# ProjectMembershipBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**parent** | [**JobBaseNewProject**](JobBaseNewProject.md) | | [optional] -**member** | [**MembershipCompactMember**](MembershipCompactMember.md) | | [optional] -**access_level** | **str** | Whether the member has admin, editor, commenter, or viewer access to the project. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectMembershipCompact.md b/docs/ProjectMembershipCompact.md deleted file mode 100644 index 93d0e7d8..00000000 --- a/docs/ProjectMembershipCompact.md +++ /dev/null @@ -1,13 +0,0 @@ -# ProjectMembershipCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**parent** | [**JobBaseNewProject**](JobBaseNewProject.md) | | [optional] -**member** | [**MembershipCompactMember**](MembershipCompactMember.md) | | [optional] -**access_level** | **str** | Whether the member has admin, editor, commenter, or viewer access to the project. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectMembershipCompactArray.md b/docs/ProjectMembershipCompactArray.md deleted file mode 100644 index 5dacbac4..00000000 --- a/docs/ProjectMembershipCompactArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# ProjectMembershipCompactArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[ProjectMembershipCompact]**](ProjectMembershipCompact.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectMembershipCompactResponse.md b/docs/ProjectMembershipCompactResponse.md deleted file mode 100644 index 0a19e599..00000000 --- a/docs/ProjectMembershipCompactResponse.md +++ /dev/null @@ -1,14 +0,0 @@ -# ProjectMembershipCompactResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**parent** | [**JobBaseNewProject**](JobBaseNewProject.md) | | [optional] -**member** | [**MembershipCompactMember**](MembershipCompactMember.md) | | [optional] -**access_level** | **str** | Whether the member has admin, editor, commenter, or viewer access to the project. | [optional] -**resource_subtype** | **str** | Type of the membership. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectMembershipCompactResponseData.md b/docs/ProjectMembershipCompactResponseData.md deleted file mode 100644 index 73e1c1d2..00000000 --- a/docs/ProjectMembershipCompactResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectMembershipCompactResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectMembershipCompactResponse**](ProjectMembershipCompactResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectMembershipNormalResponse.md b/docs/ProjectMembershipNormalResponse.md deleted file mode 100644 index ef21c97a..00000000 --- a/docs/ProjectMembershipNormalResponse.md +++ /dev/null @@ -1,16 +0,0 @@ -# ProjectMembershipNormalResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**parent** | [**JobBaseNewProject**](JobBaseNewProject.md) | | [optional] -**member** | [**MembershipCompactMember**](MembershipCompactMember.md) | | [optional] -**access_level** | **str** | Whether the member has admin, editor, commenter, or viewer access to the project. | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**project** | [**JobBaseNewProject**](JobBaseNewProject.md) | | [optional] -**write_access** | **str** | Whether the member has full access or comment-only access to the project. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectMembershipNormalResponseData.md b/docs/ProjectMembershipNormalResponseData.md deleted file mode 100644 index 276802ab..00000000 --- a/docs/ProjectMembershipNormalResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectMembershipNormalResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectMembershipNormalResponse**](ProjectMembershipNormalResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectMembershipResponse.md b/docs/ProjectMembershipResponse.md deleted file mode 100644 index be8c4530..00000000 --- a/docs/ProjectMembershipResponse.md +++ /dev/null @@ -1,15 +0,0 @@ -# ProjectMembershipResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | Type of the membership. | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**project** | [**JobBaseNewProject**](JobBaseNewProject.md) | | [optional] -**member** | [**ProjectMembershipResponseMember**](ProjectMembershipResponseMember.md) | | [optional] -**write_access** | **str** | Whether the member has full access or comment-only access to the project. | [optional] -**access_level** | **str** | Whether the member has admin, editor, commenter, or viewer access to the project. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectMembershipResponseArray.md b/docs/ProjectMembershipResponseArray.md deleted file mode 100644 index e65328b4..00000000 --- a/docs/ProjectMembershipResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# ProjectMembershipResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[ProjectMembershipResponse]**](ProjectMembershipResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectMembershipResponseData.md b/docs/ProjectMembershipResponseData.md deleted file mode 100644 index 6ba4e539..00000000 --- a/docs/ProjectMembershipResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectMembershipResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectMembershipResponse**](ProjectMembershipResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectMembershipResponseMember.md b/docs/ProjectMembershipResponseMember.md deleted file mode 100644 index cfa517b4..00000000 --- a/docs/ProjectMembershipResponseMember.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectMembershipResponseMember - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The type of the member (team or user) | [optional] -**name** | **str** | The name of the member | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectMembershipsApi.md b/docs/ProjectMembershipsApi.md deleted file mode 100644 index 13defc8c..00000000 --- a/docs/ProjectMembershipsApi.md +++ /dev/null @@ -1,121 +0,0 @@ -# asana.ProjectMembershipsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**get_project_membership**](ProjectMembershipsApi.md#get_project_membership) | **GET** /project_memberships/{project_membership_gid} | Get a project membership -[**get_project_memberships_for_project**](ProjectMembershipsApi.md#get_project_memberships_for_project) | **GET** /projects/{project_gid}/project_memberships | Get memberships from a project - -# **get_project_membership** -> ProjectMembershipNormalResponseData get_project_membership(project_membership_gid, opt_fields=opt_fields) - -Get a project membership - -Returns the complete project record for a single project membership. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectMembershipsApi(api_client) -project_membership_gid = '1331' # str | -opt_fields = ["access_level","member","member.name","parent","parent.name","project","project.name","user","user.name","write_access"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a project membership - api_response = api_instance.get_project_membership(project_membership_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectMembershipsApi->get_project_membership: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_membership_gid** | **str**| | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectMembershipNormalResponseData**](ProjectMembershipNormalResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_project_memberships_for_project** -> ProjectMembershipCompactArray get_project_memberships_for_project(project_gid, user=user, limit=limit, offset=offset, opt_fields=opt_fields) - -Get memberships from a project - -Returns the compact project membership records for the project. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectMembershipsApi(api_client) -project_gid = '1331' # str | Globally unique identifier for the project. -user = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (optional) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["access_level","member","member.name","offset","parent","parent.name","path","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get memberships from a project - api_response = api_instance.get_project_memberships_for_project(project_gid, user=user, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectMembershipsApi->get_project_memberships_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_gid** | **str**| Globally unique identifier for the project. | - **user** | **str**| A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | [optional] - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectMembershipCompactArray**](ProjectMembershipCompactArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/ProjectMembershipsApi.yaml b/docs/ProjectMembershipsApi.yaml deleted file mode 100644 index 37e0f0ab..00000000 --- a/docs/ProjectMembershipsApi.yaml +++ /dev/null @@ -1,46 +0,0 @@ -ProjectMembershipsApi: - get_project_membership: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectMembershipsApi(api_client) - project_membership_gid = '1331' # str | - opt_fields = ["access_level","member","member.name","parent","parent.name","project","project.name","user","user.name","write_access"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a project membership - api_response = api_instance.get_project_membership(project_membership_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectMembershipsApi->get_project_membership: %s\n" % e) - get_project_memberships_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectMembershipsApi(api_client) - project_gid = '1331' # str | Globally unique identifier for the project. - user = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (optional) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["access_level","member","member.name","offset","parent","parent.name","path","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get memberships from a project - api_response = api_instance.get_project_memberships_for_project(project_gid, user=user, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectMembershipsApi->get_project_memberships_for_project: %s\n" % e) diff --git a/docs/ProjectRequest.md b/docs/ProjectRequest.md deleted file mode 100644 index ca00d477..00000000 --- a/docs/ProjectRequest.md +++ /dev/null @@ -1,34 +0,0 @@ -# ProjectRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] -**archived** | **bool** | True if the project is archived, false if not. Archived projects do not show in the UI by default and may be treated differently for queries. | [optional] -**color** | **str** | Color of the project. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**current_status** | [**ProjectBaseCurrentStatus**](ProjectBaseCurrentStatus.md) | | [optional] -**current_status_update** | [**ProjectBaseCurrentStatusUpdate**](ProjectBaseCurrentStatusUpdate.md) | | [optional] -**custom_field_settings** | [**list[PortfolioResponseCustomFieldSettings]**](PortfolioResponseCustomFieldSettings.md) | Array of Custom Field Settings (in compact form). | [optional] -**default_view** | **str** | The default view (list, board, calendar, or timeline) of a project. | [optional] -**due_date** | **date** | *Deprecated: new integrations should prefer the `due_on` field.* | [optional] -**due_on** | **date** | The day on which this project is due. This takes a date with format YYYY-MM-DD. | [optional] -**html_notes** | **str** | [Opt In](/docs/inputoutput-options). The notes of the project with formatting as HTML. | [optional] -**members** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | Array of users who are members of this project. | [optional] -**modified_at** | **datetime** | The time at which this project was last modified. *Note: This does not currently reflect any changes in associations such as tasks or comments that may have been added or removed from the project.* | [optional] -**notes** | **str** | Free-form textual information associated with the project (ie., its description). | [optional] -**public** | **bool** | True if the project is public to its team. | [optional] -**start_on** | **date** | The day on which work for this project begins, or null if the project has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* | [optional] -**default_access_level** | **str** | The default access for users or teams who join or are added as members to the project. | [optional] -**minimum_access_level_for_customization** | **str** | The minimum access level needed for project members to modify this project's workflow and appearance. | [optional] -**minimum_access_level_for_sharing** | **str** | The minimum access level needed for project members to share the project and manage project memberships. | [optional] -**custom_fields** | **dict(str, str)** | An object where each key is the GID of a custom field and its corresponding value is either an enum GID, string, number, or object (depending on the custom field type). See the [custom fields guide](/docs/custom-fields-guide) for details on creating and updating custom field values. | [optional] -**followers** | **str** | *Create-only*. Comma separated string of users. Followers are a subset of members who have opted in to receive \"tasks added\" notifications for a project. | [optional] -**owner** | **str** | The current owner of the project, may be null. | [optional] -**team** | **str** | The team that this project is shared with. | [optional] -**workspace** | **str** | The `gid` of a workspace. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectResponse.md b/docs/ProjectResponse.md deleted file mode 100644 index e241534f..00000000 --- a/docs/ProjectResponse.md +++ /dev/null @@ -1,41 +0,0 @@ -# ProjectResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] -**archived** | **bool** | True if the project is archived, false if not. Archived projects do not show in the UI by default and may be treated differently for queries. | [optional] -**color** | **str** | Color of the project. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**current_status** | [**ProjectBaseCurrentStatus**](ProjectBaseCurrentStatus.md) | | [optional] -**current_status_update** | [**ProjectBaseCurrentStatusUpdate**](ProjectBaseCurrentStatusUpdate.md) | | [optional] -**custom_field_settings** | [**list[PortfolioResponseCustomFieldSettings]**](PortfolioResponseCustomFieldSettings.md) | Array of Custom Field Settings (in compact form). | [optional] -**default_view** | **str** | The default view (list, board, calendar, or timeline) of a project. | [optional] -**due_date** | **date** | *Deprecated: new integrations should prefer the `due_on` field.* | [optional] -**due_on** | **date** | The day on which this project is due. This takes a date with format YYYY-MM-DD. | [optional] -**html_notes** | **str** | [Opt In](/docs/inputoutput-options). The notes of the project with formatting as HTML. | [optional] -**members** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | Array of users who are members of this project. | [optional] -**modified_at** | **datetime** | The time at which this project was last modified. *Note: This does not currently reflect any changes in associations such as tasks or comments that may have been added or removed from the project.* | [optional] -**notes** | **str** | Free-form textual information associated with the project (ie., its description). | [optional] -**public** | **bool** | True if the project is public to its team. | [optional] -**start_on** | **date** | The day on which work for this project begins, or null if the project has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* | [optional] -**default_access_level** | **str** | The default access for users or teams who join or are added as members to the project. | [optional] -**minimum_access_level_for_customization** | **str** | The minimum access level needed for project members to modify this project's workflow and appearance. | [optional] -**minimum_access_level_for_sharing** | **str** | The minimum access level needed for project members to share the project and manage project memberships. | [optional] -**custom_fields** | [**list[PortfolioResponseCustomFields]**](PortfolioResponseCustomFields.md) | Array of Custom Fields. | [optional] -**completed** | **bool** | True if the project is currently marked complete, false if not. | [optional] -**completed_at** | **datetime** | The time at which this project was completed, or null if the project is not completed. | [optional] -**completed_by** | [**ProjectResponseCompletedBy**](ProjectResponseCompletedBy.md) | | [optional] -**followers** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | Array of users following this project. Followers are a subset of members who have opted in to receive \"tasks added\" notifications for a project. | [optional] -**owner** | **AllOfProjectResponseOwner** | The current owner of the project, may be null. | [optional] -**team** | [**ProjectResponseTeam**](ProjectResponseTeam.md) | | [optional] -**icon** | **str** | The icon for a project. | [optional] -**permalink_url** | **str** | A url that points directly to the object within Asana. | [optional] -**project_brief** | [**ProjectResponseProjectBrief**](ProjectResponseProjectBrief.md) | | [optional] -**created_from_template** | [**ProjectResponseCreatedFromTemplate**](ProjectResponseCreatedFromTemplate.md) | | [optional] -**workspace** | [**ProjectResponseWorkspace**](ProjectResponseWorkspace.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectResponseArray.md b/docs/ProjectResponseArray.md deleted file mode 100644 index f3b15f3e..00000000 --- a/docs/ProjectResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# ProjectResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[ProjectResponse]**](ProjectResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectResponseCompletedBy.md b/docs/ProjectResponseCompletedBy.md deleted file mode 100644 index fcde71e7..00000000 --- a/docs/ProjectResponseCompletedBy.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectResponseCompletedBy - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | *Read-only except when same user as requester*. The user’s name. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectResponseCreatedFromTemplate.md b/docs/ProjectResponseCreatedFromTemplate.md deleted file mode 100644 index f990fac8..00000000 --- a/docs/ProjectResponseCreatedFromTemplate.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectResponseCreatedFromTemplate - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project template. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectResponseData.md b/docs/ProjectResponseData.md deleted file mode 100644 index 781c04d4..00000000 --- a/docs/ProjectResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectResponse**](ProjectResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectResponseProjectBrief.md b/docs/ProjectResponseProjectBrief.md deleted file mode 100644 index edac5e6c..00000000 --- a/docs/ProjectResponseProjectBrief.md +++ /dev/null @@ -1,10 +0,0 @@ -# ProjectResponseProjectBrief - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectResponseTeam.md b/docs/ProjectResponseTeam.md deleted file mode 100644 index 2aa3c57e..00000000 --- a/docs/ProjectResponseTeam.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectResponseTeam - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the team. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectResponseWorkspace.md b/docs/ProjectResponseWorkspace.md deleted file mode 100644 index 17f5cf30..00000000 --- a/docs/ProjectResponseWorkspace.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectResponseWorkspace - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the workspace. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectSaveAsTemplateRequest.md b/docs/ProjectSaveAsTemplateRequest.md deleted file mode 100644 index 38c7467d..00000000 --- a/docs/ProjectSaveAsTemplateRequest.md +++ /dev/null @@ -1,12 +0,0 @@ -# ProjectSaveAsTemplateRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **str** | The name of the new project template. | -**team** | **str** | Sets the team of the new project template. If the project exists in an organization, specify team and not workspace. | [optional] -**workspace** | **str** | Sets the workspace of the new project template. Only specify workspace if the project exists in a workspace. | [optional] -**public** | **bool** | Sets the project template to public to its team. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectSectionInsertRequest.md b/docs/ProjectSectionInsertRequest.md deleted file mode 100644 index 7a18a34a..00000000 --- a/docs/ProjectSectionInsertRequest.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectSectionInsertRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**section** | **str** | The section to reorder. | -**before_section** | **str** | Insert the given section immediately before the section specified by this parameter. | [optional] -**after_section** | **str** | Insert the given section immediately after the section specified by this parameter. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectStatusBase.md b/docs/ProjectStatusBase.md deleted file mode 100644 index f5eaec7c..00000000 --- a/docs/ProjectStatusBase.md +++ /dev/null @@ -1,14 +0,0 @@ -# ProjectStatusBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the project status update. | [optional] -**text** | **str** | The text content of the status update. | [optional] -**html_text** | **str** | [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. | [optional] -**color** | **str** | The color associated with the status update. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectStatusCompact.md b/docs/ProjectStatusCompact.md deleted file mode 100644 index bd2b5ac4..00000000 --- a/docs/ProjectStatusCompact.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectStatusCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the project status update. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectStatusRequest.md b/docs/ProjectStatusRequest.md deleted file mode 100644 index e82595b8..00000000 --- a/docs/ProjectStatusRequest.md +++ /dev/null @@ -1,14 +0,0 @@ -# ProjectStatusRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the project status update. | [optional] -**text** | **str** | The text content of the status update. | [optional] -**html_text** | **str** | [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. | [optional] -**color** | **str** | The color associated with the status update. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectStatusResponse.md b/docs/ProjectStatusResponse.md deleted file mode 100644 index 5f293395..00000000 --- a/docs/ProjectStatusResponse.md +++ /dev/null @@ -1,18 +0,0 @@ -# ProjectStatusResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the project status update. | [optional] -**text** | **str** | The text content of the status update. | [optional] -**html_text** | **str** | [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. | [optional] -**color** | **str** | The color associated with the status update. | [optional] -**author** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**created_by** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**modified_at** | **datetime** | The time at which this project status was last modified. *Note: This does not currently reflect any changes in associations such as comments that may have been added or removed from the project status.* | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectStatusResponseArray.md b/docs/ProjectStatusResponseArray.md deleted file mode 100644 index f6fabe24..00000000 --- a/docs/ProjectStatusResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# ProjectStatusResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[ProjectStatusResponse]**](ProjectStatusResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectStatusResponseData.md b/docs/ProjectStatusResponseData.md deleted file mode 100644 index dd842280..00000000 --- a/docs/ProjectStatusResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectStatusResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectStatusResponse**](ProjectStatusResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectStatusesApi.md b/docs/ProjectStatusesApi.md deleted file mode 100644 index 0b567317..00000000 --- a/docs/ProjectStatusesApi.md +++ /dev/null @@ -1,227 +0,0 @@ -# asana.ProjectStatusesApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_project_status_for_project**](ProjectStatusesApi.md#create_project_status_for_project) | **POST** /projects/{project_gid}/project_statuses | Create a project status -[**delete_project_status**](ProjectStatusesApi.md#delete_project_status) | **DELETE** /project_statuses/{project_status_gid} | Delete a project status -[**get_project_status**](ProjectStatusesApi.md#get_project_status) | **GET** /project_statuses/{project_status_gid} | Get a project status -[**get_project_statuses_for_project**](ProjectStatusesApi.md#get_project_statuses_for_project) | **GET** /projects/{project_gid}/project_statuses | Get statuses from a project - -# **create_project_status_for_project** -> ProjectStatusResponseData create_project_status_for_project(body, project_gid, opt_fields=opt_fields) - -Create a project status - -*Deprecated: new integrations should prefer the `/status_updates` route.* Creates a new status update on the project. Returns the full record of the newly created project status update. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectStatusesApi(api_client) -body = asana.ProjectGidProjectStatusesBody({"param1": "value1", "param2": "value2",}) # ProjectGidProjectStatusesBody | The project status to create. -project_gid = '1331' # str | Globally unique identifier for the project. -opt_fields = ["author","author.name","color","created_at","created_by","created_by.name","html_text","modified_at","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a project status - api_response = api_instance.create_project_status_for_project(body, project_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectStatusesApi->create_project_status_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ProjectGidProjectStatusesBody**](ProjectGidProjectStatusesBody.md)| The project status to create. | - **project_gid** | **str**| Globally unique identifier for the project. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectStatusResponseData**](ProjectStatusResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_project_status** -> EmptyResponseData delete_project_status(project_status_gid) - -Delete a project status - -*Deprecated: new integrations should prefer the `/status_updates/{status_gid}` route.* Deletes a specific, existing project status update. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectStatusesApi(api_client) -project_status_gid = '321654' # str | The project status update to get. - -try: - # Delete a project status - api_response = api_instance.delete_project_status(project_status_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectStatusesApi->delete_project_status: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_status_gid** | **str**| The project status update to get. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_project_status** -> ProjectStatusResponseData get_project_status(project_status_gid, opt_fields=opt_fields) - -Get a project status - -*Deprecated: new integrations should prefer the `/status_updates/{status_gid}` route.* Returns the complete record for a single status update. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectStatusesApi(api_client) -project_status_gid = '321654' # str | The project status update to get. -opt_fields = ["author","author.name","color","created_at","created_by","created_by.name","html_text","modified_at","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a project status - api_response = api_instance.get_project_status(project_status_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectStatusesApi->get_project_status: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_status_gid** | **str**| The project status update to get. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectStatusResponseData**](ProjectStatusResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_project_statuses_for_project** -> ProjectStatusResponseArray get_project_statuses_for_project(project_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get statuses from a project - -*Deprecated: new integrations should prefer the `/status_updates` route.* Returns the compact project status update records for all updates on the project. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectStatusesApi(api_client) -project_gid = '1331' # str | Globally unique identifier for the project. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["author","author.name","color","created_at","created_by","created_by.name","html_text","modified_at","offset","path","text","title","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get statuses from a project - api_response = api_instance.get_project_statuses_for_project(project_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectStatusesApi->get_project_statuses_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_gid** | **str**| Globally unique identifier for the project. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectStatusResponseArray**](ProjectStatusResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/ProjectStatusesApi.yaml b/docs/ProjectStatusesApi.yaml deleted file mode 100644 index 213608e9..00000000 --- a/docs/ProjectStatusesApi.yaml +++ /dev/null @@ -1,87 +0,0 @@ -ProjectStatusesApi: - create_project_status_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectStatusesApi(api_client) - body = asana.ProjectGidProjectStatusesBody({"param1": "value1", "param2": "value2",}) # ProjectGidProjectStatusesBody | The project status to create. - project_gid = '1331' # str | Globally unique identifier for the project. - opt_fields = ["author","author.name","color","created_at","created_by","created_by.name","html_text","modified_at","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a project status - api_response = api_instance.create_project_status_for_project(body, project_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectStatusesApi->create_project_status_for_project: %s\n" % e) - delete_project_status: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectStatusesApi(api_client) - project_status_gid = '321654' # str | The project status update to get. - - try: - # Delete a project status - api_response = api_instance.delete_project_status(project_status_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectStatusesApi->delete_project_status: %s\n" % e) - get_project_status: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectStatusesApi(api_client) - project_status_gid = '321654' # str | The project status update to get. - opt_fields = ["author","author.name","color","created_at","created_by","created_by.name","html_text","modified_at","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a project status - api_response = api_instance.get_project_status(project_status_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectStatusesApi->get_project_status: %s\n" % e) - get_project_statuses_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectStatusesApi(api_client) - project_gid = '1331' # str | Globally unique identifier for the project. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["author","author.name","color","created_at","created_by","created_by.name","html_text","modified_at","offset","path","text","title","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get statuses from a project - api_response = api_instance.get_project_statuses_for_project(project_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectStatusesApi->get_project_statuses_for_project: %s\n" % e) diff --git a/docs/ProjectTemplateBase.md b/docs/ProjectTemplateBase.md deleted file mode 100644 index f69ae0de..00000000 --- a/docs/ProjectTemplateBase.md +++ /dev/null @@ -1,19 +0,0 @@ -# ProjectTemplateBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project template. | [optional] -**description** | **str** | Free-form textual information associated with the project template | [optional] -**html_description** | **str** | The description of the project template with formatting as HTML. | [optional] -**public** | **bool** | True if the project template is public to its team. | [optional] -**owner** | **AllOfProjectTemplateBaseOwner** | The current owner of the project template, may be null. | [optional] -**team** | [**ProjectTemplateBaseTeam**](ProjectTemplateBaseTeam.md) | | [optional] -**requested_dates** | [**list[ProjectTemplateBaseRequestedDates]**](ProjectTemplateBaseRequestedDates.md) | Array of date variables in this project template. Calendar dates must be provided for these variables when instantiating a project. | [optional] -**color** | **str** | Color of the project template. | [optional] -**requested_roles** | [**list[ProjectTemplateBaseRequestedRoles]**](ProjectTemplateBaseRequestedRoles.md) | Array of template roles in this project template. User Ids can be provided for these variables when instantiating a project to assign template tasks to the user. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectTemplateBaseRequestedDates.md b/docs/ProjectTemplateBaseRequestedDates.md deleted file mode 100644 index 9c50390e..00000000 --- a/docs/ProjectTemplateBaseRequestedDates.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectTemplateBaseRequestedDates - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the date field in the project template. A value of `1` refers to the project start date, while `2` refers to the project due date. | [optional] -**name** | **str** | The name of the date variable. | [optional] -**description** | **str** | The description of what the date variable is used for when instantiating a project. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectTemplateBaseRequestedRoles.md b/docs/ProjectTemplateBaseRequestedRoles.md deleted file mode 100644 index 1c89e61d..00000000 --- a/docs/ProjectTemplateBaseRequestedRoles.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectTemplateBaseRequestedRoles - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the template role. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectTemplateBaseTeam.md b/docs/ProjectTemplateBaseTeam.md deleted file mode 100644 index 5410ffb3..00000000 --- a/docs/ProjectTemplateBaseTeam.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectTemplateBaseTeam - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the team. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectTemplateCompact.md b/docs/ProjectTemplateCompact.md deleted file mode 100644 index 1a7d8d5b..00000000 --- a/docs/ProjectTemplateCompact.md +++ /dev/null @@ -1,11 +0,0 @@ -# ProjectTemplateCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project template. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectTemplateGidInstantiateProjectBody.md b/docs/ProjectTemplateGidInstantiateProjectBody.md deleted file mode 100644 index 997bd33b..00000000 --- a/docs/ProjectTemplateGidInstantiateProjectBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectTemplateGidInstantiateProjectBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectTemplateInstantiateProjectRequest**](ProjectTemplateInstantiateProjectRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectTemplateInstantiateProjectRequest.md b/docs/ProjectTemplateInstantiateProjectRequest.md deleted file mode 100644 index 9059c29e..00000000 --- a/docs/ProjectTemplateInstantiateProjectRequest.md +++ /dev/null @@ -1,14 +0,0 @@ -# ProjectTemplateInstantiateProjectRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **str** | The name of the new project. | -**team** | **str** | *Optional*. Sets the team of the new project. If the project template exists in an _organization_, you may specify a value for `team`. If no value is provided then it defaults to the same team as the project template. | [optional] -**public** | **bool** | Sets the project to public to its team. | [optional] -**is_strict** | **bool** | *Optional*. If set to `true`, the endpoint returns an \"Unprocessable Entity\" error if you fail to provide a calendar date value for any date variable. If set to `false`, a default date is used for each unfulfilled date variable (e.g., the current date is used as the Start Date of a project). | [optional] -**requested_dates** | [**list[ProjectTemplateInstantiateProjectRequestRequestedDates]**](ProjectTemplateInstantiateProjectRequestRequestedDates.md) | Array of mappings of date variables to calendar dates. | [optional] -**requested_roles** | [**list[ProjectTemplateInstantiateProjectRequestRequestedRoles]**](ProjectTemplateInstantiateProjectRequestRequestedRoles.md) | Array of mappings of template roles to user ids | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectTemplateInstantiateProjectRequestRequestedDates.md b/docs/ProjectTemplateInstantiateProjectRequestRequestedDates.md deleted file mode 100644 index 0a694818..00000000 --- a/docs/ProjectTemplateInstantiateProjectRequestRequestedDates.md +++ /dev/null @@ -1,10 +0,0 @@ -# ProjectTemplateInstantiateProjectRequestRequestedDates - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the date field in the project template. A value of `1` refers to the project start date, while `2` refers to the project due date. | [optional] -**value** | **datetime** | The date with which the date variable should be replaced when instantiating a project. This takes a date with `YYYY-MM-DD` format. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectTemplateInstantiateProjectRequestRequestedRoles.md b/docs/ProjectTemplateInstantiateProjectRequestRequestedRoles.md deleted file mode 100644 index 668b3403..00000000 --- a/docs/ProjectTemplateInstantiateProjectRequestRequestedRoles.md +++ /dev/null @@ -1,10 +0,0 @@ -# ProjectTemplateInstantiateProjectRequestRequestedRoles - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the template role in the project template. | [optional] -**value** | **str** | The user id that should be assigned to the template role. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectTemplateResponse.md b/docs/ProjectTemplateResponse.md deleted file mode 100644 index 5c22b892..00000000 --- a/docs/ProjectTemplateResponse.md +++ /dev/null @@ -1,19 +0,0 @@ -# ProjectTemplateResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project template. | [optional] -**description** | **str** | Free-form textual information associated with the project template | [optional] -**html_description** | **str** | The description of the project template with formatting as HTML. | [optional] -**public** | **bool** | True if the project template is public to its team. | [optional] -**owner** | **AllOfProjectTemplateResponseOwner** | The current owner of the project template, may be null. | [optional] -**team** | [**ProjectTemplateBaseTeam**](ProjectTemplateBaseTeam.md) | | [optional] -**requested_dates** | [**list[ProjectTemplateBaseRequestedDates]**](ProjectTemplateBaseRequestedDates.md) | Array of date variables in this project template. Calendar dates must be provided for these variables when instantiating a project. | [optional] -**color** | **str** | Color of the project template. | [optional] -**requested_roles** | [**list[ProjectTemplateBaseRequestedRoles]**](ProjectTemplateBaseRequestedRoles.md) | Array of template roles in this project template. User Ids can be provided for these variables when instantiating a project to assign template tasks to the user. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectTemplateResponseArray.md b/docs/ProjectTemplateResponseArray.md deleted file mode 100644 index 33aaac4b..00000000 --- a/docs/ProjectTemplateResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# ProjectTemplateResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[ProjectTemplateResponse]**](ProjectTemplateResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectTemplateResponseData.md b/docs/ProjectTemplateResponseData.md deleted file mode 100644 index ad8cfb0f..00000000 --- a/docs/ProjectTemplateResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectTemplateResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectTemplateResponse**](ProjectTemplateResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectTemplatesApi.md b/docs/ProjectTemplatesApi.md deleted file mode 100644 index 0ca5ff12..00000000 --- a/docs/ProjectTemplatesApi.md +++ /dev/null @@ -1,287 +0,0 @@ -# asana.ProjectTemplatesApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**delete_project_template**](ProjectTemplatesApi.md#delete_project_template) | **DELETE** /project_templates/{project_template_gid} | Delete a project template -[**get_project_template**](ProjectTemplatesApi.md#get_project_template) | **GET** /project_templates/{project_template_gid} | Get a project template -[**get_project_templates**](ProjectTemplatesApi.md#get_project_templates) | **GET** /project_templates | Get multiple project templates -[**get_project_templates_for_team**](ProjectTemplatesApi.md#get_project_templates_for_team) | **GET** /teams/{team_gid}/project_templates | Get a team's project templates -[**instantiate_project**](ProjectTemplatesApi.md#instantiate_project) | **POST** /project_templates/{project_template_gid}/instantiateProject | Instantiate a project from a project template - -# **delete_project_template** -> EmptyResponseData delete_project_template(project_template_gid) - -Delete a project template - -A specific, existing project template can be deleted by making a DELETE request on the URL for that project template. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectTemplatesApi(api_client) -project_template_gid = '1331' # str | Globally unique identifier for the project template. - -try: - # Delete a project template - api_response = api_instance.delete_project_template(project_template_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectTemplatesApi->delete_project_template: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_template_gid** | **str**| Globally unique identifier for the project template. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_project_template** -> ProjectTemplateResponseData get_project_template(project_template_gid, opt_fields=opt_fields) - -Get a project template - -Returns the complete project template record for a single project template. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectTemplatesApi(api_client) -project_template_gid = '1331' # str | Globally unique identifier for the project template. -opt_fields = ["color","description","html_description","name","owner","public","requested_dates","requested_dates.description","requested_dates.name","requested_roles","requested_roles.name","team","team.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a project template - api_response = api_instance.get_project_template(project_template_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectTemplatesApi->get_project_template: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_template_gid** | **str**| Globally unique identifier for the project template. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectTemplateResponseData**](ProjectTemplateResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_project_templates** -> ProjectTemplateResponseArray get_project_templates(workspace=workspace, team=team, limit=limit, offset=offset, opt_fields=opt_fields) - -Get multiple project templates - -Returns the compact project template records for all project templates in the given team or workspace. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectTemplatesApi(api_client) -workspace = '12345' # str | The workspace to filter results on. (optional) -team = '14916' # str | The team to filter projects on. (optional) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["color","description","html_description","name","offset","owner","path","public","requested_dates","requested_dates.description","requested_dates.name","requested_roles","requested_roles.name","team","team.name","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get multiple project templates - api_response = api_instance.get_project_templates(workspace=workspace, team=team, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectTemplatesApi->get_project_templates: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace** | **str**| The workspace to filter results on. | [optional] - **team** | **str**| The team to filter projects on. | [optional] - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectTemplateResponseArray**](ProjectTemplateResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_project_templates_for_team** -> ProjectTemplateResponseArray get_project_templates_for_team(team_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get a team's project templates - -Returns the compact project template records for all project templates in the team. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectTemplatesApi(api_client) -team_gid = '159874' # str | Globally unique identifier for the team. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["color","description","html_description","name","offset","owner","path","public","requested_dates","requested_dates.description","requested_dates.name","requested_roles","requested_roles.name","team","team.name","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a team's project templates - api_response = api_instance.get_project_templates_for_team(team_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectTemplatesApi->get_project_templates_for_team: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **team_gid** | **str**| Globally unique identifier for the team. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectTemplateResponseArray**](ProjectTemplateResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **instantiate_project** -> JobResponseData instantiate_project(project_template_gid, body=body, opt_fields=opt_fields) - -Instantiate a project from a project template - -Creates and returns a job that will asynchronously handle the project instantiation. To form this request, it is recommended to first make a request to [get a project template](/reference/getprojecttemplate). Then, from the response, copy the `gid` from the object in the `requested_dates` array. This `gid` should be used in `requested_dates` to instantiate a project. _Note: The body of this request will differ if your workspace is an organization. To determine if your workspace is an organization, use the [is_organization](/reference/workspaces) parameter._ - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectTemplatesApi(api_client) -project_template_gid = '1331' # str | Globally unique identifier for the project template. -body = asana.ProjectTemplateGidInstantiateProjectBody({"param1": "value1", "param2": "value2",}) # ProjectTemplateGidInstantiateProjectBody | Describes the inputs used for instantiating a project, such as the resulting project's name, which team it should be created in, and values for date variables. (optional) -opt_fields = ["new_project","new_project.name","new_project_template","new_project_template.name","new_task","new_task.created_by","new_task.name","new_task.resource_subtype","resource_subtype","status"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Instantiate a project from a project template - api_response = api_instance.instantiate_project(project_template_gid, body=body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectTemplatesApi->instantiate_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_template_gid** | **str**| Globally unique identifier for the project template. | - **body** | [**ProjectTemplateGidInstantiateProjectBody**](ProjectTemplateGidInstantiateProjectBody.md)| Describes the inputs used for instantiating a project, such as the resulting project's name, which team it should be created in, and values for date variables. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**JobResponseData**](JobResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/ProjectTemplatesApi.yaml b/docs/ProjectTemplatesApi.yaml deleted file mode 100644 index 33452c53..00000000 --- a/docs/ProjectTemplatesApi.yaml +++ /dev/null @@ -1,111 +0,0 @@ -ProjectTemplatesApi: - delete_project_template: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectTemplatesApi(api_client) - project_template_gid = '1331' # str | Globally unique identifier for the project template. - - try: - # Delete a project template - api_response = api_instance.delete_project_template(project_template_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectTemplatesApi->delete_project_template: %s\n" % e) - get_project_template: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectTemplatesApi(api_client) - project_template_gid = '1331' # str | Globally unique identifier for the project template. - opt_fields = ["color","description","html_description","name","owner","public","requested_dates","requested_dates.description","requested_dates.name","requested_roles","requested_roles.name","team","team.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a project template - api_response = api_instance.get_project_template(project_template_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectTemplatesApi->get_project_template: %s\n" % e) - get_project_templates: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectTemplatesApi(api_client) - workspace = '12345' # str | The workspace to filter results on. (optional) - team = '14916' # str | The team to filter projects on. (optional) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["color","description","html_description","name","offset","owner","path","public","requested_dates","requested_dates.description","requested_dates.name","requested_roles","requested_roles.name","team","team.name","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get multiple project templates - api_response = api_instance.get_project_templates(workspace=workspace, team=team, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectTemplatesApi->get_project_templates: %s\n" % e) - get_project_templates_for_team: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectTemplatesApi(api_client) - team_gid = '159874' # str | Globally unique identifier for the team. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["color","description","html_description","name","offset","owner","path","public","requested_dates","requested_dates.description","requested_dates.name","requested_roles","requested_roles.name","team","team.name","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a team's project templates - api_response = api_instance.get_project_templates_for_team(team_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectTemplatesApi->get_project_templates_for_team: %s\n" % e) - instantiate_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectTemplatesApi(api_client) - project_template_gid = '1331' # str | Globally unique identifier for the project template. - body = asana.ProjectTemplateGidInstantiateProjectBody({"param1": "value1", "param2": "value2",}) # ProjectTemplateGidInstantiateProjectBody | Describes the inputs used for instantiating a project, such as the resulting project's name, which team it should be created in, and values for date variables. (optional) - opt_fields = ["new_project","new_project.name","new_project_template","new_project_template.name","new_task","new_task.created_by","new_task.name","new_task.resource_subtype","resource_subtype","status"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Instantiate a project from a project template - api_response = api_instance.instantiate_project(project_template_gid, body=body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectTemplatesApi->instantiate_project: %s\n" % e) diff --git a/docs/ProjectUpdateRequest.md b/docs/ProjectUpdateRequest.md deleted file mode 100644 index 8b29c17c..00000000 --- a/docs/ProjectUpdateRequest.md +++ /dev/null @@ -1,33 +0,0 @@ -# ProjectUpdateRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] -**archived** | **bool** | True if the project is archived, false if not. Archived projects do not show in the UI by default and may be treated differently for queries. | [optional] -**color** | **str** | Color of the project. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**current_status** | [**ProjectBaseCurrentStatus**](ProjectBaseCurrentStatus.md) | | [optional] -**current_status_update** | [**ProjectBaseCurrentStatusUpdate**](ProjectBaseCurrentStatusUpdate.md) | | [optional] -**custom_field_settings** | [**list[PortfolioResponseCustomFieldSettings]**](PortfolioResponseCustomFieldSettings.md) | Array of Custom Field Settings (in compact form). | [optional] -**default_view** | **str** | The default view (list, board, calendar, or timeline) of a project. | [optional] -**due_date** | **date** | *Deprecated: new integrations should prefer the `due_on` field.* | [optional] -**due_on** | **date** | The day on which this project is due. This takes a date with format YYYY-MM-DD. | [optional] -**html_notes** | **str** | [Opt In](/docs/inputoutput-options). The notes of the project with formatting as HTML. | [optional] -**members** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | Array of users who are members of this project. | [optional] -**modified_at** | **datetime** | The time at which this project was last modified. *Note: This does not currently reflect any changes in associations such as tasks or comments that may have been added or removed from the project.* | [optional] -**notes** | **str** | Free-form textual information associated with the project (ie., its description). | [optional] -**public** | **bool** | True if the project is public to its team. | [optional] -**start_on** | **date** | The day on which work for this project begins, or null if the project has no start date. This takes a date with `YYYY-MM-DD` format. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter. Additionally, `start_on` and `due_on` cannot be the same date.* | [optional] -**default_access_level** | **str** | The default access for users or teams who join or are added as members to the project. | [optional] -**minimum_access_level_for_customization** | **str** | The minimum access level needed for project members to modify this project's workflow and appearance. | [optional] -**minimum_access_level_for_sharing** | **str** | The minimum access level needed for project members to share the project and manage project memberships. | [optional] -**custom_fields** | **dict(str, str)** | An object where each key is the GID of a custom field and its corresponding value is either an enum GID, string, number, or object (depending on the custom field type). See the [custom fields guide](/docs/custom-fields-guide) for details on creating and updating custom field values. | [optional] -**followers** | **str** | *Create-only*. Comma separated string of users. Followers are a subset of members who have opted in to receive \"tasks added\" notifications for a project. | [optional] -**owner** | **str** | The current owner of the project, may be null. | [optional] -**team** | **str** | The team that this project is shared with. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectsApi.md b/docs/ProjectsApi.md deleted file mode 100644 index b626dc0d..00000000 --- a/docs/ProjectsApi.md +++ /dev/null @@ -1,1073 +0,0 @@ -# asana.ProjectsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**add_custom_field_setting_for_project**](ProjectsApi.md#add_custom_field_setting_for_project) | **POST** /projects/{project_gid}/addCustomFieldSetting | Add a custom field to a project -[**add_followers_for_project**](ProjectsApi.md#add_followers_for_project) | **POST** /projects/{project_gid}/addFollowers | Add followers to a project -[**add_members_for_project**](ProjectsApi.md#add_members_for_project) | **POST** /projects/{project_gid}/addMembers | Add users to a project -[**create_project**](ProjectsApi.md#create_project) | **POST** /projects | Create a project -[**create_project_for_team**](ProjectsApi.md#create_project_for_team) | **POST** /teams/{team_gid}/projects | Create a project in a team -[**create_project_for_workspace**](ProjectsApi.md#create_project_for_workspace) | **POST** /workspaces/{workspace_gid}/projects | Create a project in a workspace -[**delete_project**](ProjectsApi.md#delete_project) | **DELETE** /projects/{project_gid} | Delete a project -[**duplicate_project**](ProjectsApi.md#duplicate_project) | **POST** /projects/{project_gid}/duplicate | Duplicate a project -[**get_project**](ProjectsApi.md#get_project) | **GET** /projects/{project_gid} | Get a project -[**get_projects**](ProjectsApi.md#get_projects) | **GET** /projects | Get multiple projects -[**get_projects_for_task**](ProjectsApi.md#get_projects_for_task) | **GET** /tasks/{task_gid}/projects | Get projects a task is in -[**get_projects_for_team**](ProjectsApi.md#get_projects_for_team) | **GET** /teams/{team_gid}/projects | Get a team's projects -[**get_projects_for_workspace**](ProjectsApi.md#get_projects_for_workspace) | **GET** /workspaces/{workspace_gid}/projects | Get all projects in a workspace -[**get_task_counts_for_project**](ProjectsApi.md#get_task_counts_for_project) | **GET** /projects/{project_gid}/task_counts | Get task count of a project -[**project_save_as_template**](ProjectsApi.md#project_save_as_template) | **POST** /projects/{project_gid}/saveAsTemplate | Create a project template from a project -[**remove_custom_field_setting_for_project**](ProjectsApi.md#remove_custom_field_setting_for_project) | **POST** /projects/{project_gid}/removeCustomFieldSetting | Remove a custom field from a project -[**remove_followers_for_project**](ProjectsApi.md#remove_followers_for_project) | **POST** /projects/{project_gid}/removeFollowers | Remove followers from a project -[**remove_members_for_project**](ProjectsApi.md#remove_members_for_project) | **POST** /projects/{project_gid}/removeMembers | Remove users from a project -[**update_project**](ProjectsApi.md#update_project) | **PUT** /projects/{project_gid} | Update a project - -# **add_custom_field_setting_for_project** -> CustomFieldSettingResponseData add_custom_field_setting_for_project(body, project_gid) - -Add a custom field to a project - -Custom fields are associated with projects by way of custom field settings. This method creates a setting for the project. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -body = asana.ProjectGidAddCustomFieldSettingBody({"param1": "value1", "param2": "value2",}) # ProjectGidAddCustomFieldSettingBody | Information about the custom field setting. -project_gid = '1331' # str | Globally unique identifier for the project. - -try: - # Add a custom field to a project - api_response = api_instance.add_custom_field_setting_for_project(body, project_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->add_custom_field_setting_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ProjectGidAddCustomFieldSettingBody**](ProjectGidAddCustomFieldSettingBody.md)| Information about the custom field setting. | - **project_gid** | **str**| Globally unique identifier for the project. | - -### Return type - -[**CustomFieldSettingResponseData**](CustomFieldSettingResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **add_followers_for_project** -> ProjectResponseData add_followers_for_project(body, project_gid, opt_fields=opt_fields) - -Add followers to a project - -Adds the specified list of users as followers to the project. Followers are a subset of members who have opted in to receive \"tasks added\" notifications for a project. Therefore, if the users are not already members of the project, they will also become members as a result of this operation. Returns the updated project record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -body = asana.ProjectGidAddFollowersBody({"param1": "value1", "param2": "value2",}) # ProjectGidAddFollowersBody | Information about the followers being added. -project_gid = '1331' # str | Globally unique identifier for the project. -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Add followers to a project - api_response = api_instance.add_followers_for_project(body, project_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->add_followers_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ProjectGidAddFollowersBody**](ProjectGidAddFollowersBody.md)| Information about the followers being added. | - **project_gid** | **str**| Globally unique identifier for the project. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseData**](ProjectResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **add_members_for_project** -> ProjectResponseData add_members_for_project(body, project_gid, opt_fields=opt_fields) - -Add users to a project - -Adds the specified list of users as members of the project. Note that a user being added as a member may also be added as a *follower* as a result of this operation. This is because the user's default notification settings (i.e., in the \"Notifcations\" tab of \"My Profile Settings\") will override this endpoint's default behavior of setting \"Tasks added\" notifications to `false`. Returns the updated project record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -body = asana.ProjectGidAddMembersBody({"param1": "value1", "param2": "value2",}) # ProjectGidAddMembersBody | Information about the members being added. -project_gid = '1331' # str | Globally unique identifier for the project. -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Add users to a project - api_response = api_instance.add_members_for_project(body, project_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->add_members_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ProjectGidAddMembersBody**](ProjectGidAddMembersBody.md)| Information about the members being added. | - **project_gid** | **str**| Globally unique identifier for the project. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseData**](ProjectResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **create_project** -> ProjectResponseData create_project(body, opt_fields=opt_fields) - -Create a project - -Create a new project in a workspace or team. Every project is required to be created in a specific workspace or organization, and this cannot be changed once set. Note that you can use the `workspace` parameter regardless of whether or not it is an organization. If the workspace for your project is an organization, you must also supply a `team` to share the project with. Returns the full record of the newly created project. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -body = asana.ProjectsBody({"param1": "value1", "param2": "value2",}) # ProjectsBody | The project to create. -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a project - api_response = api_instance.create_project(body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->create_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ProjectsBody**](ProjectsBody.md)| The project to create. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseData**](ProjectResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **create_project_for_team** -> ProjectResponseData create_project_for_team(body, team_gid, opt_fields=opt_fields) - -Create a project in a team - -Creates a project shared with the given team. Returns the full record of the newly created project. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -body = asana.TeamGidProjectsBody({"param1": "value1", "param2": "value2",}) # TeamGidProjectsBody | The new project to create. -team_gid = '159874' # str | Globally unique identifier for the team. -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a project in a team - api_response = api_instance.create_project_for_team(body, team_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->create_project_for_team: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TeamGidProjectsBody**](TeamGidProjectsBody.md)| The new project to create. | - **team_gid** | **str**| Globally unique identifier for the team. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseData**](ProjectResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **create_project_for_workspace** -> ProjectResponseData create_project_for_workspace(body, workspace_gid, opt_fields=opt_fields) - -Create a project in a workspace - -Creates a project in the workspace. If the workspace for your project is an organization, you must also supply a team to share the project with. Returns the full record of the newly created project. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -body = asana.WorkspaceGidProjectsBody({"param1": "value1", "param2": "value2",}) # WorkspaceGidProjectsBody | The new project to create. -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a project in a workspace - api_response = api_instance.create_project_for_workspace(body, workspace_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->create_project_for_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**WorkspaceGidProjectsBody**](WorkspaceGidProjectsBody.md)| The new project to create. | - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseData**](ProjectResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_project** -> EmptyResponseData delete_project(project_gid) - -Delete a project - -A specific, existing project can be deleted by making a DELETE request on the URL for that project. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -project_gid = '1331' # str | Globally unique identifier for the project. - -try: - # Delete a project - api_response = api_instance.delete_project(project_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->delete_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_gid** | **str**| Globally unique identifier for the project. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **duplicate_project** -> JobResponseData duplicate_project(project_gid, body=body, opt_fields=opt_fields) - -Duplicate a project - -Creates and returns a job that will asynchronously handle the duplication. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -project_gid = '1331' # str | Globally unique identifier for the project. -body = asana.ProjectGidDuplicateBody({"param1": "value1", "param2": "value2",}) # ProjectGidDuplicateBody | Describes the duplicate's name and the elements that will be duplicated. (optional) -opt_fields = ["new_project","new_project.name","new_project_template","new_project_template.name","new_task","new_task.created_by","new_task.name","new_task.resource_subtype","resource_subtype","status"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Duplicate a project - api_response = api_instance.duplicate_project(project_gid, body=body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->duplicate_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_gid** | **str**| Globally unique identifier for the project. | - **body** | [**ProjectGidDuplicateBody**](ProjectGidDuplicateBody.md)| Describes the duplicate's name and the elements that will be duplicated. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**JobResponseData**](JobResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_project** -> ProjectResponseData get_project(project_gid, opt_fields=opt_fields) - -Get a project - -Returns the complete project record for a single project. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -project_gid = '1331' # str | Globally unique identifier for the project. -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a project - api_response = api_instance.get_project(project_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->get_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_gid** | **str**| Globally unique identifier for the project. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseData**](ProjectResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_projects** -> ProjectResponseArray get_projects(limit=limit, offset=offset, workspace=workspace, team=team, archived=archived, opt_fields=opt_fields) - -Get multiple projects - -Returns the compact project records for some filtered set of projects. Use one or more of the parameters provided to filter the projects returned. *Note: This endpoint may timeout for large domains. Try filtering by team!* - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -workspace = '1331' # str | The workspace or organization to filter projects on. (optional) -team = '14916' # str | The team to filter projects on. (optional) -archived = false # bool | Only return projects whose `archived` field takes on the value of this parameter. (optional) -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","offset","owner","path","permalink_url","project_brief","public","start_on","team","team.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get multiple projects - api_response = api_instance.get_projects(limit=limit, offset=offset, workspace=workspace, team=team, archived=archived, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->get_projects: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **workspace** | **str**| The workspace or organization to filter projects on. | [optional] - **team** | **str**| The team to filter projects on. | [optional] - **archived** | **bool**| Only return projects whose `archived` field takes on the value of this parameter. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseArray**](ProjectResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_projects_for_task** -> ProjectResponseArray get_projects_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get projects a task is in - -Returns a compact representation of all of the projects the task is in. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -task_gid = '321654' # str | The task to operate on. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","offset","owner","path","permalink_url","project_brief","public","start_on","team","team.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get projects a task is in - api_response = api_instance.get_projects_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->get_projects_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **task_gid** | **str**| The task to operate on. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseArray**](ProjectResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_projects_for_team** -> ProjectResponseArray get_projects_for_team(team_gid, limit=limit, offset=offset, archived=archived, opt_fields=opt_fields) - -Get a team's projects - -Returns the compact project records for all projects in the team. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -team_gid = '159874' # str | Globally unique identifier for the team. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -archived = false # bool | Only return projects whose `archived` field takes on the value of this parameter. (optional) -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","offset","owner","path","permalink_url","project_brief","public","start_on","team","team.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a team's projects - api_response = api_instance.get_projects_for_team(team_gid, limit=limit, offset=offset, archived=archived, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->get_projects_for_team: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **team_gid** | **str**| Globally unique identifier for the team. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **archived** | **bool**| Only return projects whose `archived` field takes on the value of this parameter. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseArray**](ProjectResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_projects_for_workspace** -> ProjectResponseArray get_projects_for_workspace(workspace_gid, limit=limit, offset=offset, archived=archived, opt_fields=opt_fields) - -Get all projects in a workspace - -Returns the compact project records for all projects in the workspace. *Note: This endpoint may timeout for large domains. Prefer the `/teams/{team_gid}/projects` endpoint.* - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -archived = false # bool | Only return projects whose `archived` field takes on the value of this parameter. (optional) -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","offset","owner","path","permalink_url","project_brief","public","start_on","team","team.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get all projects in a workspace - api_response = api_instance.get_projects_for_workspace(workspace_gid, limit=limit, offset=offset, archived=archived, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->get_projects_for_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **archived** | **bool**| Only return projects whose `archived` field takes on the value of this parameter. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseArray**](ProjectResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_task_counts_for_project** -> TaskCountResponseData get_task_counts_for_project(project_gid, opt_fields=opt_fields) - -Get task count of a project - -Get an object that holds task count fields. **All fields are excluded by default**. You must [opt in](/docs/inputoutput-options) using `opt_fields` to get any information from this endpoint. This endpoint has an additional [rate limit](/docs/rate-limits) and each field counts especially high against our [cost limits](/docs/rate-limits#cost-limits). Milestones are just tasks, so they are included in the `num_tasks`, `num_incomplete_tasks`, and `num_completed_tasks` counts. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -project_gid = '1331' # str | Globally unique identifier for the project. -opt_fields = ["num_completed_milestones","num_completed_tasks","num_incomplete_milestones","num_incomplete_tasks","num_milestones","num_tasks"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get task count of a project - api_response = api_instance.get_task_counts_for_project(project_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->get_task_counts_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_gid** | **str**| Globally unique identifier for the project. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskCountResponseData**](TaskCountResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **project_save_as_template** -> JobResponseData project_save_as_template(body, project_gid, opt_fields=opt_fields) - -Create a project template from a project - -Creates and returns a job that will asynchronously handle the project template creation. Note that while the resulting project template can be accessed with the API, it won't be visible in the Asana UI until Project Templates 2.0 is launched in the app. See more in [this forum post](https://forum.asana.com/t/a-new-api-for-project-templates/156432). - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -body = asana.ProjectGidSaveAsTemplateBody({"param1": "value1", "param2": "value2",}) # ProjectGidSaveAsTemplateBody | Describes the inputs used for creating a project template, such as the resulting project template's name, which team it should be created in. -project_gid = '1331' # str | Globally unique identifier for the project. -opt_fields = ["new_project","new_project.name","new_project_template","new_project_template.name","new_task","new_task.created_by","new_task.name","new_task.resource_subtype","resource_subtype","status"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a project template from a project - api_response = api_instance.project_save_as_template(body, project_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->project_save_as_template: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ProjectGidSaveAsTemplateBody**](ProjectGidSaveAsTemplateBody.md)| Describes the inputs used for creating a project template, such as the resulting project template's name, which team it should be created in. | - **project_gid** | **str**| Globally unique identifier for the project. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**JobResponseData**](JobResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_custom_field_setting_for_project** -> EmptyResponseData remove_custom_field_setting_for_project(body, project_gid) - -Remove a custom field from a project - -Removes a custom field setting from a project. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -body = asana.ProjectGidRemoveCustomFieldSettingBody({"param1": "value1", "param2": "value2",}) # ProjectGidRemoveCustomFieldSettingBody | Information about the custom field setting being removed. -project_gid = '1331' # str | Globally unique identifier for the project. - -try: - # Remove a custom field from a project - api_response = api_instance.remove_custom_field_setting_for_project(body, project_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->remove_custom_field_setting_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ProjectGidRemoveCustomFieldSettingBody**](ProjectGidRemoveCustomFieldSettingBody.md)| Information about the custom field setting being removed. | - **project_gid** | **str**| Globally unique identifier for the project. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_followers_for_project** -> ProjectResponseData remove_followers_for_project(body, project_gid, opt_fields=opt_fields) - -Remove followers from a project - -Removes the specified list of users from following the project, this will not affect project membership status. Returns the updated project record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -body = asana.ProjectGidRemoveFollowersBody({"param1": "value1", "param2": "value2",}) # ProjectGidRemoveFollowersBody | Information about the followers being removed. -project_gid = '1331' # str | Globally unique identifier for the project. -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Remove followers from a project - api_response = api_instance.remove_followers_for_project(body, project_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->remove_followers_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ProjectGidRemoveFollowersBody**](ProjectGidRemoveFollowersBody.md)| Information about the followers being removed. | - **project_gid** | **str**| Globally unique identifier for the project. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseData**](ProjectResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_members_for_project** -> ProjectResponseData remove_members_for_project(body, project_gid, opt_fields=opt_fields) - -Remove users from a project - -Removes the specified list of users from members of the project. Returns the updated project record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -body = asana.ProjectGidRemoveMembersBody({"param1": "value1", "param2": "value2",}) # ProjectGidRemoveMembersBody | Information about the members being removed. -project_gid = '1331' # str | Globally unique identifier for the project. -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Remove users from a project - api_response = api_instance.remove_members_for_project(body, project_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->remove_members_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ProjectGidRemoveMembersBody**](ProjectGidRemoveMembersBody.md)| Information about the members being removed. | - **project_gid** | **str**| Globally unique identifier for the project. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseData**](ProjectResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_project** -> ProjectResponseData update_project(body, project_gid, opt_fields=opt_fields) - -Update a project - -A specific, existing project can be updated by making a PUT request on the URL for that project. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the task. Returns the complete updated project record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.ProjectsApi(api_client) -body = asana.ProjectsProjectGidBody({"param1": "value1", "param2": "value2",}) # ProjectsProjectGidBody | The updated fields for the project. -project_gid = '1331' # str | Globally unique identifier for the project. -opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a project - api_response = api_instance.update_project(body, project_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling ProjectsApi->update_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**ProjectsProjectGidBody**](ProjectsProjectGidBody.md)| The updated fields for the project. | - **project_gid** | **str**| Globally unique identifier for the project. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**ProjectResponseData**](ProjectResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/ProjectsApi.yaml b/docs/ProjectsApi.yaml deleted file mode 100644 index da93a822..00000000 --- a/docs/ProjectsApi.yaml +++ /dev/null @@ -1,420 +0,0 @@ -ProjectsApi: - add_custom_field_setting_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - body = asana.ProjectGidAddCustomFieldSettingBody({"param1": "value1", "param2": "value2",}) # ProjectGidAddCustomFieldSettingBody | Information about the custom field setting. - project_gid = '1331' # str | Globally unique identifier for the project. - - try: - # Add a custom field to a project - api_response = api_instance.add_custom_field_setting_for_project(body, project_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->add_custom_field_setting_for_project: %s\n" % e) - add_followers_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - body = asana.ProjectGidAddFollowersBody({"param1": "value1", "param2": "value2",}) # ProjectGidAddFollowersBody | Information about the followers being added. - project_gid = '1331' # str | Globally unique identifier for the project. - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Add followers to a project - api_response = api_instance.add_followers_for_project(body, project_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->add_followers_for_project: %s\n" % e) - add_members_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - body = asana.ProjectGidAddMembersBody({"param1": "value1", "param2": "value2",}) # ProjectGidAddMembersBody | Information about the members being added. - project_gid = '1331' # str | Globally unique identifier for the project. - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Add users to a project - api_response = api_instance.add_members_for_project(body, project_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->add_members_for_project: %s\n" % e) - create_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - body = asana.ProjectsBody({"param1": "value1", "param2": "value2",}) # ProjectsBody | The project to create. - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a project - api_response = api_instance.create_project(body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->create_project: %s\n" % e) - create_project_for_team: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - body = asana.TeamGidProjectsBody({"param1": "value1", "param2": "value2",}) # TeamGidProjectsBody | The new project to create. - team_gid = '159874' # str | Globally unique identifier for the team. - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a project in a team - api_response = api_instance.create_project_for_team(body, team_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->create_project_for_team: %s\n" % e) - create_project_for_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - body = asana.WorkspaceGidProjectsBody({"param1": "value1", "param2": "value2",}) # WorkspaceGidProjectsBody | The new project to create. - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a project in a workspace - api_response = api_instance.create_project_for_workspace(body, workspace_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->create_project_for_workspace: %s\n" % e) - delete_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - project_gid = '1331' # str | Globally unique identifier for the project. - - try: - # Delete a project - api_response = api_instance.delete_project(project_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->delete_project: %s\n" % e) - duplicate_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - project_gid = '1331' # str | Globally unique identifier for the project. - body = asana.ProjectGidDuplicateBody({"param1": "value1", "param2": "value2",}) # ProjectGidDuplicateBody | Describes the duplicate's name and the elements that will be duplicated. (optional) - opt_fields = ["new_project","new_project.name","new_project_template","new_project_template.name","new_task","new_task.created_by","new_task.name","new_task.resource_subtype","resource_subtype","status"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Duplicate a project - api_response = api_instance.duplicate_project(project_gid, body=body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->duplicate_project: %s\n" % e) - get_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - project_gid = '1331' # str | Globally unique identifier for the project. - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a project - api_response = api_instance.get_project(project_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->get_project: %s\n" % e) - get_projects: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - workspace = '1331' # str | The workspace or organization to filter projects on. (optional) - team = '14916' # str | The team to filter projects on. (optional) - archived = false # bool | Only return projects whose `archived` field takes on the value of this parameter. (optional) - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","offset","owner","path","permalink_url","project_brief","public","start_on","team","team.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get multiple projects - api_response = api_instance.get_projects(limit=limit, offset=offset, workspace=workspace, team=team, archived=archived, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->get_projects: %s\n" % e) - get_projects_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - task_gid = '321654' # str | The task to operate on. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","offset","owner","path","permalink_url","project_brief","public","start_on","team","team.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get projects a task is in - api_response = api_instance.get_projects_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->get_projects_for_task: %s\n" % e) - get_projects_for_team: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - team_gid = '159874' # str | Globally unique identifier for the team. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - archived = false # bool | Only return projects whose `archived` field takes on the value of this parameter. (optional) - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","offset","owner","path","permalink_url","project_brief","public","start_on","team","team.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a team's projects - api_response = api_instance.get_projects_for_team(team_gid, limit=limit, offset=offset, archived=archived, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->get_projects_for_team: %s\n" % e) - get_projects_for_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - archived = false # bool | Only return projects whose `archived` field takes on the value of this parameter. (optional) - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","offset","owner","path","permalink_url","project_brief","public","start_on","team","team.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get all projects in a workspace - api_response = api_instance.get_projects_for_workspace(workspace_gid, limit=limit, offset=offset, archived=archived, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->get_projects_for_workspace: %s\n" % e) - get_task_counts_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - project_gid = '1331' # str | Globally unique identifier for the project. - opt_fields = ["num_completed_milestones","num_completed_tasks","num_incomplete_milestones","num_incomplete_tasks","num_milestones","num_tasks"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get task count of a project - api_response = api_instance.get_task_counts_for_project(project_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->get_task_counts_for_project: %s\n" % e) - project_save_as_template: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - body = asana.ProjectGidSaveAsTemplateBody({"param1": "value1", "param2": "value2",}) # ProjectGidSaveAsTemplateBody | Describes the inputs used for creating a project template, such as the resulting project template's name, which team it should be created in. - project_gid = '1331' # str | Globally unique identifier for the project. - opt_fields = ["new_project","new_project.name","new_project_template","new_project_template.name","new_task","new_task.created_by","new_task.name","new_task.resource_subtype","resource_subtype","status"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a project template from a project - api_response = api_instance.project_save_as_template(body, project_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->project_save_as_template: %s\n" % e) - remove_custom_field_setting_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - body = asana.ProjectGidRemoveCustomFieldSettingBody({"param1": "value1", "param2": "value2",}) # ProjectGidRemoveCustomFieldSettingBody | Information about the custom field setting being removed. - project_gid = '1331' # str | Globally unique identifier for the project. - - try: - # Remove a custom field from a project - api_response = api_instance.remove_custom_field_setting_for_project(body, project_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->remove_custom_field_setting_for_project: %s\n" % e) - remove_followers_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - body = asana.ProjectGidRemoveFollowersBody({"param1": "value1", "param2": "value2",}) # ProjectGidRemoveFollowersBody | Information about the followers being removed. - project_gid = '1331' # str | Globally unique identifier for the project. - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Remove followers from a project - api_response = api_instance.remove_followers_for_project(body, project_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->remove_followers_for_project: %s\n" % e) - remove_members_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - body = asana.ProjectGidRemoveMembersBody({"param1": "value1", "param2": "value2",}) # ProjectGidRemoveMembersBody | Information about the members being removed. - project_gid = '1331' # str | Globally unique identifier for the project. - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Remove users from a project - api_response = api_instance.remove_members_for_project(body, project_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->remove_members_for_project: %s\n" % e) - update_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.ProjectsApi(api_client) - body = asana.ProjectsProjectGidBody({"param1": "value1", "param2": "value2",}) # ProjectsProjectGidBody | The updated fields for the project. - project_gid = '1331' # str | Globally unique identifier for the project. - opt_fields = ["archived","color","completed","completed_at","completed_by","completed_by.name","created_at","created_from_template","created_from_template.name","current_status","current_status.author","current_status.author.name","current_status.color","current_status.created_at","current_status.created_by","current_status.created_by.name","current_status.html_text","current_status.modified_at","current_status.text","current_status.title","current_status_update","current_status_update.resource_subtype","current_status_update.title","custom_field_settings","custom_field_settings.custom_field","custom_field_settings.custom_field.asana_created_field","custom_field_settings.custom_field.created_by","custom_field_settings.custom_field.created_by.name","custom_field_settings.custom_field.currency_code","custom_field_settings.custom_field.custom_label","custom_field_settings.custom_field.custom_label_position","custom_field_settings.custom_field.date_value","custom_field_settings.custom_field.date_value.date","custom_field_settings.custom_field.date_value.date_time","custom_field_settings.custom_field.description","custom_field_settings.custom_field.display_value","custom_field_settings.custom_field.enabled","custom_field_settings.custom_field.enum_options","custom_field_settings.custom_field.enum_options.color","custom_field_settings.custom_field.enum_options.enabled","custom_field_settings.custom_field.enum_options.name","custom_field_settings.custom_field.enum_value","custom_field_settings.custom_field.enum_value.color","custom_field_settings.custom_field.enum_value.enabled","custom_field_settings.custom_field.enum_value.name","custom_field_settings.custom_field.format","custom_field_settings.custom_field.has_notifications_enabled","custom_field_settings.custom_field.is_formula_field","custom_field_settings.custom_field.is_global_to_workspace","custom_field_settings.custom_field.is_value_read_only","custom_field_settings.custom_field.multi_enum_values","custom_field_settings.custom_field.multi_enum_values.color","custom_field_settings.custom_field.multi_enum_values.enabled","custom_field_settings.custom_field.multi_enum_values.name","custom_field_settings.custom_field.name","custom_field_settings.custom_field.number_value","custom_field_settings.custom_field.people_value","custom_field_settings.custom_field.people_value.name","custom_field_settings.custom_field.precision","custom_field_settings.custom_field.resource_subtype","custom_field_settings.custom_field.text_value","custom_field_settings.custom_field.type","custom_field_settings.is_important","custom_field_settings.parent","custom_field_settings.parent.name","custom_field_settings.project","custom_field_settings.project.name","custom_fields","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.is_formula_field","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","default_access_level","default_view","due_date","due_on","followers","followers.name","html_notes","icon","members","members.name","minimum_access_level_for_customization","minimum_access_level_for_sharing","modified_at","name","notes","owner","permalink_url","project_brief","public","start_on","team","team.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a project - api_response = api_instance.update_project(body, project_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling ProjectsApi->update_project: %s\n" % e) diff --git a/docs/ProjectsBody.md b/docs/ProjectsBody.md deleted file mode 100644 index 7c6f7870..00000000 --- a/docs/ProjectsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectRequest**](ProjectRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/ProjectsProjectGidBody.md b/docs/ProjectsProjectGidBody.md deleted file mode 100644 index 866da029..00000000 --- a/docs/ProjectsProjectGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# ProjectsProjectGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectUpdateRequest**](ProjectUpdateRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/RemoveCustomFieldSettingRequest.md b/docs/RemoveCustomFieldSettingRequest.md deleted file mode 100644 index fe16f4b6..00000000 --- a/docs/RemoveCustomFieldSettingRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# RemoveCustomFieldSettingRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**custom_field** | **str** | The custom field to remove from this portfolio. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/RemoveFollowersRequest.md b/docs/RemoveFollowersRequest.md deleted file mode 100644 index 898f0c7f..00000000 --- a/docs/RemoveFollowersRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# RemoveFollowersRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**followers** | **str** | An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/RemoveMembersRequest.md b/docs/RemoveMembersRequest.md deleted file mode 100644 index b861010e..00000000 --- a/docs/RemoveMembersRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# RemoveMembersRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**members** | **str** | An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/RequestedRoleRequest.md b/docs/RequestedRoleRequest.md deleted file mode 100644 index d85ef805..00000000 --- a/docs/RequestedRoleRequest.md +++ /dev/null @@ -1,10 +0,0 @@ -# RequestedRoleRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the template role in the project template. | [optional] -**value** | **str** | The user id that should be assigned to the template role. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/RuleTriggerGidRunBody.md b/docs/RuleTriggerGidRunBody.md deleted file mode 100644 index 24ab166b..00000000 --- a/docs/RuleTriggerGidRunBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# RuleTriggerGidRunBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**RuleTriggerRequest**](RuleTriggerRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/RuleTriggerRequest.md b/docs/RuleTriggerRequest.md deleted file mode 100644 index 398b9d94..00000000 --- a/docs/RuleTriggerRequest.md +++ /dev/null @@ -1,10 +0,0 @@ -# RuleTriggerRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**resource** | **str** | The ID of the resource. For the duration of the beta, this resource is always a task, and this task must exist in the project in which the rule is created. | -**action_data** | **dict(str, object)** | The dynamic keys and values of the request. These fields are intended to be used in the action for the rule associated with this trigger. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/RuleTriggerResponse.md b/docs/RuleTriggerResponse.md deleted file mode 100644 index 2a0df059..00000000 --- a/docs/RuleTriggerResponse.md +++ /dev/null @@ -1,9 +0,0 @@ -# RuleTriggerResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**message** | **str** | Message providing more detail about the result | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/RuleTriggerResponseData.md b/docs/RuleTriggerResponseData.md deleted file mode 100644 index 0652e621..00000000 --- a/docs/RuleTriggerResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# RuleTriggerResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**RuleTriggerResponse**](RuleTriggerResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/RulesApi.md b/docs/RulesApi.md deleted file mode 100644 index 3c02bea7..00000000 --- a/docs/RulesApi.md +++ /dev/null @@ -1,61 +0,0 @@ -# asana.RulesApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**trigger_rule**](RulesApi.md#trigger_rule) | **POST** /rule_triggers/{rule_trigger_gid}/run | Trigger a rule - -# **trigger_rule** -> RuleTriggerResponseData trigger_rule(body, rule_trigger_gid) - -Trigger a rule - -Trigger a rule which uses an [\"incoming web request\"](/docs/incoming-web-requests) trigger. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.RulesApi(api_client) -body = asana.RuleTriggerGidRunBody({"param1": "value1", "param2": "value2",}) # RuleTriggerGidRunBody | A dictionary of variables accessible from within the rule. -rule_trigger_gid = '12345' # str | The ID of the incoming web request trigger. This value is a path parameter that is automatically generated for the API endpoint. - -try: - # Trigger a rule - api_response = api_instance.trigger_rule(body, rule_trigger_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling RulesApi->trigger_rule: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**RuleTriggerGidRunBody**](RuleTriggerGidRunBody.md)| A dictionary of variables accessible from within the rule. | - **rule_trigger_gid** | **str**| The ID of the incoming web request trigger. This value is a path parameter that is automatically generated for the API endpoint. | - -### Return type - -[**RuleTriggerResponseData**](RuleTriggerResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/RulesApi.yaml b/docs/RulesApi.yaml deleted file mode 100644 index 5a8fec3d..00000000 --- a/docs/RulesApi.yaml +++ /dev/null @@ -1,22 +0,0 @@ -RulesApi: - trigger_rule: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.RulesApi(api_client) - body = asana.RuleTriggerGidRunBody({"param1": "value1", "param2": "value2",}) # RuleTriggerGidRunBody | A dictionary of variables accessible from within the rule. - rule_trigger_gid = '12345' # str | The ID of the incoming web request trigger. This value is a path parameter that is automatically generated for the API endpoint. - - try: - # Trigger a rule - api_response = api_instance.trigger_rule(body, rule_trigger_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling RulesApi->trigger_rule: %s\n" % e) diff --git a/docs/SectionBase.md b/docs/SectionBase.md deleted file mode 100644 index 6481d0be..00000000 --- a/docs/SectionBase.md +++ /dev/null @@ -1,11 +0,0 @@ -# SectionBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the section (i.e. the text displayed as the section header). | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/SectionCompact.md b/docs/SectionCompact.md deleted file mode 100644 index 1482a975..00000000 --- a/docs/SectionCompact.md +++ /dev/null @@ -1,11 +0,0 @@ -# SectionCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the section (i.e. the text displayed as the section header). | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/SectionGidAddTaskBody.md b/docs/SectionGidAddTaskBody.md deleted file mode 100644 index 7b2d886f..00000000 --- a/docs/SectionGidAddTaskBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# SectionGidAddTaskBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**SectionTaskInsertRequest**](SectionTaskInsertRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/SectionRequest.md b/docs/SectionRequest.md deleted file mode 100644 index 931f0231..00000000 --- a/docs/SectionRequest.md +++ /dev/null @@ -1,11 +0,0 @@ -# SectionRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **str** | The text to be displayed as the section name. This cannot be an empty string. | -**insert_before** | **str** | An existing section within this project before which the added section should be inserted. Cannot be provided together with insert_after. | [optional] -**insert_after** | **str** | An existing section within this project after which the added section should be inserted. Cannot be provided together with insert_before. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/SectionResponse.md b/docs/SectionResponse.md deleted file mode 100644 index f39eb42f..00000000 --- a/docs/SectionResponse.md +++ /dev/null @@ -1,14 +0,0 @@ -# SectionResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the section (i.e. the text displayed as the section header). | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**project** | [**JobBaseNewProject**](JobBaseNewProject.md) | | [optional] -**projects** | [**list[JobBaseNewProject]**](JobBaseNewProject.md) | *Deprecated - please use project instead* | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/SectionResponseArray.md b/docs/SectionResponseArray.md deleted file mode 100644 index 54a18317..00000000 --- a/docs/SectionResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# SectionResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[SectionResponse]**](SectionResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/SectionResponseData.md b/docs/SectionResponseData.md deleted file mode 100644 index 7c3e8862..00000000 --- a/docs/SectionResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# SectionResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**SectionResponse**](SectionResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/SectionTaskInsertRequest.md b/docs/SectionTaskInsertRequest.md deleted file mode 100644 index 6a01830a..00000000 --- a/docs/SectionTaskInsertRequest.md +++ /dev/null @@ -1,11 +0,0 @@ -# SectionTaskInsertRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**task** | **str** | The task to add to this section. | -**insert_before** | **str** | An existing task within this section before which the added task should be inserted. Cannot be provided together with insert_after. | [optional] -**insert_after** | **str** | An existing task within this section after which the added task should be inserted. Cannot be provided together with insert_before. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/SectionsApi.md b/docs/SectionsApi.md deleted file mode 100644 index f3fedf11..00000000 --- a/docs/SectionsApi.md +++ /dev/null @@ -1,391 +0,0 @@ -# asana.SectionsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**add_task_for_section**](SectionsApi.md#add_task_for_section) | **POST** /sections/{section_gid}/addTask | Add task to section -[**create_section_for_project**](SectionsApi.md#create_section_for_project) | **POST** /projects/{project_gid}/sections | Create a section in a project -[**delete_section**](SectionsApi.md#delete_section) | **DELETE** /sections/{section_gid} | Delete a section -[**get_section**](SectionsApi.md#get_section) | **GET** /sections/{section_gid} | Get a section -[**get_sections_for_project**](SectionsApi.md#get_sections_for_project) | **GET** /projects/{project_gid}/sections | Get sections in a project -[**insert_section_for_project**](SectionsApi.md#insert_section_for_project) | **POST** /projects/{project_gid}/sections/insert | Move or Insert sections -[**update_section**](SectionsApi.md#update_section) | **PUT** /sections/{section_gid} | Update a section - -# **add_task_for_section** -> EmptyResponseData add_task_for_section(section_gid, body=body) - -Add task to section - -Add a task to a specific, existing section. This will remove the task from other sections of the project. The task will be inserted at the top of a section unless an insert_before or insert_after parameter is declared. This does not work for separators (tasks with the resource_subtype of section). - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.SectionsApi(api_client) -section_gid = '321654' # str | The globally unique identifier for the section. -body = asana.SectionGidAddTaskBody({"param1": "value1", "param2": "value2",}) # SectionGidAddTaskBody | The task and optionally the insert location. (optional) - -try: - # Add task to section - api_response = api_instance.add_task_for_section(section_gid, body=body) - pprint(api_response) -except ApiException as e: - print("Exception when calling SectionsApi->add_task_for_section: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **section_gid** | **str**| The globally unique identifier for the section. | - **body** | [**SectionGidAddTaskBody**](SectionGidAddTaskBody.md)| The task and optionally the insert location. | [optional] - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **create_section_for_project** -> SectionResponseData create_section_for_project(project_gid, body=body, opt_fields=opt_fields) - -Create a section in a project - -Creates a new section in a project. Returns the full record of the newly created section. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.SectionsApi(api_client) -project_gid = '1331' # str | Globally unique identifier for the project. -body = asana.ProjectGidSectionsBody({"param1": "value1", "param2": "value2",}) # ProjectGidSectionsBody | The section to create. (optional) -opt_fields = ["created_at","name","project","project.name","projects","projects.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a section in a project - api_response = api_instance.create_section_for_project(project_gid, body=body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling SectionsApi->create_section_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_gid** | **str**| Globally unique identifier for the project. | - **body** | [**ProjectGidSectionsBody**](ProjectGidSectionsBody.md)| The section to create. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**SectionResponseData**](SectionResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_section** -> EmptyResponseData delete_section(section_gid) - -Delete a section - -A specific, existing section can be deleted by making a DELETE request on the URL for that section. Note that sections must be empty to be deleted. The last remaining section cannot be deleted. Returns an empty data block. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.SectionsApi(api_client) -section_gid = '321654' # str | The globally unique identifier for the section. - -try: - # Delete a section - api_response = api_instance.delete_section(section_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling SectionsApi->delete_section: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **section_gid** | **str**| The globally unique identifier for the section. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_section** -> SectionResponseData get_section(section_gid, opt_fields=opt_fields) - -Get a section - -Returns the complete record for a single section. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.SectionsApi(api_client) -section_gid = '321654' # str | The globally unique identifier for the section. -opt_fields = ["created_at","name","project","project.name","projects","projects.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a section - api_response = api_instance.get_section(section_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling SectionsApi->get_section: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **section_gid** | **str**| The globally unique identifier for the section. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**SectionResponseData**](SectionResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_sections_for_project** -> SectionResponseArray get_sections_for_project(project_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get sections in a project - -Returns the compact records for all sections in the specified project. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.SectionsApi(api_client) -project_gid = '1331' # str | Globally unique identifier for the project. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["created_at","name","offset","path","project","project.name","projects","projects.name","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get sections in a project - api_response = api_instance.get_sections_for_project(project_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling SectionsApi->get_sections_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_gid** | **str**| Globally unique identifier for the project. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**SectionResponseArray**](SectionResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **insert_section_for_project** -> EmptyResponseData insert_section_for_project(project_gid, body=body) - -Move or Insert sections - -Move sections relative to each other. One of `before_section` or `after_section` is required. Sections cannot be moved between projects. Returns an empty data block. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.SectionsApi(api_client) -project_gid = '1331' # str | Globally unique identifier for the project. -body = asana.SectionsInsertBody({"param1": "value1", "param2": "value2",}) # SectionsInsertBody | The section's move action. (optional) - -try: - # Move or Insert sections - api_response = api_instance.insert_section_for_project(project_gid, body=body) - pprint(api_response) -except ApiException as e: - print("Exception when calling SectionsApi->insert_section_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_gid** | **str**| Globally unique identifier for the project. | - **body** | [**SectionsInsertBody**](SectionsInsertBody.md)| The section's move action. | [optional] - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_section** -> SectionResponseData update_section(section_gid, body=body, opt_fields=opt_fields) - -Update a section - -A specific, existing section can be updated by making a PUT request on the URL for that project. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. (note that at this time, the only field that can be updated is the `name` field.) When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the task. Returns the complete updated section record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.SectionsApi(api_client) -section_gid = '321654' # str | The globally unique identifier for the section. -body = asana.SectionsSectionGidBody({"param1": "value1", "param2": "value2",}) # SectionsSectionGidBody | The section to create. (optional) -opt_fields = ["created_at","name","project","project.name","projects","projects.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a section - api_response = api_instance.update_section(section_gid, body=body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling SectionsApi->update_section: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **section_gid** | **str**| The globally unique identifier for the section. | - **body** | [**SectionsSectionGidBody**](SectionsSectionGidBody.md)| The section to create. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**SectionResponseData**](SectionResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/SectionsApi.yaml b/docs/SectionsApi.yaml deleted file mode 100644 index 00915662..00000000 --- a/docs/SectionsApi.yaml +++ /dev/null @@ -1,151 +0,0 @@ -SectionsApi: - add_task_for_section: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.SectionsApi(api_client) - section_gid = '321654' # str | The globally unique identifier for the section. - body = asana.SectionGidAddTaskBody({"param1": "value1", "param2": "value2",}) # SectionGidAddTaskBody | The task and optionally the insert location. (optional) - - try: - # Add task to section - api_response = api_instance.add_task_for_section(section_gid, body=body) - pprint(api_response) - except ApiException as e: - print("Exception when calling SectionsApi->add_task_for_section: %s\n" % e) - create_section_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.SectionsApi(api_client) - project_gid = '1331' # str | Globally unique identifier for the project. - body = asana.ProjectGidSectionsBody({"param1": "value1", "param2": "value2",}) # ProjectGidSectionsBody | The section to create. (optional) - opt_fields = ["created_at","name","project","project.name","projects","projects.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a section in a project - api_response = api_instance.create_section_for_project(project_gid, body=body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling SectionsApi->create_section_for_project: %s\n" % e) - delete_section: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.SectionsApi(api_client) - section_gid = '321654' # str | The globally unique identifier for the section. - - try: - # Delete a section - api_response = api_instance.delete_section(section_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling SectionsApi->delete_section: %s\n" % e) - get_section: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.SectionsApi(api_client) - section_gid = '321654' # str | The globally unique identifier for the section. - opt_fields = ["created_at","name","project","project.name","projects","projects.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a section - api_response = api_instance.get_section(section_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling SectionsApi->get_section: %s\n" % e) - get_sections_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.SectionsApi(api_client) - project_gid = '1331' # str | Globally unique identifier for the project. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["created_at","name","offset","path","project","project.name","projects","projects.name","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get sections in a project - api_response = api_instance.get_sections_for_project(project_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling SectionsApi->get_sections_for_project: %s\n" % e) - insert_section_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.SectionsApi(api_client) - project_gid = '1331' # str | Globally unique identifier for the project. - body = asana.SectionsInsertBody({"param1": "value1", "param2": "value2",}) # SectionsInsertBody | The section's move action. (optional) - - try: - # Move or Insert sections - api_response = api_instance.insert_section_for_project(project_gid, body=body) - pprint(api_response) - except ApiException as e: - print("Exception when calling SectionsApi->insert_section_for_project: %s\n" % e) - update_section: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.SectionsApi(api_client) - section_gid = '321654' # str | The globally unique identifier for the section. - body = asana.SectionsSectionGidBody({"param1": "value1", "param2": "value2",}) # SectionsSectionGidBody | The section to create. (optional) - opt_fields = ["created_at","name","project","project.name","projects","projects.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a section - api_response = api_instance.update_section(section_gid, body=body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling SectionsApi->update_section: %s\n" % e) diff --git a/docs/SectionsInsertBody.md b/docs/SectionsInsertBody.md deleted file mode 100644 index 1b4d370b..00000000 --- a/docs/SectionsInsertBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# SectionsInsertBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectSectionInsertRequest**](ProjectSectionInsertRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/SectionsSectionGidBody.md b/docs/SectionsSectionGidBody.md deleted file mode 100644 index eee47960..00000000 --- a/docs/SectionsSectionGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# SectionsSectionGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**SectionRequest**](SectionRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StatusUpdateBase.md b/docs/StatusUpdateBase.md deleted file mode 100644 index fed8b97a..00000000 --- a/docs/StatusUpdateBase.md +++ /dev/null @@ -1,15 +0,0 @@ -# StatusUpdateBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the status update. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. | [optional] -**text** | **str** | The text content of the status update. | -**html_text** | **str** | [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. | [optional] -**status_type** | **str** | The type associated with the status update. This represents the current state of the object this object is on. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StatusUpdateCompact.md b/docs/StatusUpdateCompact.md deleted file mode 100644 index cd3009a5..00000000 --- a/docs/StatusUpdateCompact.md +++ /dev/null @@ -1,12 +0,0 @@ -# StatusUpdateCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the status update. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StatusUpdateRequest.md b/docs/StatusUpdateRequest.md deleted file mode 100644 index 8f8c5f2a..00000000 --- a/docs/StatusUpdateRequest.md +++ /dev/null @@ -1,16 +0,0 @@ -# StatusUpdateRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the status update. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. | [optional] -**text** | **str** | The text content of the status update. | -**html_text** | **str** | [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. | [optional] -**status_type** | **str** | The type associated with the status update. This represents the current state of the object this object is on. | -**parent** | **str** | The id of parent to send this status update to. This can be a project, goal or portfolio. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StatusUpdateResponse.md b/docs/StatusUpdateResponse.md deleted file mode 100644 index 329243f2..00000000 --- a/docs/StatusUpdateResponse.md +++ /dev/null @@ -1,26 +0,0 @@ -# StatusUpdateResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**title** | **str** | The title of the status update. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The `resource_subtype`s for `status` objects represent the type of their parent. | [optional] -**text** | **str** | The text content of the status update. | -**html_text** | **str** | [Opt In](/docs/inputoutput-options). The text content of the status update with formatting as HTML. | [optional] -**status_type** | **str** | The type associated with the status update. This represents the current state of the object this object is on. | -**author** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**created_by** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**hearted** | **bool** | *Deprecated - please use liked instead* True if the status is hearted by the authorized user, false if not. | [optional] -**hearts** | [**list[GoalResponseLikes]**](GoalResponseLikes.md) | *Deprecated - please use likes instead* Array of likes for users who have hearted this status. | [optional] -**liked** | **bool** | True if the status is liked by the authorized user, false if not. | [optional] -**likes** | [**list[GoalResponseLikes]**](GoalResponseLikes.md) | Array of likes for users who have liked this status. | [optional] -**modified_at** | **datetime** | The time at which this project status was last modified. *Note: This does not currently reflect any changes in associations such as comments that may have been added or removed from the status.* | [optional] -**num_hearts** | **int** | *Deprecated - please use likes instead* The number of users who have hearted this status. | [optional] -**num_likes** | **int** | The number of users who have liked this status. | [optional] -**parent** | [**StatusUpdateResponseParent**](StatusUpdateResponseParent.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StatusUpdateResponseArray.md b/docs/StatusUpdateResponseArray.md deleted file mode 100644 index f41ff996..00000000 --- a/docs/StatusUpdateResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# StatusUpdateResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[StatusUpdateResponse]**](StatusUpdateResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StatusUpdateResponseData.md b/docs/StatusUpdateResponseData.md deleted file mode 100644 index aae6d4e2..00000000 --- a/docs/StatusUpdateResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# StatusUpdateResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**StatusUpdateResponse**](StatusUpdateResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StatusUpdateResponseParent.md b/docs/StatusUpdateResponseParent.md deleted file mode 100644 index 063ddb48..00000000 --- a/docs/StatusUpdateResponseParent.md +++ /dev/null @@ -1,11 +0,0 @@ -# StatusUpdateResponseParent - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StatusUpdatesApi.md b/docs/StatusUpdatesApi.md deleted file mode 100644 index 3cd052bd..00000000 --- a/docs/StatusUpdatesApi.md +++ /dev/null @@ -1,231 +0,0 @@ -# asana.StatusUpdatesApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_status_for_object**](StatusUpdatesApi.md#create_status_for_object) | **POST** /status_updates | Create a status update -[**delete_status**](StatusUpdatesApi.md#delete_status) | **DELETE** /status_updates/{status_update_gid} | Delete a status update -[**get_status**](StatusUpdatesApi.md#get_status) | **GET** /status_updates/{status_update_gid} | Get a status update -[**get_statuses_for_object**](StatusUpdatesApi.md#get_statuses_for_object) | **GET** /status_updates | Get status updates from an object - -# **create_status_for_object** -> StatusUpdateResponseData create_status_for_object(body, limit=limit, offset=offset, opt_fields=opt_fields) - -Create a status update - -Creates a new status update on an object. Returns the full record of the newly created status update. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.StatusUpdatesApi(api_client) -body = asana.StatusUpdatesBody({"param1": "value1", "param2": "value2",}) # StatusUpdatesBody | The status update to create. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["author","author.name","created_at","created_by","created_by.name","hearted","hearts","hearts.user","hearts.user.name","html_text","liked","likes","likes.user","likes.user.name","modified_at","num_hearts","num_likes","parent","parent.name","resource_subtype","status_type","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a status update - api_response = api_instance.create_status_for_object(body, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling StatusUpdatesApi->create_status_for_object: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**StatusUpdatesBody**](StatusUpdatesBody.md)| The status update to create. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**StatusUpdateResponseData**](StatusUpdateResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_status** -> EmptyResponseData delete_status(status_update_gid) - -Delete a status update - -Deletes a specific, existing status update. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.StatusUpdatesApi(api_client) -status_update_gid = '321654' # str | The status update to get. - -try: - # Delete a status update - api_response = api_instance.delete_status(status_update_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling StatusUpdatesApi->delete_status: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **status_update_gid** | **str**| The status update to get. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_status** -> StatusUpdateResponseData get_status(status_update_gid, opt_fields=opt_fields) - -Get a status update - -Returns the complete record for a single status update. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.StatusUpdatesApi(api_client) -status_update_gid = '321654' # str | The status update to get. -opt_fields = ["author","author.name","created_at","created_by","created_by.name","hearted","hearts","hearts.user","hearts.user.name","html_text","liked","likes","likes.user","likes.user.name","modified_at","num_hearts","num_likes","parent","parent.name","resource_subtype","status_type","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a status update - api_response = api_instance.get_status(status_update_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling StatusUpdatesApi->get_status: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **status_update_gid** | **str**| The status update to get. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**StatusUpdateResponseData**](StatusUpdateResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_statuses_for_object** -> StatusUpdateResponseArray get_statuses_for_object(parent, limit=limit, offset=offset, created_since=created_since, opt_fields=opt_fields) - -Get status updates from an object - -Returns the compact status update records for all updates on the object. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.StatusUpdatesApi(api_client) -parent = '159874' # str | Globally unique identifier for object to fetch statuses from. Must be a GID for a project, portfolio, or goal. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -created_since = '2012-02-22T02:06:58.158Z' # datetime | Only return statuses that have been created since the given time. (optional) -opt_fields = ["author","author.name","created_at","created_by","created_by.name","hearted","hearts","hearts.user","hearts.user.name","html_text","liked","likes","likes.user","likes.user.name","modified_at","num_hearts","num_likes","offset","parent","parent.name","path","resource_subtype","status_type","text","title","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get status updates from an object - api_response = api_instance.get_statuses_for_object(parent, limit=limit, offset=offset, created_since=created_since, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling StatusUpdatesApi->get_statuses_for_object: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **parent** | **str**| Globally unique identifier for object to fetch statuses from. Must be a GID for a project, portfolio, or goal. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **created_since** | **datetime**| Only return statuses that have been created since the given time. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**StatusUpdateResponseArray**](StatusUpdateResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/StatusUpdatesApi.yaml b/docs/StatusUpdatesApi.yaml deleted file mode 100644 index 31c91173..00000000 --- a/docs/StatusUpdatesApi.yaml +++ /dev/null @@ -1,89 +0,0 @@ -StatusUpdatesApi: - create_status_for_object: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.StatusUpdatesApi(api_client) - body = asana.StatusUpdatesBody({"param1": "value1", "param2": "value2",}) # StatusUpdatesBody | The status update to create. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["author","author.name","created_at","created_by","created_by.name","hearted","hearts","hearts.user","hearts.user.name","html_text","liked","likes","likes.user","likes.user.name","modified_at","num_hearts","num_likes","parent","parent.name","resource_subtype","status_type","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a status update - api_response = api_instance.create_status_for_object(body, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling StatusUpdatesApi->create_status_for_object: %s\n" % e) - delete_status: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.StatusUpdatesApi(api_client) - status_update_gid = '321654' # str | The status update to get. - - try: - # Delete a status update - api_response = api_instance.delete_status(status_update_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling StatusUpdatesApi->delete_status: %s\n" % e) - get_status: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.StatusUpdatesApi(api_client) - status_update_gid = '321654' # str | The status update to get. - opt_fields = ["author","author.name","created_at","created_by","created_by.name","hearted","hearts","hearts.user","hearts.user.name","html_text","liked","likes","likes.user","likes.user.name","modified_at","num_hearts","num_likes","parent","parent.name","resource_subtype","status_type","text","title"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a status update - api_response = api_instance.get_status(status_update_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling StatusUpdatesApi->get_status: %s\n" % e) - get_statuses_for_object: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.StatusUpdatesApi(api_client) - parent = '159874' # str | Globally unique identifier for object to fetch statuses from. Must be a GID for a project, portfolio, or goal. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - created_since = '2012-02-22T02:06:58.158Z' # datetime | Only return statuses that have been created since the given time. (optional) - opt_fields = ["author","author.name","created_at","created_by","created_by.name","hearted","hearts","hearts.user","hearts.user.name","html_text","liked","likes","likes.user","likes.user.name","modified_at","num_hearts","num_likes","offset","parent","parent.name","path","resource_subtype","status_type","text","title","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get status updates from an object - api_response = api_instance.get_statuses_for_object(parent, limit=limit, offset=offset, created_since=created_since, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling StatusUpdatesApi->get_statuses_for_object: %s\n" % e) diff --git a/docs/StatusUpdatesBody.md b/docs/StatusUpdatesBody.md deleted file mode 100644 index 4fe6d8de..00000000 --- a/docs/StatusUpdatesBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# StatusUpdatesBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**StatusUpdateRequest**](StatusUpdateRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoriesApi.md b/docs/StoriesApi.md deleted file mode 100644 index 042d0d12..00000000 --- a/docs/StoriesApi.md +++ /dev/null @@ -1,283 +0,0 @@ -# asana.StoriesApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_story_for_task**](StoriesApi.md#create_story_for_task) | **POST** /tasks/{task_gid}/stories | Create a story on a task -[**delete_story**](StoriesApi.md#delete_story) | **DELETE** /stories/{story_gid} | Delete a story -[**get_stories_for_task**](StoriesApi.md#get_stories_for_task) | **GET** /tasks/{task_gid}/stories | Get stories from a task -[**get_story**](StoriesApi.md#get_story) | **GET** /stories/{story_gid} | Get a story -[**update_story**](StoriesApi.md#update_story) | **PUT** /stories/{story_gid} | Update a story - -# **create_story_for_task** -> StoryResponseData create_story_for_task(body, task_gid, opt_fields=opt_fields) - -Create a story on a task - -Adds a story to a task. This endpoint currently only allows for comment stories to be created. The comment will be authored by the currently authenticated user, and timestamped when the server receives the request. Returns the full record for the new story added to the task. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.StoriesApi(api_client) -body = asana.TaskGidStoriesBody({"param1": "value1", "param2": "value2",}) # TaskGidStoriesBody | The story to create. -task_gid = '321654' # str | The task to operate on. -opt_fields = ["assignee","assignee.name","created_at","created_by","created_by.name","custom_field","custom_field.date_value","custom_field.date_value.date","custom_field.date_value.date_time","custom_field.display_value","custom_field.enabled","custom_field.enum_options","custom_field.enum_options.color","custom_field.enum_options.enabled","custom_field.enum_options.name","custom_field.enum_value","custom_field.enum_value.color","custom_field.enum_value.enabled","custom_field.enum_value.name","custom_field.is_formula_field","custom_field.multi_enum_values","custom_field.multi_enum_values.color","custom_field.multi_enum_values.enabled","custom_field.multi_enum_values.name","custom_field.name","custom_field.number_value","custom_field.resource_subtype","custom_field.text_value","custom_field.type","dependency","dependency.created_by","dependency.name","dependency.resource_subtype","duplicate_of","duplicate_of.created_by","duplicate_of.name","duplicate_of.resource_subtype","duplicated_from","duplicated_from.created_by","duplicated_from.name","duplicated_from.resource_subtype","follower","follower.name","hearted","hearts","hearts.user","hearts.user.name","html_text","is_editable","is_edited","is_pinned","liked","likes","likes.user","likes.user.name","new_approval_status","new_date_value","new_dates","new_dates.due_at","new_dates.due_on","new_dates.start_on","new_enum_value","new_enum_value.color","new_enum_value.enabled","new_enum_value.name","new_multi_enum_values","new_multi_enum_values.color","new_multi_enum_values.enabled","new_multi_enum_values.name","new_name","new_number_value","new_people_value","new_people_value.name","new_resource_subtype","new_section","new_section.name","new_text_value","num_hearts","num_likes","old_approval_status","old_date_value","old_dates","old_dates.due_at","old_dates.due_on","old_dates.start_on","old_enum_value","old_enum_value.color","old_enum_value.enabled","old_enum_value.name","old_multi_enum_values","old_multi_enum_values.color","old_multi_enum_values.enabled","old_multi_enum_values.name","old_name","old_number_value","old_people_value","old_people_value.name","old_resource_subtype","old_section","old_section.name","old_text_value","previews","previews.fallback","previews.footer","previews.header","previews.header_link","previews.html_text","previews.text","previews.title","previews.title_link","project","project.name","resource_subtype","source","sticker_name","story","story.created_at","story.created_by","story.created_by.name","story.resource_subtype","story.text","tag","tag.name","target","target.created_by","target.name","target.resource_subtype","task","task.created_by","task.name","task.resource_subtype","text","type"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a story on a task - api_response = api_instance.create_story_for_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling StoriesApi->create_story_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidStoriesBody**](TaskGidStoriesBody.md)| The story to create. | - **task_gid** | **str**| The task to operate on. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**StoryResponseData**](StoryResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_story** -> EmptyResponseData delete_story(story_gid) - -Delete a story - -Deletes a story. A user can only delete stories they have created. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.StoriesApi(api_client) -story_gid = '35678' # str | Globally unique identifier for the story. - -try: - # Delete a story - api_response = api_instance.delete_story(story_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling StoriesApi->delete_story: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **story_gid** | **str**| Globally unique identifier for the story. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_stories_for_task** -> StoryResponseArray get_stories_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get stories from a task - -Returns the compact records for all stories on the task. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.StoriesApi(api_client) -task_gid = '321654' # str | The task to operate on. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["assignee","assignee.name","created_at","created_by","created_by.name","custom_field","custom_field.date_value","custom_field.date_value.date","custom_field.date_value.date_time","custom_field.display_value","custom_field.enabled","custom_field.enum_options","custom_field.enum_options.color","custom_field.enum_options.enabled","custom_field.enum_options.name","custom_field.enum_value","custom_field.enum_value.color","custom_field.enum_value.enabled","custom_field.enum_value.name","custom_field.is_formula_field","custom_field.multi_enum_values","custom_field.multi_enum_values.color","custom_field.multi_enum_values.enabled","custom_field.multi_enum_values.name","custom_field.name","custom_field.number_value","custom_field.resource_subtype","custom_field.text_value","custom_field.type","dependency","dependency.created_by","dependency.name","dependency.resource_subtype","duplicate_of","duplicate_of.created_by","duplicate_of.name","duplicate_of.resource_subtype","duplicated_from","duplicated_from.created_by","duplicated_from.name","duplicated_from.resource_subtype","follower","follower.name","hearted","hearts","hearts.user","hearts.user.name","html_text","is_editable","is_edited","is_pinned","liked","likes","likes.user","likes.user.name","new_approval_status","new_date_value","new_dates","new_dates.due_at","new_dates.due_on","new_dates.start_on","new_enum_value","new_enum_value.color","new_enum_value.enabled","new_enum_value.name","new_multi_enum_values","new_multi_enum_values.color","new_multi_enum_values.enabled","new_multi_enum_values.name","new_name","new_number_value","new_people_value","new_people_value.name","new_resource_subtype","new_section","new_section.name","new_text_value","num_hearts","num_likes","offset","old_approval_status","old_date_value","old_dates","old_dates.due_at","old_dates.due_on","old_dates.start_on","old_enum_value","old_enum_value.color","old_enum_value.enabled","old_enum_value.name","old_multi_enum_values","old_multi_enum_values.color","old_multi_enum_values.enabled","old_multi_enum_values.name","old_name","old_number_value","old_people_value","old_people_value.name","old_resource_subtype","old_section","old_section.name","old_text_value","path","previews","previews.fallback","previews.footer","previews.header","previews.header_link","previews.html_text","previews.text","previews.title","previews.title_link","project","project.name","resource_subtype","source","sticker_name","story","story.created_at","story.created_by","story.created_by.name","story.resource_subtype","story.text","tag","tag.name","target","target.created_by","target.name","target.resource_subtype","task","task.created_by","task.name","task.resource_subtype","text","type","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get stories from a task - api_response = api_instance.get_stories_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling StoriesApi->get_stories_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **task_gid** | **str**| The task to operate on. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**StoryResponseArray**](StoryResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_story** -> StoryResponseData get_story(story_gid, opt_fields=opt_fields) - -Get a story - -Returns the full record for a single story. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.StoriesApi(api_client) -story_gid = '35678' # str | Globally unique identifier for the story. -opt_fields = ["assignee","assignee.name","created_at","created_by","created_by.name","custom_field","custom_field.date_value","custom_field.date_value.date","custom_field.date_value.date_time","custom_field.display_value","custom_field.enabled","custom_field.enum_options","custom_field.enum_options.color","custom_field.enum_options.enabled","custom_field.enum_options.name","custom_field.enum_value","custom_field.enum_value.color","custom_field.enum_value.enabled","custom_field.enum_value.name","custom_field.is_formula_field","custom_field.multi_enum_values","custom_field.multi_enum_values.color","custom_field.multi_enum_values.enabled","custom_field.multi_enum_values.name","custom_field.name","custom_field.number_value","custom_field.resource_subtype","custom_field.text_value","custom_field.type","dependency","dependency.created_by","dependency.name","dependency.resource_subtype","duplicate_of","duplicate_of.created_by","duplicate_of.name","duplicate_of.resource_subtype","duplicated_from","duplicated_from.created_by","duplicated_from.name","duplicated_from.resource_subtype","follower","follower.name","hearted","hearts","hearts.user","hearts.user.name","html_text","is_editable","is_edited","is_pinned","liked","likes","likes.user","likes.user.name","new_approval_status","new_date_value","new_dates","new_dates.due_at","new_dates.due_on","new_dates.start_on","new_enum_value","new_enum_value.color","new_enum_value.enabled","new_enum_value.name","new_multi_enum_values","new_multi_enum_values.color","new_multi_enum_values.enabled","new_multi_enum_values.name","new_name","new_number_value","new_people_value","new_people_value.name","new_resource_subtype","new_section","new_section.name","new_text_value","num_hearts","num_likes","old_approval_status","old_date_value","old_dates","old_dates.due_at","old_dates.due_on","old_dates.start_on","old_enum_value","old_enum_value.color","old_enum_value.enabled","old_enum_value.name","old_multi_enum_values","old_multi_enum_values.color","old_multi_enum_values.enabled","old_multi_enum_values.name","old_name","old_number_value","old_people_value","old_people_value.name","old_resource_subtype","old_section","old_section.name","old_text_value","previews","previews.fallback","previews.footer","previews.header","previews.header_link","previews.html_text","previews.text","previews.title","previews.title_link","project","project.name","resource_subtype","source","sticker_name","story","story.created_at","story.created_by","story.created_by.name","story.resource_subtype","story.text","tag","tag.name","target","target.created_by","target.name","target.resource_subtype","task","task.created_by","task.name","task.resource_subtype","text","type"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a story - api_response = api_instance.get_story(story_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling StoriesApi->get_story: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **story_gid** | **str**| Globally unique identifier for the story. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**StoryResponseData**](StoryResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_story** -> StoryResponseData update_story(body, story_gid, opt_fields=opt_fields) - -Update a story - -Updates the story and returns the full record for the updated story. Only comment stories can have their text updated, and only comment stories and attachment stories can be pinned. Only one of `text` and `html_text` can be specified. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.StoriesApi(api_client) -body = asana.StoriesStoryGidBody({"param1": "value1", "param2": "value2",}) # StoriesStoryGidBody | The comment story to update. -story_gid = '35678' # str | Globally unique identifier for the story. -opt_fields = ["assignee","assignee.name","created_at","created_by","created_by.name","custom_field","custom_field.date_value","custom_field.date_value.date","custom_field.date_value.date_time","custom_field.display_value","custom_field.enabled","custom_field.enum_options","custom_field.enum_options.color","custom_field.enum_options.enabled","custom_field.enum_options.name","custom_field.enum_value","custom_field.enum_value.color","custom_field.enum_value.enabled","custom_field.enum_value.name","custom_field.is_formula_field","custom_field.multi_enum_values","custom_field.multi_enum_values.color","custom_field.multi_enum_values.enabled","custom_field.multi_enum_values.name","custom_field.name","custom_field.number_value","custom_field.resource_subtype","custom_field.text_value","custom_field.type","dependency","dependency.created_by","dependency.name","dependency.resource_subtype","duplicate_of","duplicate_of.created_by","duplicate_of.name","duplicate_of.resource_subtype","duplicated_from","duplicated_from.created_by","duplicated_from.name","duplicated_from.resource_subtype","follower","follower.name","hearted","hearts","hearts.user","hearts.user.name","html_text","is_editable","is_edited","is_pinned","liked","likes","likes.user","likes.user.name","new_approval_status","new_date_value","new_dates","new_dates.due_at","new_dates.due_on","new_dates.start_on","new_enum_value","new_enum_value.color","new_enum_value.enabled","new_enum_value.name","new_multi_enum_values","new_multi_enum_values.color","new_multi_enum_values.enabled","new_multi_enum_values.name","new_name","new_number_value","new_people_value","new_people_value.name","new_resource_subtype","new_section","new_section.name","new_text_value","num_hearts","num_likes","old_approval_status","old_date_value","old_dates","old_dates.due_at","old_dates.due_on","old_dates.start_on","old_enum_value","old_enum_value.color","old_enum_value.enabled","old_enum_value.name","old_multi_enum_values","old_multi_enum_values.color","old_multi_enum_values.enabled","old_multi_enum_values.name","old_name","old_number_value","old_people_value","old_people_value.name","old_resource_subtype","old_section","old_section.name","old_text_value","previews","previews.fallback","previews.footer","previews.header","previews.header_link","previews.html_text","previews.text","previews.title","previews.title_link","project","project.name","resource_subtype","source","sticker_name","story","story.created_at","story.created_by","story.created_by.name","story.resource_subtype","story.text","tag","tag.name","target","target.created_by","target.name","target.resource_subtype","task","task.created_by","task.name","task.resource_subtype","text","type"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a story - api_response = api_instance.update_story(body, story_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling StoriesApi->update_story: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**StoriesStoryGidBody**](StoriesStoryGidBody.md)| The comment story to update. | - **story_gid** | **str**| Globally unique identifier for the story. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**StoryResponseData**](StoryResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/StoriesApi.yaml b/docs/StoriesApi.yaml deleted file mode 100644 index 976bc36e..00000000 --- a/docs/StoriesApi.yaml +++ /dev/null @@ -1,109 +0,0 @@ -StoriesApi: - create_story_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.StoriesApi(api_client) - body = asana.TaskGidStoriesBody({"param1": "value1", "param2": "value2",}) # TaskGidStoriesBody | The story to create. - task_gid = '321654' # str | The task to operate on. - opt_fields = ["assignee","assignee.name","created_at","created_by","created_by.name","custom_field","custom_field.date_value","custom_field.date_value.date","custom_field.date_value.date_time","custom_field.display_value","custom_field.enabled","custom_field.enum_options","custom_field.enum_options.color","custom_field.enum_options.enabled","custom_field.enum_options.name","custom_field.enum_value","custom_field.enum_value.color","custom_field.enum_value.enabled","custom_field.enum_value.name","custom_field.is_formula_field","custom_field.multi_enum_values","custom_field.multi_enum_values.color","custom_field.multi_enum_values.enabled","custom_field.multi_enum_values.name","custom_field.name","custom_field.number_value","custom_field.resource_subtype","custom_field.text_value","custom_field.type","dependency","dependency.created_by","dependency.name","dependency.resource_subtype","duplicate_of","duplicate_of.created_by","duplicate_of.name","duplicate_of.resource_subtype","duplicated_from","duplicated_from.created_by","duplicated_from.name","duplicated_from.resource_subtype","follower","follower.name","hearted","hearts","hearts.user","hearts.user.name","html_text","is_editable","is_edited","is_pinned","liked","likes","likes.user","likes.user.name","new_approval_status","new_date_value","new_dates","new_dates.due_at","new_dates.due_on","new_dates.start_on","new_enum_value","new_enum_value.color","new_enum_value.enabled","new_enum_value.name","new_multi_enum_values","new_multi_enum_values.color","new_multi_enum_values.enabled","new_multi_enum_values.name","new_name","new_number_value","new_people_value","new_people_value.name","new_resource_subtype","new_section","new_section.name","new_text_value","num_hearts","num_likes","old_approval_status","old_date_value","old_dates","old_dates.due_at","old_dates.due_on","old_dates.start_on","old_enum_value","old_enum_value.color","old_enum_value.enabled","old_enum_value.name","old_multi_enum_values","old_multi_enum_values.color","old_multi_enum_values.enabled","old_multi_enum_values.name","old_name","old_number_value","old_people_value","old_people_value.name","old_resource_subtype","old_section","old_section.name","old_text_value","previews","previews.fallback","previews.footer","previews.header","previews.header_link","previews.html_text","previews.text","previews.title","previews.title_link","project","project.name","resource_subtype","source","sticker_name","story","story.created_at","story.created_by","story.created_by.name","story.resource_subtype","story.text","tag","tag.name","target","target.created_by","target.name","target.resource_subtype","task","task.created_by","task.name","task.resource_subtype","text","type"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a story on a task - api_response = api_instance.create_story_for_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling StoriesApi->create_story_for_task: %s\n" % e) - delete_story: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.StoriesApi(api_client) - story_gid = '35678' # str | Globally unique identifier for the story. - - try: - # Delete a story - api_response = api_instance.delete_story(story_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling StoriesApi->delete_story: %s\n" % e) - get_stories_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.StoriesApi(api_client) - task_gid = '321654' # str | The task to operate on. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["assignee","assignee.name","created_at","created_by","created_by.name","custom_field","custom_field.date_value","custom_field.date_value.date","custom_field.date_value.date_time","custom_field.display_value","custom_field.enabled","custom_field.enum_options","custom_field.enum_options.color","custom_field.enum_options.enabled","custom_field.enum_options.name","custom_field.enum_value","custom_field.enum_value.color","custom_field.enum_value.enabled","custom_field.enum_value.name","custom_field.is_formula_field","custom_field.multi_enum_values","custom_field.multi_enum_values.color","custom_field.multi_enum_values.enabled","custom_field.multi_enum_values.name","custom_field.name","custom_field.number_value","custom_field.resource_subtype","custom_field.text_value","custom_field.type","dependency","dependency.created_by","dependency.name","dependency.resource_subtype","duplicate_of","duplicate_of.created_by","duplicate_of.name","duplicate_of.resource_subtype","duplicated_from","duplicated_from.created_by","duplicated_from.name","duplicated_from.resource_subtype","follower","follower.name","hearted","hearts","hearts.user","hearts.user.name","html_text","is_editable","is_edited","is_pinned","liked","likes","likes.user","likes.user.name","new_approval_status","new_date_value","new_dates","new_dates.due_at","new_dates.due_on","new_dates.start_on","new_enum_value","new_enum_value.color","new_enum_value.enabled","new_enum_value.name","new_multi_enum_values","new_multi_enum_values.color","new_multi_enum_values.enabled","new_multi_enum_values.name","new_name","new_number_value","new_people_value","new_people_value.name","new_resource_subtype","new_section","new_section.name","new_text_value","num_hearts","num_likes","offset","old_approval_status","old_date_value","old_dates","old_dates.due_at","old_dates.due_on","old_dates.start_on","old_enum_value","old_enum_value.color","old_enum_value.enabled","old_enum_value.name","old_multi_enum_values","old_multi_enum_values.color","old_multi_enum_values.enabled","old_multi_enum_values.name","old_name","old_number_value","old_people_value","old_people_value.name","old_resource_subtype","old_section","old_section.name","old_text_value","path","previews","previews.fallback","previews.footer","previews.header","previews.header_link","previews.html_text","previews.text","previews.title","previews.title_link","project","project.name","resource_subtype","source","sticker_name","story","story.created_at","story.created_by","story.created_by.name","story.resource_subtype","story.text","tag","tag.name","target","target.created_by","target.name","target.resource_subtype","task","task.created_by","task.name","task.resource_subtype","text","type","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get stories from a task - api_response = api_instance.get_stories_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling StoriesApi->get_stories_for_task: %s\n" % e) - get_story: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.StoriesApi(api_client) - story_gid = '35678' # str | Globally unique identifier for the story. - opt_fields = ["assignee","assignee.name","created_at","created_by","created_by.name","custom_field","custom_field.date_value","custom_field.date_value.date","custom_field.date_value.date_time","custom_field.display_value","custom_field.enabled","custom_field.enum_options","custom_field.enum_options.color","custom_field.enum_options.enabled","custom_field.enum_options.name","custom_field.enum_value","custom_field.enum_value.color","custom_field.enum_value.enabled","custom_field.enum_value.name","custom_field.is_formula_field","custom_field.multi_enum_values","custom_field.multi_enum_values.color","custom_field.multi_enum_values.enabled","custom_field.multi_enum_values.name","custom_field.name","custom_field.number_value","custom_field.resource_subtype","custom_field.text_value","custom_field.type","dependency","dependency.created_by","dependency.name","dependency.resource_subtype","duplicate_of","duplicate_of.created_by","duplicate_of.name","duplicate_of.resource_subtype","duplicated_from","duplicated_from.created_by","duplicated_from.name","duplicated_from.resource_subtype","follower","follower.name","hearted","hearts","hearts.user","hearts.user.name","html_text","is_editable","is_edited","is_pinned","liked","likes","likes.user","likes.user.name","new_approval_status","new_date_value","new_dates","new_dates.due_at","new_dates.due_on","new_dates.start_on","new_enum_value","new_enum_value.color","new_enum_value.enabled","new_enum_value.name","new_multi_enum_values","new_multi_enum_values.color","new_multi_enum_values.enabled","new_multi_enum_values.name","new_name","new_number_value","new_people_value","new_people_value.name","new_resource_subtype","new_section","new_section.name","new_text_value","num_hearts","num_likes","old_approval_status","old_date_value","old_dates","old_dates.due_at","old_dates.due_on","old_dates.start_on","old_enum_value","old_enum_value.color","old_enum_value.enabled","old_enum_value.name","old_multi_enum_values","old_multi_enum_values.color","old_multi_enum_values.enabled","old_multi_enum_values.name","old_name","old_number_value","old_people_value","old_people_value.name","old_resource_subtype","old_section","old_section.name","old_text_value","previews","previews.fallback","previews.footer","previews.header","previews.header_link","previews.html_text","previews.text","previews.title","previews.title_link","project","project.name","resource_subtype","source","sticker_name","story","story.created_at","story.created_by","story.created_by.name","story.resource_subtype","story.text","tag","tag.name","target","target.created_by","target.name","target.resource_subtype","task","task.created_by","task.name","task.resource_subtype","text","type"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a story - api_response = api_instance.get_story(story_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling StoriesApi->get_story: %s\n" % e) - update_story: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.StoriesApi(api_client) - body = asana.StoriesStoryGidBody({"param1": "value1", "param2": "value2",}) # StoriesStoryGidBody | The comment story to update. - story_gid = '35678' # str | Globally unique identifier for the story. - opt_fields = ["assignee","assignee.name","created_at","created_by","created_by.name","custom_field","custom_field.date_value","custom_field.date_value.date","custom_field.date_value.date_time","custom_field.display_value","custom_field.enabled","custom_field.enum_options","custom_field.enum_options.color","custom_field.enum_options.enabled","custom_field.enum_options.name","custom_field.enum_value","custom_field.enum_value.color","custom_field.enum_value.enabled","custom_field.enum_value.name","custom_field.is_formula_field","custom_field.multi_enum_values","custom_field.multi_enum_values.color","custom_field.multi_enum_values.enabled","custom_field.multi_enum_values.name","custom_field.name","custom_field.number_value","custom_field.resource_subtype","custom_field.text_value","custom_field.type","dependency","dependency.created_by","dependency.name","dependency.resource_subtype","duplicate_of","duplicate_of.created_by","duplicate_of.name","duplicate_of.resource_subtype","duplicated_from","duplicated_from.created_by","duplicated_from.name","duplicated_from.resource_subtype","follower","follower.name","hearted","hearts","hearts.user","hearts.user.name","html_text","is_editable","is_edited","is_pinned","liked","likes","likes.user","likes.user.name","new_approval_status","new_date_value","new_dates","new_dates.due_at","new_dates.due_on","new_dates.start_on","new_enum_value","new_enum_value.color","new_enum_value.enabled","new_enum_value.name","new_multi_enum_values","new_multi_enum_values.color","new_multi_enum_values.enabled","new_multi_enum_values.name","new_name","new_number_value","new_people_value","new_people_value.name","new_resource_subtype","new_section","new_section.name","new_text_value","num_hearts","num_likes","old_approval_status","old_date_value","old_dates","old_dates.due_at","old_dates.due_on","old_dates.start_on","old_enum_value","old_enum_value.color","old_enum_value.enabled","old_enum_value.name","old_multi_enum_values","old_multi_enum_values.color","old_multi_enum_values.enabled","old_multi_enum_values.name","old_name","old_number_value","old_people_value","old_people_value.name","old_resource_subtype","old_section","old_section.name","old_text_value","previews","previews.fallback","previews.footer","previews.header","previews.header_link","previews.html_text","previews.text","previews.title","previews.title_link","project","project.name","resource_subtype","source","sticker_name","story","story.created_at","story.created_by","story.created_by.name","story.resource_subtype","story.text","tag","tag.name","target","target.created_by","target.name","target.resource_subtype","task","task.created_by","task.name","task.resource_subtype","text","type"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a story - api_response = api_instance.update_story(body, story_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling StoriesApi->update_story: %s\n" % e) diff --git a/docs/StoriesStoryGidBody.md b/docs/StoriesStoryGidBody.md deleted file mode 100644 index 364c400c..00000000 --- a/docs/StoriesStoryGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# StoriesStoryGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**StoryRequest**](StoryRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryBase.md b/docs/StoryBase.md deleted file mode 100644 index 421adfe4..00000000 --- a/docs/StoryBase.md +++ /dev/null @@ -1,16 +0,0 @@ -# StoryBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**text** | **str** | The plain text of the comment to add. Cannot be used with html_text. | [optional] -**html_text** | **str** | [Opt In](/docs/inputoutput-options). HTML formatted text for a comment. This will not include the name of the creator. | [optional] -**is_pinned** | **bool** | *Conditional*. Whether the story should be pinned on the resource. | [optional] -**sticker_name** | **str** | The name of the sticker in this story. `null` if there is no sticker. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryCompact.md b/docs/StoryCompact.md deleted file mode 100644 index 270e65ce..00000000 --- a/docs/StoryCompact.md +++ /dev/null @@ -1,14 +0,0 @@ -# StoryCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**created_by** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**text** | **str** | *Create-only*. Human-readable text for the story or comment. This will not include the name of the creator. *Note: This is not guaranteed to be stable for a given type of story. For example, text for a reassignment may not always say “assigned to …” as the text for a story can both be edited and change based on the language settings of the user making the request.* Use the `resource_subtype` property to discover the action that created the story. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryRequest.md b/docs/StoryRequest.md deleted file mode 100644 index 4bb32f2e..00000000 --- a/docs/StoryRequest.md +++ /dev/null @@ -1,16 +0,0 @@ -# StoryRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**text** | **str** | The plain text of the comment to add. Cannot be used with html_text. | [optional] -**html_text** | **str** | [Opt In](/docs/inputoutput-options). HTML formatted text for a comment. This will not include the name of the creator. | [optional] -**is_pinned** | **bool** | *Conditional*. Whether the story should be pinned on the resource. | [optional] -**sticker_name** | **str** | The name of the sticker in this story. `null` if there is no sticker. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponse.md b/docs/StoryResponse.md deleted file mode 100644 index e897a161..00000000 --- a/docs/StoryResponse.md +++ /dev/null @@ -1,61 +0,0 @@ -# StoryResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**text** | **str** | The plain text of the comment to add. Cannot be used with html_text. | [optional] -**html_text** | **str** | [Opt In](/docs/inputoutput-options). HTML formatted text for a comment. This will not include the name of the creator. | [optional] -**is_pinned** | **bool** | *Conditional*. Whether the story should be pinned on the resource. | [optional] -**sticker_name** | **str** | The name of the sticker in this story. `null` if there is no sticker. | [optional] -**created_by** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**type** | **str** | | [optional] -**is_editable** | **bool** | *Conditional*. Whether the text of the story can be edited after creation. | [optional] -**is_edited** | **bool** | *Conditional*. Whether the text of the story has been edited after creation. | [optional] -**hearted** | **bool** | *Deprecated - please use likes instead* *Conditional*. True if the story is hearted by the authorized user, false if not. | [optional] -**hearts** | [**list[GoalResponseLikes]**](GoalResponseLikes.md) | *Deprecated - please use likes instead* *Conditional*. Array of likes for users who have hearted this story. | [optional] -**num_hearts** | **int** | *Deprecated - please use likes instead* *Conditional*. The number of users who have hearted this story. | [optional] -**liked** | **bool** | *Conditional*. True if the story is liked by the authorized user, false if not. | [optional] -**likes** | [**list[GoalResponseLikes]**](GoalResponseLikes.md) | *Conditional*. Array of likes for users who have liked this story. | [optional] -**num_likes** | **int** | *Conditional*. The number of users who have liked this story. | [optional] -**previews** | [**list[StoryResponsePreviews]**](StoryResponsePreviews.md) | *Conditional*. A collection of previews to be displayed in the story. *Note: This property only exists for comment stories.* | [optional] -**old_name** | **str** | *Conditional*' | [optional] -**new_name** | **str** | *Conditional* | [optional] -**old_dates** | [**StoryResponseOldDates**](StoryResponseOldDates.md) | | [optional] -**new_dates** | [**StoryResponseOldDates**](StoryResponseOldDates.md) | | [optional] -**old_resource_subtype** | **str** | *Conditional* | [optional] -**new_resource_subtype** | **str** | *Conditional* | [optional] -**story** | [**StoryResponseStory**](StoryResponseStory.md) | | [optional] -**assignee** | [**StoryResponseAssignee**](StoryResponseAssignee.md) | | [optional] -**follower** | [**StoryResponseAssignee**](StoryResponseAssignee.md) | | [optional] -**old_section** | [**StoryResponseOldSection**](StoryResponseOldSection.md) | | [optional] -**new_section** | [**StoryResponseOldSection**](StoryResponseOldSection.md) | | [optional] -**task** | [**StoryResponseTask**](StoryResponseTask.md) | | [optional] -**project** | [**StoryResponseProject**](StoryResponseProject.md) | | [optional] -**tag** | [**StoryResponseTag**](StoryResponseTag.md) | | [optional] -**custom_field** | [**StoryResponseCustomField**](StoryResponseCustomField.md) | | [optional] -**old_text_value** | **str** | *Conditional* | [optional] -**new_text_value** | **str** | *Conditional* | [optional] -**old_number_value** | **int** | *Conditional* | [optional] -**new_number_value** | **int** | *Conditional* | [optional] -**old_enum_value** | [**StoryResponseOldEnumValue**](StoryResponseOldEnumValue.md) | | [optional] -**new_enum_value** | [**StoryResponseOldEnumValue**](StoryResponseOldEnumValue.md) | | [optional] -**old_date_value** | **AllOfStoryResponseOldDateValue** | | [optional] -**new_date_value** | **AllOfStoryResponseNewDateValue** | | [optional] -**old_people_value** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | *Conditional*. The old value of a people custom field story. | [optional] -**new_people_value** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | *Conditional*. The new value of a people custom field story. | [optional] -**old_multi_enum_values** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. The old value of a multi-enum custom field story. | [optional] -**new_multi_enum_values** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. The new value of a multi-enum custom field story. | [optional] -**new_approval_status** | **str** | *Conditional*. The new value of approval status. | [optional] -**old_approval_status** | **str** | *Conditional*. The old value of approval status. | [optional] -**duplicate_of** | [**StoryResponseTask**](StoryResponseTask.md) | | [optional] -**duplicated_from** | [**StoryResponseTask**](StoryResponseTask.md) | | [optional] -**dependency** | [**StoryResponseTask**](StoryResponseTask.md) | | [optional] -**source** | **str** | The component of the Asana product the user used to trigger the story. | [optional] -**target** | [**StoryResponseTarget**](StoryResponseTarget.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponseArray.md b/docs/StoryResponseArray.md deleted file mode 100644 index d5780c2b..00000000 --- a/docs/StoryResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# StoryResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[StoryResponse]**](StoryResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponseAssignee.md b/docs/StoryResponseAssignee.md deleted file mode 100644 index f06b94cc..00000000 --- a/docs/StoryResponseAssignee.md +++ /dev/null @@ -1,11 +0,0 @@ -# StoryResponseAssignee - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | *Read-only except when same user as requester*. The user’s name. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponseCustomField.md b/docs/StoryResponseCustomField.md deleted file mode 100644 index 60f174a0..00000000 --- a/docs/StoryResponseCustomField.md +++ /dev/null @@ -1,22 +0,0 @@ -# StoryResponseCustomField - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the custom field. | [optional] -**resource_subtype** | **str** | The type of the custom field. Must be one of the given values. | [optional] -**type** | **str** | *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. | [optional] -**enum_options** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). | [optional] -**enabled** | **bool** | *Conditional*. Determines if the custom field is enabled or not. | [optional] -**is_formula_field** | **bool** | *Conditional*. This flag describes whether a custom field is a formula custom field. | [optional] -**date_value** | [**CustomFieldBaseDateValue**](CustomFieldBaseDateValue.md) | | [optional] -**enum_value** | [**CustomFieldBaseEnumValue**](CustomFieldBaseEnumValue.md) | | [optional] -**multi_enum_values** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. | [optional] -**number_value** | **float** | *Conditional*. This number is the value of a `number` custom field. | [optional] -**text_value** | **str** | *Conditional*. This string is the value of a `text` custom field. | [optional] -**display_value** | **str** | A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponseData.md b/docs/StoryResponseData.md deleted file mode 100644 index 9b7dab7d..00000000 --- a/docs/StoryResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# StoryResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**StoryResponse**](StoryResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponseDates.md b/docs/StoryResponseDates.md deleted file mode 100644 index 064cb734..00000000 --- a/docs/StoryResponseDates.md +++ /dev/null @@ -1,11 +0,0 @@ -# StoryResponseDates - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**start_on** | **date** | The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. | [optional] -**due_at** | **datetime** | The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. | [optional] -**due_on** | **date** | The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponseOldDates.md b/docs/StoryResponseOldDates.md deleted file mode 100644 index b3f681d0..00000000 --- a/docs/StoryResponseOldDates.md +++ /dev/null @@ -1,11 +0,0 @@ -# StoryResponseOldDates - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**start_on** | **date** | The day on which work for this goal begins, or null if the goal has no start date. This takes a date with `YYYY-MM-DD` format, and cannot be set unless there is an accompanying due date. | [optional] -**due_at** | **datetime** | The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. | [optional] -**due_on** | **date** | The localized day on which this goal is due. This takes a date with format `YYYY-MM-DD`. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponseOldEnumValue.md b/docs/StoryResponseOldEnumValue.md deleted file mode 100644 index 12fe056d..00000000 --- a/docs/StoryResponseOldEnumValue.md +++ /dev/null @@ -1,13 +0,0 @@ -# StoryResponseOldEnumValue - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the enum option. | [optional] -**enabled** | **bool** | Whether or not the enum option is a selectable value for the custom field. | [optional] -**color** | **str** | The color of the enum option. Defaults to ‘none’. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponseOldSection.md b/docs/StoryResponseOldSection.md deleted file mode 100644 index 4fa6658f..00000000 --- a/docs/StoryResponseOldSection.md +++ /dev/null @@ -1,11 +0,0 @@ -# StoryResponseOldSection - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the section (i.e. the text displayed as the section header). | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponsePreviews.md b/docs/StoryResponsePreviews.md deleted file mode 100644 index 92760828..00000000 --- a/docs/StoryResponsePreviews.md +++ /dev/null @@ -1,16 +0,0 @@ -# StoryResponsePreviews - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**fallback** | **str** | Some fallback text to display if unable to display the full preview. | [optional] -**footer** | **str** | Text to display in the footer. | [optional] -**header** | **str** | Text to display in the header. | [optional] -**header_link** | **str** | Where the header will link to. | [optional] -**html_text** | **str** | HTML formatted text for the body of the preview. | [optional] -**text** | **str** | Text for the body of the preview. | [optional] -**title** | **str** | Text to display as the title. | [optional] -**title_link** | **str** | Where to title will link to. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponseProject.md b/docs/StoryResponseProject.md deleted file mode 100644 index 5d086d21..00000000 --- a/docs/StoryResponseProject.md +++ /dev/null @@ -1,11 +0,0 @@ -# StoryResponseProject - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the project. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponseStory.md b/docs/StoryResponseStory.md deleted file mode 100644 index 845c75d4..00000000 --- a/docs/StoryResponseStory.md +++ /dev/null @@ -1,14 +0,0 @@ -# StoryResponseStory - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**created_by** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. | [optional] -**text** | **str** | *Create-only*. Human-readable text for the story or comment. This will not include the name of the creator. *Note: This is not guaranteed to be stable for a given type of story. For example, text for a reassignment may not always say “assigned to …” as the text for a story can both be edited and change based on the language settings of the user making the request.* Use the `resource_subtype` property to discover the action that created the story. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponseTag.md b/docs/StoryResponseTag.md deleted file mode 100644 index c3c6df43..00000000 --- a/docs/StoryResponseTag.md +++ /dev/null @@ -1,11 +0,0 @@ -# StoryResponseTag - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponseTarget.md b/docs/StoryResponseTarget.md deleted file mode 100644 index 1ee98bdf..00000000 --- a/docs/StoryResponseTarget.md +++ /dev/null @@ -1,13 +0,0 @@ -# StoryResponseTarget - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the task. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. | [optional] -**created_by** | [**AttachmentResponseParentCreatedBy**](AttachmentResponseParentCreatedBy.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/StoryResponseTask.md b/docs/StoryResponseTask.md deleted file mode 100644 index caee2c51..00000000 --- a/docs/StoryResponseTask.md +++ /dev/null @@ -1,13 +0,0 @@ -# StoryResponseTask - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the task. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. | [optional] -**created_by** | [**AttachmentResponseParentCreatedBy**](AttachmentResponseParentCreatedBy.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TagBase.md b/docs/TagBase.md deleted file mode 100644 index e00ba09e..00000000 --- a/docs/TagBase.md +++ /dev/null @@ -1,13 +0,0 @@ -# TagBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] -**color** | **str** | Color of the tag. | [optional] -**notes** | **str** | Free-form textual information associated with the tag (i.e. its description). | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TagCompact.md b/docs/TagCompact.md deleted file mode 100644 index 16bebfe8..00000000 --- a/docs/TagCompact.md +++ /dev/null @@ -1,11 +0,0 @@ -# TagCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TagCreateTagForWorkspaceRequest.md b/docs/TagCreateTagForWorkspaceRequest.md deleted file mode 100644 index db6f64c7..00000000 --- a/docs/TagCreateTagForWorkspaceRequest.md +++ /dev/null @@ -1,14 +0,0 @@ -# TagCreateTagForWorkspaceRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] -**color** | **str** | Color of the tag. | [optional] -**notes** | **str** | Free-form textual information associated with the tag (i.e. its description). | [optional] -**followers** | **list[str]** | An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TagRequest.md b/docs/TagRequest.md deleted file mode 100644 index 27737ac8..00000000 --- a/docs/TagRequest.md +++ /dev/null @@ -1,15 +0,0 @@ -# TagRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] -**color** | **str** | Color of the tag. | [optional] -**notes** | **str** | Free-form textual information associated with the tag (i.e. its description). | [optional] -**followers** | **list[str]** | An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. | [optional] -**workspace** | **str** | Gid of an object. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TagResponse.md b/docs/TagResponse.md deleted file mode 100644 index ad60eb5c..00000000 --- a/docs/TagResponse.md +++ /dev/null @@ -1,17 +0,0 @@ -# TagResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] -**color** | **str** | Color of the tag. | [optional] -**notes** | **str** | Free-form textual information associated with the tag (i.e. its description). | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**followers** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | Array of users following this tag. | [optional] -**workspace** | [**GoalResponseWorkspace**](GoalResponseWorkspace.md) | | [optional] -**permalink_url** | **str** | A url that points directly to the object within Asana. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TagResponseArray.md b/docs/TagResponseArray.md deleted file mode 100644 index fde8faae..00000000 --- a/docs/TagResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# TagResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[TagResponse]**](TagResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TagResponseData.md b/docs/TagResponseData.md deleted file mode 100644 index bc3dd988..00000000 --- a/docs/TagResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# TagResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TagResponse**](TagResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TagsApi.md b/docs/TagsApi.md deleted file mode 100644 index 9e7e799c..00000000 --- a/docs/TagsApi.md +++ /dev/null @@ -1,451 +0,0 @@ -# asana.TagsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_tag**](TagsApi.md#create_tag) | **POST** /tags | Create a tag -[**create_tag_for_workspace**](TagsApi.md#create_tag_for_workspace) | **POST** /workspaces/{workspace_gid}/tags | Create a tag in a workspace -[**delete_tag**](TagsApi.md#delete_tag) | **DELETE** /tags/{tag_gid} | Delete a tag -[**get_tag**](TagsApi.md#get_tag) | **GET** /tags/{tag_gid} | Get a tag -[**get_tags**](TagsApi.md#get_tags) | **GET** /tags | Get multiple tags -[**get_tags_for_task**](TagsApi.md#get_tags_for_task) | **GET** /tasks/{task_gid}/tags | Get a task's tags -[**get_tags_for_workspace**](TagsApi.md#get_tags_for_workspace) | **GET** /workspaces/{workspace_gid}/tags | Get tags in a workspace -[**update_tag**](TagsApi.md#update_tag) | **PUT** /tags/{tag_gid} | Update a tag - -# **create_tag** -> TagResponseData create_tag(body, opt_fields=opt_fields) - -Create a tag - -Creates a new tag in a workspace or organization. Every tag is required to be created in a specific workspace or organization, and this cannot be changed once set. Note that you can use the workspace parameter regardless of whether or not it is an organization. Returns the full record of the newly created tag. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TagsApi(api_client) -body = asana.TagsBody({"param1": "value1", "param2": "value2",}) # TagsBody | The tag to create. -opt_fields = ["color","created_at","followers","followers.name","name","notes","permalink_url","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a tag - api_response = api_instance.create_tag(body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TagsApi->create_tag: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TagsBody**](TagsBody.md)| The tag to create. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TagResponseData**](TagResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **create_tag_for_workspace** -> TagResponseData create_tag_for_workspace(body, workspace_gid, opt_fields=opt_fields) - -Create a tag in a workspace - -Creates a new tag in a workspace or organization. Every tag is required to be created in a specific workspace or organization, and this cannot be changed once set. Note that you can use the workspace parameter regardless of whether or not it is an organization. Returns the full record of the newly created tag. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TagsApi(api_client) -body = asana.WorkspaceGidTagsBody({"param1": "value1", "param2": "value2",}) # WorkspaceGidTagsBody | The tag to create. -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -opt_fields = ["color","created_at","followers","followers.name","name","notes","permalink_url","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a tag in a workspace - api_response = api_instance.create_tag_for_workspace(body, workspace_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TagsApi->create_tag_for_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**WorkspaceGidTagsBody**](WorkspaceGidTagsBody.md)| The tag to create. | - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TagResponseData**](TagResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_tag** -> EmptyResponseData delete_tag(tag_gid) - -Delete a tag - -A specific, existing tag can be deleted by making a DELETE request on the URL for that tag. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TagsApi(api_client) -tag_gid = '11235' # str | Globally unique identifier for the tag. - -try: - # Delete a tag - api_response = api_instance.delete_tag(tag_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TagsApi->delete_tag: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **tag_gid** | **str**| Globally unique identifier for the tag. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_tag** -> TagResponseData get_tag(tag_gid, opt_fields=opt_fields) - -Get a tag - -Returns the complete tag record for a single tag. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TagsApi(api_client) -tag_gid = '11235' # str | Globally unique identifier for the tag. -opt_fields = ["color","created_at","followers","followers.name","name","notes","permalink_url","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a tag - api_response = api_instance.get_tag(tag_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TagsApi->get_tag: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **tag_gid** | **str**| Globally unique identifier for the tag. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TagResponseData**](TagResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_tags** -> TagResponseArray get_tags(limit=limit, offset=offset, workspace=workspace, opt_fields=opt_fields) - -Get multiple tags - -Returns the compact tag records for some filtered set of tags. Use one or more of the parameters provided to filter the tags returned. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TagsApi(api_client) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -workspace = '1331' # str | The workspace to filter tags on. (optional) -opt_fields = ["color","created_at","followers","followers.name","name","notes","offset","path","permalink_url","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get multiple tags - api_response = api_instance.get_tags(limit=limit, offset=offset, workspace=workspace, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TagsApi->get_tags: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **workspace** | **str**| The workspace to filter tags on. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TagResponseArray**](TagResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_tags_for_task** -> TagResponseArray get_tags_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get a task's tags - -Get a compact representation of all of the tags the task has. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TagsApi(api_client) -task_gid = '321654' # str | The task to operate on. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["color","created_at","followers","followers.name","name","notes","offset","path","permalink_url","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a task's tags - api_response = api_instance.get_tags_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TagsApi->get_tags_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **task_gid** | **str**| The task to operate on. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TagResponseArray**](TagResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_tags_for_workspace** -> TagResponseArray get_tags_for_workspace(workspace_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get tags in a workspace - -Returns the compact tag records for some filtered set of tags. Use one or more of the parameters provided to filter the tags returned. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TagsApi(api_client) -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["color","created_at","followers","followers.name","name","notes","offset","path","permalink_url","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get tags in a workspace - api_response = api_instance.get_tags_for_workspace(workspace_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TagsApi->get_tags_for_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TagResponseArray**](TagResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_tag** -> TagResponseData update_tag(tag_gid, opt_fields=opt_fields) - -Update a tag - -Updates the properties of a tag. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the tag. Returns the complete updated tag record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TagsApi(api_client) -tag_gid = '11235' # str | Globally unique identifier for the tag. -opt_fields = ["color","created_at","followers","followers.name","name","notes","permalink_url","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a tag - api_response = api_instance.update_tag(tag_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TagsApi->update_tag: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **tag_gid** | **str**| Globally unique identifier for the tag. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TagResponseData**](TagResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/TagsApi.yaml b/docs/TagsApi.yaml deleted file mode 100644 index 799c3083..00000000 --- a/docs/TagsApi.yaml +++ /dev/null @@ -1,175 +0,0 @@ -TagsApi: - create_tag: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TagsApi(api_client) - body = asana.TagsBody({"param1": "value1", "param2": "value2",}) # TagsBody | The tag to create. - opt_fields = ["color","created_at","followers","followers.name","name","notes","permalink_url","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a tag - api_response = api_instance.create_tag(body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TagsApi->create_tag: %s\n" % e) - create_tag_for_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TagsApi(api_client) - body = asana.WorkspaceGidTagsBody({"param1": "value1", "param2": "value2",}) # WorkspaceGidTagsBody | The tag to create. - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - opt_fields = ["color","created_at","followers","followers.name","name","notes","permalink_url","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a tag in a workspace - api_response = api_instance.create_tag_for_workspace(body, workspace_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TagsApi->create_tag_for_workspace: %s\n" % e) - delete_tag: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TagsApi(api_client) - tag_gid = '11235' # str | Globally unique identifier for the tag. - - try: - # Delete a tag - api_response = api_instance.delete_tag(tag_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling TagsApi->delete_tag: %s\n" % e) - get_tag: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TagsApi(api_client) - tag_gid = '11235' # str | Globally unique identifier for the tag. - opt_fields = ["color","created_at","followers","followers.name","name","notes","permalink_url","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a tag - api_response = api_instance.get_tag(tag_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TagsApi->get_tag: %s\n" % e) - get_tags: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TagsApi(api_client) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - workspace = '1331' # str | The workspace to filter tags on. (optional) - opt_fields = ["color","created_at","followers","followers.name","name","notes","offset","path","permalink_url","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get multiple tags - api_response = api_instance.get_tags(limit=limit, offset=offset, workspace=workspace, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TagsApi->get_tags: %s\n" % e) - get_tags_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TagsApi(api_client) - task_gid = '321654' # str | The task to operate on. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["color","created_at","followers","followers.name","name","notes","offset","path","permalink_url","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a task's tags - api_response = api_instance.get_tags_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TagsApi->get_tags_for_task: %s\n" % e) - get_tags_for_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TagsApi(api_client) - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["color","created_at","followers","followers.name","name","notes","offset","path","permalink_url","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get tags in a workspace - api_response = api_instance.get_tags_for_workspace(workspace_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TagsApi->get_tags_for_workspace: %s\n" % e) - update_tag: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TagsApi(api_client) - tag_gid = '11235' # str | Globally unique identifier for the tag. - opt_fields = ["color","created_at","followers","followers.name","name","notes","permalink_url","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a tag - api_response = api_instance.update_tag(tag_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TagsApi->update_tag: %s\n" % e) diff --git a/docs/TagsBody.md b/docs/TagsBody.md deleted file mode 100644 index 869da682..00000000 --- a/docs/TagsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TagsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TagRequest**](TagRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskAddFollowersRequest.md b/docs/TaskAddFollowersRequest.md deleted file mode 100644 index 645fea7a..00000000 --- a/docs/TaskAddFollowersRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskAddFollowersRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**followers** | **list[str]** | An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskAddProjectRequest.md b/docs/TaskAddProjectRequest.md deleted file mode 100644 index 7c74d70d..00000000 --- a/docs/TaskAddProjectRequest.md +++ /dev/null @@ -1,12 +0,0 @@ -# TaskAddProjectRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**project** | **str** | The project to add the task to. | -**insert_after** | **str** | A task in the project to insert the task after, or `null` to insert at the beginning of the list. | [optional] -**insert_before** | **str** | A task in the project to insert the task before, or `null` to insert at the end of the list. | [optional] -**section** | **str** | A section in the project to insert the task into. The task will be inserted at the bottom of the section. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskAddTagRequest.md b/docs/TaskAddTagRequest.md deleted file mode 100644 index c32ec0b3..00000000 --- a/docs/TaskAddTagRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskAddTagRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**tag** | **str** | The tag to add to the task. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskBase.md b/docs/TaskBase.md deleted file mode 100644 index 8a899817..00000000 --- a/docs/TaskBase.md +++ /dev/null @@ -1,39 +0,0 @@ -# TaskBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the task. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. | [optional] -**created_by** | [**AttachmentResponseParentCreatedBy**](AttachmentResponseParentCreatedBy.md) | | [optional] -**approval_status** | **str** | *Conditional* Reflects the approval status of this task. This field is kept in sync with `completed`, meaning `pending` translates to false while `approved`, `rejected`, and `changes_requested` translate to true. If you set completed to true, this field will be set to `approved`. | [optional] -**assignee_status** | **str** | *Deprecated* Scheduling status of this task for the user it is assigned to. This field can only be set if the assignee is non-null. Setting this field to \"inbox\" or \"upcoming\" inserts it at the top of the section, while the other options will insert at the bottom. | [optional] -**completed** | **bool** | True if the task is currently marked complete, false if not. | [optional] -**completed_at** | **datetime** | The time at which this task was completed, or null if the task is incomplete. | [optional] -**completed_by** | [**TaskBaseCompletedBy**](TaskBaseCompletedBy.md) | | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**dependencies** | [**list[TaskBaseDependencies]**](TaskBaseDependencies.md) | [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that this task depends on. The objects contain only the gid of the dependency. | [optional] -**dependents** | [**list[TaskBaseDependencies]**](TaskBaseDependencies.md) | [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that depend on this task. The objects contain only the ID of the dependent. | [optional] -**due_at** | **datetime** | The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. | [optional] -**due_on** | **date** | The localized date on which this task is due, or null if the task has no due date. This takes a date with `YYYY-MM-DD` format and should not be used together with `due_at`. | [optional] -**external** | [**TaskBaseExternal**](TaskBaseExternal.md) | | [optional] -**html_notes** | **str** | [Opt In](/docs/inputoutput-options). The notes of the text with formatting as HTML. | [optional] -**hearted** | **bool** | *Deprecated - please use liked instead* True if the task is hearted by the authorized user, false if not. | [optional] -**hearts** | [**list[GoalResponseLikes]**](GoalResponseLikes.md) | *Deprecated - please use likes instead* Array of likes for users who have hearted this task. | [optional] -**is_rendered_as_separator** | **bool** | [Opt In](/docs/inputoutput-options). In some contexts tasks can be rendered as a visual separator; for instance, subtasks can appear similar to [sections](/reference/sections) without being true `section` objects. If a `task` object is rendered this way in any context it will have the property `is_rendered_as_separator` set to `true`. | [optional] -**liked** | **bool** | True if the task is liked by the authorized user, false if not. | [optional] -**likes** | [**list[GoalResponseLikes]**](GoalResponseLikes.md) | Array of likes for users who have liked this task. | [optional] -**memberships** | [**list[TaskBaseMemberships]**](TaskBaseMemberships.md) | *Create-only*. Array of projects this task is associated with and the section it is in. At task creation time, this array can be used to add the task to specific sections. After task creation, these associations can be modified using the `addProject` and `removeProject` endpoints. Note that over time, more types of memberships may be added to this property. | [optional] -**modified_at** | **datetime** | The time at which this task was last modified. The following conditions will change `modified_at`: - story is created on a task - story is trashed on a task - attachment is trashed on a task - task is assigned or unassigned - custom field value is changed - the task itself is trashed - Or if any of the following fields are updated: - completed - name - due_date - description - attachments - items - schedule_status The following conditions will _not_ change `modified_at`: - moving to a new container (project, portfolio, etc) - comments being added to the task (but the stories they generate _will_ affect `modified_at`) | [optional] -**notes** | **str** | Free-form textual information associated with the task (i.e. its description). | [optional] -**num_hearts** | **int** | *Deprecated - please use likes instead* The number of users who have hearted this task. | [optional] -**num_likes** | **int** | The number of users who have liked this task. | [optional] -**num_subtasks** | **int** | [Opt In](/docs/inputoutput-options). The number of subtasks on this task. | [optional] -**start_at** | **datetime** | Date and time on which work begins for the task, or null if the task has no start time. This takes an ISO 8601 date string in UTC and should not be used together with `start_on`. *Note: `due_at` must be present in the request when setting or unsetting the `start_at` parameter.* | [optional] -**start_on** | **date** | The day on which work begins for the task , or null if the task has no start date. This takes a date with `YYYY-MM-DD` format and should not be used together with `start_at`. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter.* | [optional] -**actual_time_minutes** | **float** | This value represents the sum of all the Time Tracking entries in the Actual Time field on a given Task. It is represented as a nullable long value. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskBaseCompletedBy.md b/docs/TaskBaseCompletedBy.md deleted file mode 100644 index 3c081f14..00000000 --- a/docs/TaskBaseCompletedBy.md +++ /dev/null @@ -1,11 +0,0 @@ -# TaskBaseCompletedBy - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | *Read-only except when same user as requester*. The user’s name. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskBaseDependencies.md b/docs/TaskBaseDependencies.md deleted file mode 100644 index 532775f1..00000000 --- a/docs/TaskBaseDependencies.md +++ /dev/null @@ -1,10 +0,0 @@ -# TaskBaseDependencies - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskBaseExternal.md b/docs/TaskBaseExternal.md deleted file mode 100644 index 2c8297e0..00000000 --- a/docs/TaskBaseExternal.md +++ /dev/null @@ -1,10 +0,0 @@ -# TaskBaseExternal - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | | [optional] -**data** | **str** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskBaseMemberships.md b/docs/TaskBaseMemberships.md deleted file mode 100644 index 32efcb24..00000000 --- a/docs/TaskBaseMemberships.md +++ /dev/null @@ -1,10 +0,0 @@ -# TaskBaseMemberships - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**project** | [**JobBaseNewProject**](JobBaseNewProject.md) | | [optional] -**section** | [**TaskBaseSection**](TaskBaseSection.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskBaseSection.md b/docs/TaskBaseSection.md deleted file mode 100644 index 64c0de13..00000000 --- a/docs/TaskBaseSection.md +++ /dev/null @@ -1,11 +0,0 @@ -# TaskBaseSection - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the section (i.e. the text displayed as the section header). | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskCompact.md b/docs/TaskCompact.md deleted file mode 100644 index a3bd42cc..00000000 --- a/docs/TaskCompact.md +++ /dev/null @@ -1,13 +0,0 @@ -# TaskCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the task. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. | [optional] -**created_by** | [**AttachmentResponseParentCreatedBy**](AttachmentResponseParentCreatedBy.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskCountResponse.md b/docs/TaskCountResponse.md deleted file mode 100644 index 9f89e392..00000000 --- a/docs/TaskCountResponse.md +++ /dev/null @@ -1,14 +0,0 @@ -# TaskCountResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**num_tasks** | **int** | The number of tasks in a project. | [optional] -**num_incomplete_tasks** | **int** | The number of incomplete tasks in a project. | [optional] -**num_completed_tasks** | **int** | The number of completed tasks in a project. | [optional] -**num_milestones** | **int** | The number of milestones in a project. | [optional] -**num_incomplete_milestones** | **int** | The number of incomplete milestones in a project. | [optional] -**num_completed_milestones** | **int** | The number of completed milestones in a project. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskCountResponseData.md b/docs/TaskCountResponseData.md deleted file mode 100644 index 9f40d9ce..00000000 --- a/docs/TaskCountResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskCountResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskCountResponse**](TaskCountResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskDuplicateRequest.md b/docs/TaskDuplicateRequest.md deleted file mode 100644 index 61aa147e..00000000 --- a/docs/TaskDuplicateRequest.md +++ /dev/null @@ -1,10 +0,0 @@ -# TaskDuplicateRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **str** | The name of the new task. | [optional] -**include** | **str** | A comma-separated list of fields that will be duplicated to the new task. ##### Fields - assignee - attachments - dates - dependencies - followers - notes - parent - projects - subtasks - tags | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidAddDependenciesBody.md b/docs/TaskGidAddDependenciesBody.md deleted file mode 100644 index ec796d82..00000000 --- a/docs/TaskGidAddDependenciesBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidAddDependenciesBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ModifyDependenciesRequest**](ModifyDependenciesRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidAddDependentsBody.md b/docs/TaskGidAddDependentsBody.md deleted file mode 100644 index e62849c9..00000000 --- a/docs/TaskGidAddDependentsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidAddDependentsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ModifyDependentsRequest**](ModifyDependentsRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidAddFollowersBody.md b/docs/TaskGidAddFollowersBody.md deleted file mode 100644 index a530d8ee..00000000 --- a/docs/TaskGidAddFollowersBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidAddFollowersBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskAddFollowersRequest**](TaskAddFollowersRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidAddProjectBody.md b/docs/TaskGidAddProjectBody.md deleted file mode 100644 index 4a33205d..00000000 --- a/docs/TaskGidAddProjectBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidAddProjectBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskAddProjectRequest**](TaskAddProjectRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidAddTagBody.md b/docs/TaskGidAddTagBody.md deleted file mode 100644 index 06497ceb..00000000 --- a/docs/TaskGidAddTagBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidAddTagBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskAddTagRequest**](TaskAddTagRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidDuplicateBody.md b/docs/TaskGidDuplicateBody.md deleted file mode 100644 index fa77c0bf..00000000 --- a/docs/TaskGidDuplicateBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidDuplicateBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskDuplicateRequest**](TaskDuplicateRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidRemoveDependenciesBody.md b/docs/TaskGidRemoveDependenciesBody.md deleted file mode 100644 index 1e1c9ff4..00000000 --- a/docs/TaskGidRemoveDependenciesBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidRemoveDependenciesBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ModifyDependenciesRequest**](ModifyDependenciesRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidRemoveDependentsBody.md b/docs/TaskGidRemoveDependentsBody.md deleted file mode 100644 index 5de9c71c..00000000 --- a/docs/TaskGidRemoveDependentsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidRemoveDependentsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ModifyDependentsRequest**](ModifyDependentsRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidRemoveFollowersBody.md b/docs/TaskGidRemoveFollowersBody.md deleted file mode 100644 index f4243af5..00000000 --- a/docs/TaskGidRemoveFollowersBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidRemoveFollowersBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskRemoveFollowersRequest**](TaskRemoveFollowersRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidRemoveProjectBody.md b/docs/TaskGidRemoveProjectBody.md deleted file mode 100644 index aa6e751b..00000000 --- a/docs/TaskGidRemoveProjectBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidRemoveProjectBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskRemoveProjectRequest**](TaskRemoveProjectRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidRemoveTagBody.md b/docs/TaskGidRemoveTagBody.md deleted file mode 100644 index 75767236..00000000 --- a/docs/TaskGidRemoveTagBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidRemoveTagBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskRemoveTagRequest**](TaskRemoveTagRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidSetParentBody.md b/docs/TaskGidSetParentBody.md deleted file mode 100644 index 9b0b6048..00000000 --- a/docs/TaskGidSetParentBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidSetParentBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskSetParentRequest**](TaskSetParentRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidStoriesBody.md b/docs/TaskGidStoriesBody.md deleted file mode 100644 index 4a96e991..00000000 --- a/docs/TaskGidStoriesBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidStoriesBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**StoryRequest**](StoryRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidSubtasksBody.md b/docs/TaskGidSubtasksBody.md deleted file mode 100644 index 9cc9107d..00000000 --- a/docs/TaskGidSubtasksBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidSubtasksBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskRequest**](TaskRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskGidTimeTrackingEntriesBody.md b/docs/TaskGidTimeTrackingEntriesBody.md deleted file mode 100644 index 0f6f2109..00000000 --- a/docs/TaskGidTimeTrackingEntriesBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskGidTimeTrackingEntriesBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**CreateTimeTrackingEntryRequest**](CreateTimeTrackingEntryRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskRemoveFollowersRequest.md b/docs/TaskRemoveFollowersRequest.md deleted file mode 100644 index 53c41760..00000000 --- a/docs/TaskRemoveFollowersRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskRemoveFollowersRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**followers** | **list[str]** | An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskRemoveProjectRequest.md b/docs/TaskRemoveProjectRequest.md deleted file mode 100644 index 1907eddd..00000000 --- a/docs/TaskRemoveProjectRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskRemoveProjectRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**project** | **str** | The project to remove the task from. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskRemoveTagRequest.md b/docs/TaskRemoveTagRequest.md deleted file mode 100644 index 8f66b29d..00000000 --- a/docs/TaskRemoveTagRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskRemoveTagRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**tag** | **str** | The tag to remove from the task. | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskRequest.md b/docs/TaskRequest.md deleted file mode 100644 index d85765ad..00000000 --- a/docs/TaskRequest.md +++ /dev/null @@ -1,47 +0,0 @@ -# TaskRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the task. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. | [optional] -**created_by** | [**AttachmentResponseParentCreatedBy**](AttachmentResponseParentCreatedBy.md) | | [optional] -**approval_status** | **str** | *Conditional* Reflects the approval status of this task. This field is kept in sync with `completed`, meaning `pending` translates to false while `approved`, `rejected`, and `changes_requested` translate to true. If you set completed to true, this field will be set to `approved`. | [optional] -**assignee_status** | **str** | *Deprecated* Scheduling status of this task for the user it is assigned to. This field can only be set if the assignee is non-null. Setting this field to \"inbox\" or \"upcoming\" inserts it at the top of the section, while the other options will insert at the bottom. | [optional] -**completed** | **bool** | True if the task is currently marked complete, false if not. | [optional] -**completed_at** | **datetime** | The time at which this task was completed, or null if the task is incomplete. | [optional] -**completed_by** | [**TaskBaseCompletedBy**](TaskBaseCompletedBy.md) | | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**dependencies** | [**list[TaskBaseDependencies]**](TaskBaseDependencies.md) | [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that this task depends on. The objects contain only the gid of the dependency. | [optional] -**dependents** | [**list[TaskBaseDependencies]**](TaskBaseDependencies.md) | [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that depend on this task. The objects contain only the ID of the dependent. | [optional] -**due_at** | **datetime** | The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. | [optional] -**due_on** | **date** | The localized date on which this task is due, or null if the task has no due date. This takes a date with `YYYY-MM-DD` format and should not be used together with `due_at`. | [optional] -**external** | [**TaskBaseExternal**](TaskBaseExternal.md) | | [optional] -**html_notes** | **str** | [Opt In](/docs/inputoutput-options). The notes of the text with formatting as HTML. | [optional] -**hearted** | **bool** | *Deprecated - please use liked instead* True if the task is hearted by the authorized user, false if not. | [optional] -**hearts** | [**list[GoalResponseLikes]**](GoalResponseLikes.md) | *Deprecated - please use likes instead* Array of likes for users who have hearted this task. | [optional] -**is_rendered_as_separator** | **bool** | [Opt In](/docs/inputoutput-options). In some contexts tasks can be rendered as a visual separator; for instance, subtasks can appear similar to [sections](/reference/sections) without being true `section` objects. If a `task` object is rendered this way in any context it will have the property `is_rendered_as_separator` set to `true`. | [optional] -**liked** | **bool** | True if the task is liked by the authorized user, false if not. | [optional] -**likes** | [**list[GoalResponseLikes]**](GoalResponseLikes.md) | Array of likes for users who have liked this task. | [optional] -**memberships** | [**list[TaskBaseMemberships]**](TaskBaseMemberships.md) | *Create-only*. Array of projects this task is associated with and the section it is in. At task creation time, this array can be used to add the task to specific sections. After task creation, these associations can be modified using the `addProject` and `removeProject` endpoints. Note that over time, more types of memberships may be added to this property. | [optional] -**modified_at** | **datetime** | The time at which this task was last modified. The following conditions will change `modified_at`: - story is created on a task - story is trashed on a task - attachment is trashed on a task - task is assigned or unassigned - custom field value is changed - the task itself is trashed - Or if any of the following fields are updated: - completed - name - due_date - description - attachments - items - schedule_status The following conditions will _not_ change `modified_at`: - moving to a new container (project, portfolio, etc) - comments being added to the task (but the stories they generate _will_ affect `modified_at`) | [optional] -**notes** | **str** | Free-form textual information associated with the task (i.e. its description). | [optional] -**num_hearts** | **int** | *Deprecated - please use likes instead* The number of users who have hearted this task. | [optional] -**num_likes** | **int** | The number of users who have liked this task. | [optional] -**num_subtasks** | **int** | [Opt In](/docs/inputoutput-options). The number of subtasks on this task. | [optional] -**start_at** | **datetime** | Date and time on which work begins for the task, or null if the task has no start time. This takes an ISO 8601 date string in UTC and should not be used together with `start_on`. *Note: `due_at` must be present in the request when setting or unsetting the `start_at` parameter.* | [optional] -**start_on** | **date** | The day on which work begins for the task , or null if the task has no start date. This takes a date with `YYYY-MM-DD` format and should not be used together with `start_at`. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter.* | [optional] -**actual_time_minutes** | **float** | This value represents the sum of all the Time Tracking entries in the Actual Time field on a given Task. It is represented as a nullable long value. | [optional] -**assignee** | **str** | Gid of a user. | [optional] -**assignee_section** | **str** | The *assignee section* is a subdivision of a project that groups tasks together in the assignee's \"My Tasks\" list. It can either be a header above a list of tasks in a list view or a column in a board view of \"My Tasks.\" The `assignee_section` property will be returned in the response only if the request was sent by the user who is the assignee of the task. Note that you can only write to `assignee_section` with the gid of an existing section visible in the user's \"My Tasks\" list. | [optional] -**custom_fields** | **dict(str, str)** | An object where each key is the GID of a custom field and its corresponding value is either an enum GID, string, number, object, or array (depending on the custom field type). See the [custom fields guide](/docs/custom-fields-guide) for details on creating and updating custom field values. | [optional] -**followers** | **list[str]** | *Create-Only* An array of strings identifying users. These can either be the string \"me\", an email, or the gid of a user. In order to change followers on an existing task use `addFollowers` and `removeFollowers`. | [optional] -**parent** | **str** | Gid of a task. | [optional] -**projects** | **list[str]** | *Create-Only* Array of project gids. In order to change projects on an existing task use `addProject` and `removeProject`. | [optional] -**tags** | **list[str]** | *Create-Only* Array of tag gids. In order to change tags on an existing task use `addTag` and `removeTag`. | [optional] -**workspace** | **str** | Gid of a workspace. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskResponse.md b/docs/TaskResponse.md deleted file mode 100644 index d7c0bfae..00000000 --- a/docs/TaskResponse.md +++ /dev/null @@ -1,48 +0,0 @@ -# TaskResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the task. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. | [optional] -**created_by** | [**AttachmentResponseParentCreatedBy**](AttachmentResponseParentCreatedBy.md) | | [optional] -**approval_status** | **str** | *Conditional* Reflects the approval status of this task. This field is kept in sync with `completed`, meaning `pending` translates to false while `approved`, `rejected`, and `changes_requested` translate to true. If you set completed to true, this field will be set to `approved`. | [optional] -**assignee_status** | **str** | *Deprecated* Scheduling status of this task for the user it is assigned to. This field can only be set if the assignee is non-null. Setting this field to \"inbox\" or \"upcoming\" inserts it at the top of the section, while the other options will insert at the bottom. | [optional] -**completed** | **bool** | True if the task is currently marked complete, false if not. | [optional] -**completed_at** | **datetime** | The time at which this task was completed, or null if the task is incomplete. | [optional] -**completed_by** | [**TaskBaseCompletedBy**](TaskBaseCompletedBy.md) | | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**dependencies** | [**list[TaskBaseDependencies]**](TaskBaseDependencies.md) | [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that this task depends on. The objects contain only the gid of the dependency. | [optional] -**dependents** | [**list[TaskBaseDependencies]**](TaskBaseDependencies.md) | [Opt In](/docs/inputoutput-options). Array of resources referencing tasks that depend on this task. The objects contain only the ID of the dependent. | [optional] -**due_at** | **datetime** | The UTC date and time on which this task is due, or null if the task has no due time. This takes an ISO 8601 date string in UTC and should not be used together with `due_on`. | [optional] -**due_on** | **date** | The localized date on which this task is due, or null if the task has no due date. This takes a date with `YYYY-MM-DD` format and should not be used together with `due_at`. | [optional] -**external** | [**TaskBaseExternal**](TaskBaseExternal.md) | | [optional] -**html_notes** | **str** | [Opt In](/docs/inputoutput-options). The notes of the text with formatting as HTML. | [optional] -**hearted** | **bool** | *Deprecated - please use liked instead* True if the task is hearted by the authorized user, false if not. | [optional] -**hearts** | [**list[GoalResponseLikes]**](GoalResponseLikes.md) | *Deprecated - please use likes instead* Array of likes for users who have hearted this task. | [optional] -**is_rendered_as_separator** | **bool** | [Opt In](/docs/inputoutput-options). In some contexts tasks can be rendered as a visual separator; for instance, subtasks can appear similar to [sections](/reference/sections) without being true `section` objects. If a `task` object is rendered this way in any context it will have the property `is_rendered_as_separator` set to `true`. | [optional] -**liked** | **bool** | True if the task is liked by the authorized user, false if not. | [optional] -**likes** | [**list[GoalResponseLikes]**](GoalResponseLikes.md) | Array of likes for users who have liked this task. | [optional] -**memberships** | [**list[TaskBaseMemberships]**](TaskBaseMemberships.md) | *Create-only*. Array of projects this task is associated with and the section it is in. At task creation time, this array can be used to add the task to specific sections. After task creation, these associations can be modified using the `addProject` and `removeProject` endpoints. Note that over time, more types of memberships may be added to this property. | [optional] -**modified_at** | **datetime** | The time at which this task was last modified. The following conditions will change `modified_at`: - story is created on a task - story is trashed on a task - attachment is trashed on a task - task is assigned or unassigned - custom field value is changed - the task itself is trashed - Or if any of the following fields are updated: - completed - name - due_date - description - attachments - items - schedule_status The following conditions will _not_ change `modified_at`: - moving to a new container (project, portfolio, etc) - comments being added to the task (but the stories they generate _will_ affect `modified_at`) | [optional] -**notes** | **str** | Free-form textual information associated with the task (i.e. its description). | [optional] -**num_hearts** | **int** | *Deprecated - please use likes instead* The number of users who have hearted this task. | [optional] -**num_likes** | **int** | The number of users who have liked this task. | [optional] -**num_subtasks** | **int** | [Opt In](/docs/inputoutput-options). The number of subtasks on this task. | [optional] -**start_at** | **datetime** | Date and time on which work begins for the task, or null if the task has no start time. This takes an ISO 8601 date string in UTC and should not be used together with `start_on`. *Note: `due_at` must be present in the request when setting or unsetting the `start_at` parameter.* | [optional] -**start_on** | **date** | The day on which work begins for the task , or null if the task has no start date. This takes a date with `YYYY-MM-DD` format and should not be used together with `start_at`. *Note: `due_on` or `due_at` must be present in the request when setting or unsetting the `start_on` parameter.* | [optional] -**actual_time_minutes** | **float** | This value represents the sum of all the Time Tracking entries in the Actual Time field on a given Task. It is represented as a nullable long value. | [optional] -**assignee** | [**CustomFieldResponseCreatedBy**](CustomFieldResponseCreatedBy.md) | | [optional] -**assignee_section** | [**TaskResponseAssigneeSection**](TaskResponseAssigneeSection.md) | | [optional] -**custom_fields** | [**list[TaskResponseCustomFields]**](TaskResponseCustomFields.md) | Array of custom field values applied to the task. These represent the custom field values recorded on this project for a particular custom field. For example, these custom field values will contain an `enum_value` property for custom fields of type `enum`, a `text_value` property for custom fields of type `text`, and so on. Please note that the `gid` returned on each custom field value *is identical* to the `gid` of the custom field, which allows referencing the custom field metadata through the `/custom_fields/custom_field-gid` endpoint. | [optional] -**followers** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | Array of users following this task. | [optional] -**parent** | [**TaskResponseParent**](TaskResponseParent.md) | | [optional] -**projects** | [**list[JobBaseNewProject]**](JobBaseNewProject.md) | *Create-only.* Array of projects this task is associated with. At task creation time, this array can be used to add the task to many projects at once. After task creation, these associations can be modified using the addProject and removeProject endpoints. | [optional] -**tags** | [**list[TaskResponseTags]**](TaskResponseTags.md) | Array of tags associated with this task. In order to change tags on an existing task use `addTag` and `removeTag`. | [optional] -**workspace** | [**TaskResponseWorkspace**](TaskResponseWorkspace.md) | | [optional] -**permalink_url** | **str** | A url that points directly to the object within Asana. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskResponseArray.md b/docs/TaskResponseArray.md deleted file mode 100644 index 7118d3d0..00000000 --- a/docs/TaskResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# TaskResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[TaskResponse]**](TaskResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskResponseAssigneeSection.md b/docs/TaskResponseAssigneeSection.md deleted file mode 100644 index f1d81a67..00000000 --- a/docs/TaskResponseAssigneeSection.md +++ /dev/null @@ -1,11 +0,0 @@ -# TaskResponseAssigneeSection - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the section (i.e. the text displayed as the section header). | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskResponseCustomFields.md b/docs/TaskResponseCustomFields.md deleted file mode 100644 index c6e292be..00000000 --- a/docs/TaskResponseCustomFields.md +++ /dev/null @@ -1,34 +0,0 @@ -# TaskResponseCustomFields - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the custom field. | [optional] -**resource_subtype** | **str** | The type of the custom field. Must be one of the given values. | [optional] -**type** | **str** | *Deprecated: new integrations should prefer the resource_subtype field.* The type of the custom field. Must be one of the given values. | [optional] -**enum_options** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `enum`. This array specifies the possible values which an `enum` custom field can adopt. To modify the enum options, refer to [working with enum options](/reference/createenumoptionforcustomfield). | [optional] -**enabled** | **bool** | *Conditional*. Determines if the custom field is enabled or not. | [optional] -**is_formula_field** | **bool** | *Conditional*. This flag describes whether a custom field is a formula custom field. | [optional] -**date_value** | [**CustomFieldBaseDateValue**](CustomFieldBaseDateValue.md) | | [optional] -**enum_value** | [**CustomFieldBaseEnumValue**](CustomFieldBaseEnumValue.md) | | [optional] -**multi_enum_values** | [**list[CustomFieldBaseEnumOptions]**](CustomFieldBaseEnumOptions.md) | *Conditional*. Only relevant for custom fields of type `multi_enum`. This object is the chosen values of a `multi_enum` custom field. | [optional] -**number_value** | **float** | *Conditional*. This number is the value of a `number` custom field. | [optional] -**text_value** | **str** | *Conditional*. This string is the value of a `text` custom field. | [optional] -**display_value** | **str** | A string representation for the value of the custom field. Integrations that don't require the underlying type should use this field to read values. Using this field will future-proof an app against new custom field types. | [optional] -**description** | **str** | [Opt In](/docs/inputoutput-options). The description of the custom field. | [optional] -**precision** | **int** | Only relevant for custom fields of type ‘Number’. This field dictates the number of places after the decimal to round to, i.e. 0 is integer values, 1 rounds to the nearest tenth, and so on. Must be between 0 and 6, inclusive. For percentage format, this may be unintuitive, as a value of 0.25 has a precision of 0, while a value of 0.251 has a precision of 1. This is due to 0.25 being displayed as 25%. The identifier format will always have a precision of 0. | [optional] -**format** | **str** | The format of this custom field. | [optional] -**currency_code** | **str** | ISO 4217 currency code to format this custom field. This will be null if the `format` is not `currency`. | [optional] -**custom_label** | **str** | This is the string that appears next to the custom field value. This will be null if the `format` is not `custom`. | [optional] -**custom_label_position** | **str** | Only relevant for custom fields with `custom` format. This depicts where to place the custom label. This will be null if the `format` is not `custom`. | [optional] -**is_global_to_workspace** | **bool** | This flag describes whether this custom field is available to every container in the workspace. Before project-specific custom fields, this field was always true. | [optional] -**has_notifications_enabled** | **bool** | *Conditional*. This flag describes whether a follower of a task with this field should receive inbox notifications from changes to this field. | [optional] -**asana_created_field** | **str** | *Conditional*. A unique identifier to associate this field with the template source of truth. | [optional] -**is_value_read_only** | **bool** | *Conditional*. This flag describes whether a custom field is read only. | [optional] -**created_by** | [**CustomFieldResponseCreatedBy**](CustomFieldResponseCreatedBy.md) | | [optional] -**people_value** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | *Conditional*. Only relevant for custom fields of type `people`. This array of [compact user](/reference/users) objects reflects the values of a `people` custom field. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskResponseData.md b/docs/TaskResponseData.md deleted file mode 100644 index e92012a9..00000000 --- a/docs/TaskResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskResponse**](TaskResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskResponseParent.md b/docs/TaskResponseParent.md deleted file mode 100644 index 393b0cea..00000000 --- a/docs/TaskResponseParent.md +++ /dev/null @@ -1,13 +0,0 @@ -# TaskResponseParent - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the task. | [optional] -**resource_subtype** | **str** | The subtype of this resource. Different subtypes retain many of the same fields and behavior, but may render differently in Asana or represent resources with different semantic meaning. The resource_subtype `milestone` represent a single moment in time. This means tasks with this subtype cannot have a start_date. | [optional] -**created_by** | [**AttachmentResponseParentCreatedBy**](AttachmentResponseParentCreatedBy.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskResponseTags.md b/docs/TaskResponseTags.md deleted file mode 100644 index ef898c40..00000000 --- a/docs/TaskResponseTags.md +++ /dev/null @@ -1,11 +0,0 @@ -# TaskResponseTags - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the tag. This is generally a short sentence fragment that fits on a line in the UI for maximum readability. However, it can be longer. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskResponseWorkspace.md b/docs/TaskResponseWorkspace.md deleted file mode 100644 index 4b0ecb26..00000000 --- a/docs/TaskResponseWorkspace.md +++ /dev/null @@ -1,11 +0,0 @@ -# TaskResponseWorkspace - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the workspace. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskSetParentRequest.md b/docs/TaskSetParentRequest.md deleted file mode 100644 index 11aad6eb..00000000 --- a/docs/TaskSetParentRequest.md +++ /dev/null @@ -1,11 +0,0 @@ -# TaskSetParentRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**parent** | **str** | The new parent of the task, or `null` for no parent. | -**insert_after** | **str** | A subtask of the parent to insert the task after, or `null` to insert at the beginning of the list. | [optional] -**insert_before** | **str** | A subtask of the parent to insert the task before, or `null` to insert at the end of the list. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskTemplateBase.md b/docs/TaskTemplateBase.md deleted file mode 100644 index 39adb3ef..00000000 --- a/docs/TaskTemplateBase.md +++ /dev/null @@ -1,11 +0,0 @@ -# TaskTemplateBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the task template. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskTemplateCompact.md b/docs/TaskTemplateCompact.md deleted file mode 100644 index 138c254c..00000000 --- a/docs/TaskTemplateCompact.md +++ /dev/null @@ -1,11 +0,0 @@ -# TaskTemplateCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the task template. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskTemplateGidInstantiateTaskBody.md b/docs/TaskTemplateGidInstantiateTaskBody.md deleted file mode 100644 index aa3f5436..00000000 --- a/docs/TaskTemplateGidInstantiateTaskBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskTemplateGidInstantiateTaskBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskTemplateInstantiateTaskRequest**](TaskTemplateInstantiateTaskRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskTemplateInstantiateTaskRequest.md b/docs/TaskTemplateInstantiateTaskRequest.md deleted file mode 100644 index a721e6ff..00000000 --- a/docs/TaskTemplateInstantiateTaskRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskTemplateInstantiateTaskRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **str** | The name of the new task. If not provided, the name of the task template will be used. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskTemplateRecipe.md b/docs/TaskTemplateRecipe.md deleted file mode 100644 index 3b88c753..00000000 --- a/docs/TaskTemplateRecipe.md +++ /dev/null @@ -1,22 +0,0 @@ -# TaskTemplateRecipe - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **str** | Name of the task that will be created from this template. | [optional] -**task_resource_subtype** | **str** | The subtype of the task that will be created from this template. | [optional] -**description** | **str** | Description of the task that will be created from this template. | [optional] -**html_description** | **str** | HTML description of the task that will be created from this template. | [optional] -**memberships** | [**list[JobBaseNewProject]**](JobBaseNewProject.md) | Array of projects that the task created from this template will be added to | [optional] -**relative_start_on** | **int** | The number of days after the task has been instantiated on which that the task will start | [optional] -**relative_due_on** | **int** | The number of days after the task has been instantiated on which that the task will be due | [optional] -**due_time** | **str** | The time of day that the task will be due | [optional] -**dependencies** | [**list[TaskTemplateRecipeDependencies]**](TaskTemplateRecipeDependencies.md) | Array of task templates that the task created from this template will depend on | [optional] -**dependents** | [**list[TaskTemplateRecipeDependencies]**](TaskTemplateRecipeDependencies.md) | Array of task templates that will depend on the task created from this template | [optional] -**followers** | [**list[CustomFieldResponsePeopleValue]**](CustomFieldResponsePeopleValue.md) | Array of users that will be added as followers to the task created from this template | [optional] -**attachments** | [**list[TaskTemplateRecipeAttachments]**](TaskTemplateRecipeAttachments.md) | Array of attachments that will be added to the task created from this template | [optional] -**subtasks** | [**list[TaskTemplateRecipeDependencies]**](TaskTemplateRecipeDependencies.md) | Array of subtasks that will be added to the task created from this template | [optional] -**custom_fields** | [**list[PortfolioResponseCustomFields]**](PortfolioResponseCustomFields.md) | Array of custom fields that will be added to the task created from this template | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskTemplateRecipeAttachments.md b/docs/TaskTemplateRecipeAttachments.md deleted file mode 100644 index f1879ad0..00000000 --- a/docs/TaskTemplateRecipeAttachments.md +++ /dev/null @@ -1,12 +0,0 @@ -# TaskTemplateRecipeAttachments - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the file. | [optional] -**resource_subtype** | **str** | The service hosting the attachment. Valid values are `asana`, `dropbox`, `gdrive`, `onedrive`, `box`, `vimeo`, and `external`. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskTemplateRecipeCompact.md b/docs/TaskTemplateRecipeCompact.md deleted file mode 100644 index c29f4b00..00000000 --- a/docs/TaskTemplateRecipeCompact.md +++ /dev/null @@ -1,10 +0,0 @@ -# TaskTemplateRecipeCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **str** | Name of the task that will be created from this template. | [optional] -**task_resource_subtype** | **str** | The subtype of the task that will be created from this template. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskTemplateRecipeDependencies.md b/docs/TaskTemplateRecipeDependencies.md deleted file mode 100644 index 831cc6a4..00000000 --- a/docs/TaskTemplateRecipeDependencies.md +++ /dev/null @@ -1,10 +0,0 @@ -# TaskTemplateRecipeDependencies - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **str** | Name of the task that will be created from this template. | [optional] -**task_resource_subtype** | **str** | The subtype of the task that will be created from this template. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskTemplateResponse.md b/docs/TaskTemplateResponse.md deleted file mode 100644 index a365c824..00000000 --- a/docs/TaskTemplateResponse.md +++ /dev/null @@ -1,15 +0,0 @@ -# TaskTemplateResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the task template. | [optional] -**project** | **AllOfTaskTemplateResponseProject** | The project that this task template belongs to. | [optional] -**template** | **AllOfTaskTemplateResponseTemplate** | The configuration for the task that will be created from this template. | [optional] -**created_by** | **AllOfTaskTemplateResponseCreatedBy** | The user who created this task template. | [optional] -**created_at** | **datetime** | The time at which this task template was created. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskTemplateResponseArray.md b/docs/TaskTemplateResponseArray.md deleted file mode 100644 index 4890b911..00000000 --- a/docs/TaskTemplateResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# TaskTemplateResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[TaskTemplateResponse]**](TaskTemplateResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskTemplateResponseData.md b/docs/TaskTemplateResponseData.md deleted file mode 100644 index 1a14e46e..00000000 --- a/docs/TaskTemplateResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# TaskTemplateResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskTemplateResponse**](TaskTemplateResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TaskTemplatesApi.md b/docs/TaskTemplatesApi.md deleted file mode 100644 index 4fe886b2..00000000 --- a/docs/TaskTemplatesApi.md +++ /dev/null @@ -1,175 +0,0 @@ -# asana.TaskTemplatesApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**get_task_template**](TaskTemplatesApi.md#get_task_template) | **GET** /task_templates/{task_template_gid} | Get a task template -[**get_task_templates**](TaskTemplatesApi.md#get_task_templates) | **GET** /task_templates | Get multiple task templates -[**instantiate_task**](TaskTemplatesApi.md#instantiate_task) | **POST** /task_templates/{task_template_gid}/instantiateTask | Instantiate a task from a task template - -# **get_task_template** -> TaskTemplateResponseData get_task_template(task_template_gid, opt_fields=opt_fields) - -Get a task template - -Returns the complete task template record for a single task template. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TaskTemplatesApi(api_client) -task_template_gid = '1331' # str | Globally unique identifier for the task template. -opt_fields = ["created_at","created_by","name","project","template"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a task template - api_response = api_instance.get_task_template(task_template_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TaskTemplatesApi->get_task_template: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **task_template_gid** | **str**| Globally unique identifier for the task template. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskTemplateResponseData**](TaskTemplateResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_task_templates** -> TaskTemplateResponseArray get_task_templates(limit=limit, offset=offset, project=project, opt_fields=opt_fields) - -Get multiple task templates - -Returns the compact task template records for some filtered set of task templates. You must specify a `project` - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TaskTemplatesApi(api_client) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -project = '321654' # str | The project to filter task templates on. (optional) -opt_fields = ["created_at","created_by","name","project","template"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get multiple task templates - api_response = api_instance.get_task_templates(limit=limit, offset=offset, project=project, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TaskTemplatesApi->get_task_templates: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **project** | **str**| The project to filter task templates on. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskTemplateResponseArray**](TaskTemplateResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **instantiate_task** -> JobResponseData instantiate_task(task_template_gid, body=body, opt_fields=opt_fields) - -Instantiate a task from a task template - -Creates and returns a job that will asynchronously handle the task instantiation. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TaskTemplatesApi(api_client) -task_template_gid = '1331' # str | Globally unique identifier for the task template. -body = asana.TaskTemplateGidInstantiateTaskBody({"param1": "value1", "param2": "value2",}) # TaskTemplateGidInstantiateTaskBody | Describes the inputs used for instantiating a task - the task's name. (optional) -opt_fields = ["new_project","new_project.name","new_project_template","new_project_template.name","new_task","new_task.created_by","new_task.name","new_task.resource_subtype","resource_subtype","status"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Instantiate a task from a task template - api_response = api_instance.instantiate_task(task_template_gid, body=body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TaskTemplatesApi->instantiate_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **task_template_gid** | **str**| Globally unique identifier for the task template. | - **body** | [**TaskTemplateGidInstantiateTaskBody**](TaskTemplateGidInstantiateTaskBody.md)| Describes the inputs used for instantiating a task - the task's name. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**JobResponseData**](JobResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/TaskTemplatesApi.yaml b/docs/TaskTemplatesApi.yaml deleted file mode 100644 index 4dee7210..00000000 --- a/docs/TaskTemplatesApi.yaml +++ /dev/null @@ -1,67 +0,0 @@ -TaskTemplatesApi: - get_task_template: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TaskTemplatesApi(api_client) - task_template_gid = '1331' # str | Globally unique identifier for the task template. - opt_fields = ["created_at","created_by","name","project","template"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a task template - api_response = api_instance.get_task_template(task_template_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TaskTemplatesApi->get_task_template: %s\n" % e) - get_task_templates: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TaskTemplatesApi(api_client) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - project = '321654' # str | The project to filter task templates on. (optional) - opt_fields = ["created_at","created_by","name","project","template"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get multiple task templates - api_response = api_instance.get_task_templates(limit=limit, offset=offset, project=project, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TaskTemplatesApi->get_task_templates: %s\n" % e) - instantiate_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TaskTemplatesApi(api_client) - task_template_gid = '1331' # str | Globally unique identifier for the task template. - body = asana.TaskTemplateGidInstantiateTaskBody({"param1": "value1", "param2": "value2",}) # TaskTemplateGidInstantiateTaskBody | Describes the inputs used for instantiating a task - the task's name. (optional) - opt_fields = ["new_project","new_project.name","new_project_template","new_project_template.name","new_task","new_task.created_by","new_task.name","new_task.resource_subtype","resource_subtype","status"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Instantiate a task from a task template - api_response = api_instance.instantiate_task(task_template_gid, body=body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TaskTemplatesApi->instantiate_task: %s\n" % e) diff --git a/docs/TasksApi.md b/docs/TasksApi.md deleted file mode 100644 index b121b077..00000000 --- a/docs/TasksApi.md +++ /dev/null @@ -1,1580 +0,0 @@ -# asana.TasksApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**add_dependencies_for_task**](TasksApi.md#add_dependencies_for_task) | **POST** /tasks/{task_gid}/addDependencies | Set dependencies for a task -[**add_dependents_for_task**](TasksApi.md#add_dependents_for_task) | **POST** /tasks/{task_gid}/addDependents | Set dependents for a task -[**add_followers_for_task**](TasksApi.md#add_followers_for_task) | **POST** /tasks/{task_gid}/addFollowers | Add followers to a task -[**add_project_for_task**](TasksApi.md#add_project_for_task) | **POST** /tasks/{task_gid}/addProject | Add a project to a task -[**add_tag_for_task**](TasksApi.md#add_tag_for_task) | **POST** /tasks/{task_gid}/addTag | Add a tag to a task -[**create_subtask_for_task**](TasksApi.md#create_subtask_for_task) | **POST** /tasks/{task_gid}/subtasks | Create a subtask -[**create_task**](TasksApi.md#create_task) | **POST** /tasks | Create a task -[**delete_task**](TasksApi.md#delete_task) | **DELETE** /tasks/{task_gid} | Delete a task -[**duplicate_task**](TasksApi.md#duplicate_task) | **POST** /tasks/{task_gid}/duplicate | Duplicate a task -[**get_dependencies_for_task**](TasksApi.md#get_dependencies_for_task) | **GET** /tasks/{task_gid}/dependencies | Get dependencies from a task -[**get_dependents_for_task**](TasksApi.md#get_dependents_for_task) | **GET** /tasks/{task_gid}/dependents | Get dependents from a task -[**get_subtasks_for_task**](TasksApi.md#get_subtasks_for_task) | **GET** /tasks/{task_gid}/subtasks | Get subtasks from a task -[**get_task**](TasksApi.md#get_task) | **GET** /tasks/{task_gid} | Get a task -[**get_tasks**](TasksApi.md#get_tasks) | **GET** /tasks | Get multiple tasks -[**get_tasks_for_project**](TasksApi.md#get_tasks_for_project) | **GET** /projects/{project_gid}/tasks | Get tasks from a project -[**get_tasks_for_section**](TasksApi.md#get_tasks_for_section) | **GET** /sections/{section_gid}/tasks | Get tasks from a section -[**get_tasks_for_tag**](TasksApi.md#get_tasks_for_tag) | **GET** /tags/{tag_gid}/tasks | Get tasks from a tag -[**get_tasks_for_user_task_list**](TasksApi.md#get_tasks_for_user_task_list) | **GET** /user_task_lists/{user_task_list_gid}/tasks | Get tasks from a user task list -[**remove_dependencies_for_task**](TasksApi.md#remove_dependencies_for_task) | **POST** /tasks/{task_gid}/removeDependencies | Unlink dependencies from a task -[**remove_dependents_for_task**](TasksApi.md#remove_dependents_for_task) | **POST** /tasks/{task_gid}/removeDependents | Unlink dependents from a task -[**remove_follower_for_task**](TasksApi.md#remove_follower_for_task) | **POST** /tasks/{task_gid}/removeFollowers | Remove followers from a task -[**remove_project_for_task**](TasksApi.md#remove_project_for_task) | **POST** /tasks/{task_gid}/removeProject | Remove a project from a task -[**remove_tag_for_task**](TasksApi.md#remove_tag_for_task) | **POST** /tasks/{task_gid}/removeTag | Remove a tag from a task -[**search_tasks_for_workspace**](TasksApi.md#search_tasks_for_workspace) | **GET** /workspaces/{workspace_gid}/tasks/search | Search tasks in a workspace -[**set_parent_for_task**](TasksApi.md#set_parent_for_task) | **POST** /tasks/{task_gid}/setParent | Set the parent of a task -[**update_task**](TasksApi.md#update_task) | **PUT** /tasks/{task_gid} | Update a task - -# **add_dependencies_for_task** -> EmptyResponseData add_dependencies_for_task(body, task_gid) - -Set dependencies for a task - -Marks a set of tasks as dependencies of this task, if they are not already dependencies. *A task can have at most 30 dependents and dependencies combined*. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TaskGidAddDependenciesBody({"param1": "value1", "param2": "value2",}) # TaskGidAddDependenciesBody | The list of tasks to set as dependencies. -task_gid = '321654' # str | The task to operate on. - -try: - # Set dependencies for a task - api_response = api_instance.add_dependencies_for_task(body, task_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->add_dependencies_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidAddDependenciesBody**](TaskGidAddDependenciesBody.md)| The list of tasks to set as dependencies. | - **task_gid** | **str**| The task to operate on. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **add_dependents_for_task** -> EmptyResponseData add_dependents_for_task(body, task_gid) - -Set dependents for a task - -Marks a set of tasks as dependents of this task, if they are not already dependents. *A task can have at most 30 dependents and dependencies combined*. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TaskGidAddDependentsBody({"param1": "value1", "param2": "value2",}) # TaskGidAddDependentsBody | The list of tasks to add as dependents. -task_gid = '321654' # str | The task to operate on. - -try: - # Set dependents for a task - api_response = api_instance.add_dependents_for_task(body, task_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->add_dependents_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidAddDependentsBody**](TaskGidAddDependentsBody.md)| The list of tasks to add as dependents. | - **task_gid** | **str**| The task to operate on. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **add_followers_for_task** -> TaskResponseData add_followers_for_task(body, task_gid, opt_fields=opt_fields) - -Add followers to a task - -Adds followers to a task. Returns an empty data block. Each task can be associated with zero or more followers in the system. Requests to add/remove followers, if successful, will return the complete updated task record, described above. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TaskGidAddFollowersBody({"param1": "value1", "param2": "value2",}) # TaskGidAddFollowersBody | The followers to add to the task. -task_gid = '321654' # str | The task to operate on. -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Add followers to a task - api_response = api_instance.add_followers_for_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->add_followers_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidAddFollowersBody**](TaskGidAddFollowersBody.md)| The followers to add to the task. | - **task_gid** | **str**| The task to operate on. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseData**](TaskResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **add_project_for_task** -> EmptyResponseData add_project_for_task(body, task_gid) - -Add a project to a task - -Adds the task to the specified project, in the optional location specified. If no location arguments are given, the task will be added to the end of the project. `addProject` can also be used to reorder a task within a project or section that already contains it. At most one of `insert_before`, `insert_after`, or `section` should be specified. Inserting into a section in an non-order-dependent way can be done by specifying section, otherwise, to insert within a section in a particular place, specify `insert_before` or `insert_after` and a task within the section to anchor the position of this task. Returns an empty data block. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TaskGidAddProjectBody({"param1": "value1", "param2": "value2",}) # TaskGidAddProjectBody | The project to add the task to. -task_gid = '321654' # str | The task to operate on. - -try: - # Add a project to a task - api_response = api_instance.add_project_for_task(body, task_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->add_project_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidAddProjectBody**](TaskGidAddProjectBody.md)| The project to add the task to. | - **task_gid** | **str**| The task to operate on. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **add_tag_for_task** -> EmptyResponseData add_tag_for_task(body, task_gid) - -Add a tag to a task - -Adds a tag to a task. Returns an empty data block. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TaskGidAddTagBody({"param1": "value1", "param2": "value2",}) # TaskGidAddTagBody | The tag to add to the task. -task_gid = '321654' # str | The task to operate on. - -try: - # Add a tag to a task - api_response = api_instance.add_tag_for_task(body, task_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->add_tag_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidAddTagBody**](TaskGidAddTagBody.md)| The tag to add to the task. | - **task_gid** | **str**| The task to operate on. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **create_subtask_for_task** -> TaskResponseData create_subtask_for_task(body, task_gid, opt_fields=opt_fields) - -Create a subtask - -Creates a new subtask and adds it to the parent task. Returns the full record for the newly created subtask. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TaskGidSubtasksBody({"param1": "value1", "param2": "value2",}) # TaskGidSubtasksBody | The new subtask to create. -task_gid = '321654' # str | The task to operate on. -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a subtask - api_response = api_instance.create_subtask_for_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->create_subtask_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidSubtasksBody**](TaskGidSubtasksBody.md)| The new subtask to create. | - **task_gid** | **str**| The task to operate on. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseData**](TaskResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **create_task** -> TaskResponseData create_task(body, opt_fields=opt_fields) - -Create a task - -Creating a new task is as easy as POSTing to the `/tasks` endpoint with a data block containing the fields you’d like to set on the task. Any unspecified fields will take on default values. Every task is required to be created in a specific workspace, and this workspace cannot be changed once set. The workspace need not be set explicitly if you specify `projects` or a `parent` task instead. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TasksBody({"param1": "value1", "param2": "value2",}) # TasksBody | The task to create. -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a task - api_response = api_instance.create_task(body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->create_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TasksBody**](TasksBody.md)| The task to create. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseData**](TaskResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_task** -> EmptyResponseData delete_task(task_gid) - -Delete a task - -A specific, existing task can be deleted by making a DELETE request on the URL for that task. Deleted tasks go into the “trash” of the user making the delete request. Tasks can be recovered from the trash within a period of 30 days; afterward they are completely removed from the system. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -task_gid = '321654' # str | The task to operate on. - -try: - # Delete a task - api_response = api_instance.delete_task(task_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->delete_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **task_gid** | **str**| The task to operate on. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **duplicate_task** -> JobResponseData duplicate_task(body, task_gid, opt_fields=opt_fields) - -Duplicate a task - -Creates and returns a job that will asynchronously handle the duplication. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TaskGidDuplicateBody({"param1": "value1", "param2": "value2",}) # TaskGidDuplicateBody | Describes the duplicate's name and the fields that will be duplicated. -task_gid = '321654' # str | The task to operate on. -opt_fields = ["new_project","new_project.name","new_project_template","new_project_template.name","new_task","new_task.created_by","new_task.name","new_task.resource_subtype","resource_subtype","status"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Duplicate a task - api_response = api_instance.duplicate_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->duplicate_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidDuplicateBody**](TaskGidDuplicateBody.md)| Describes the duplicate's name and the fields that will be duplicated. | - **task_gid** | **str**| The task to operate on. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**JobResponseData**](JobResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_dependencies_for_task** -> TaskResponseArray get_dependencies_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get dependencies from a task - -Returns the compact representations of all of the dependencies of a task. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -task_gid = '321654' # str | The task to operate on. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get dependencies from a task - api_response = api_instance.get_dependencies_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->get_dependencies_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **task_gid** | **str**| The task to operate on. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseArray**](TaskResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_dependents_for_task** -> TaskResponseArray get_dependents_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get dependents from a task - -Returns the compact representations of all of the dependents of a task. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -task_gid = '321654' # str | The task to operate on. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get dependents from a task - api_response = api_instance.get_dependents_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->get_dependents_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **task_gid** | **str**| The task to operate on. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseArray**](TaskResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_subtasks_for_task** -> TaskResponseArray get_subtasks_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get subtasks from a task - -Returns a compact representation of all of the subtasks of a task. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -task_gid = '321654' # str | The task to operate on. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get subtasks from a task - api_response = api_instance.get_subtasks_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->get_subtasks_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **task_gid** | **str**| The task to operate on. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseArray**](TaskResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_task** -> TaskResponseData get_task(task_gid, opt_fields=opt_fields) - -Get a task - -Returns the complete task record for a single task. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -task_gid = '321654' # str | The task to operate on. -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a task - api_response = api_instance.get_task(task_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->get_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **task_gid** | **str**| The task to operate on. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseData**](TaskResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_tasks** -> TaskResponseArray get_tasks(limit=limit, offset=offset, assignee=assignee, project=project, section=section, workspace=workspace, completed_since=completed_since, modified_since=modified_since, opt_fields=opt_fields) - -Get multiple tasks - -Returns the compact task records for some filtered set of tasks. Use one or more of the parameters provided to filter the tasks returned. You must specify a `project` or `tag` if you do not specify `assignee` and `workspace`. For more complex task retrieval, use [workspaces/{workspace_gid}/tasks/search](/reference/searchtasksforworkspace). - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -assignee = '14641' # str | The assignee to filter tasks on. If searching for unassigned tasks, assignee.any = null can be specified. *Note: If you specify `assignee`, you must also specify the `workspace` to filter on.* (optional) -project = '321654' # str | The project to filter tasks on. (optional) -section = '321654' # str | The section to filter tasks on. (optional) -workspace = '321654' # str | The workspace to filter tasks on. *Note: If you specify `workspace`, you must also specify the `assignee` to filter on.* (optional) -completed_since = '2012-02-22T02:06:58.158Z' # datetime | Only return tasks that are either incomplete or that have been completed since this time. (optional) -modified_since = '2012-02-22T02:06:58.158Z' # datetime | Only return tasks that have been modified since the given time. *Note: A task is considered “modified” if any of its properties change, or associations between it and other objects are modified (e.g. a task being added to a project). A task is not considered modified just because another object it is associated with (e.g. a subtask) is modified. Actions that count as modifying the task include assigning, renaming, completing, and adding stories.* (optional) -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get multiple tasks - api_response = api_instance.get_tasks(limit=limit, offset=offset, assignee=assignee, project=project, section=section, workspace=workspace, completed_since=completed_since, modified_since=modified_since, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->get_tasks: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **assignee** | **str**| The assignee to filter tasks on. If searching for unassigned tasks, assignee.any = null can be specified. *Note: If you specify `assignee`, you must also specify the `workspace` to filter on.* | [optional] - **project** | **str**| The project to filter tasks on. | [optional] - **section** | **str**| The section to filter tasks on. | [optional] - **workspace** | **str**| The workspace to filter tasks on. *Note: If you specify `workspace`, you must also specify the `assignee` to filter on.* | [optional] - **completed_since** | **datetime**| Only return tasks that are either incomplete or that have been completed since this time. | [optional] - **modified_since** | **datetime**| Only return tasks that have been modified since the given time. *Note: A task is considered “modified” if any of its properties change, or associations between it and other objects are modified (e.g. a task being added to a project). A task is not considered modified just because another object it is associated with (e.g. a subtask) is modified. Actions that count as modifying the task include assigning, renaming, completing, and adding stories.* | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseArray**](TaskResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_tasks_for_project** -> TaskResponseArray get_tasks_for_project(project_gid, completed_since=completed_since, limit=limit, offset=offset, opt_fields=opt_fields) - -Get tasks from a project - -Returns the compact task records for all tasks within the given project, ordered by their priority within the project. Tasks can exist in more than one project at a time. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -project_gid = '1331' # str | Globally unique identifier for the project. -completed_since = '2012-02-22T02:06:58.158Z' # str | Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. (optional) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get tasks from a project - api_response = api_instance.get_tasks_for_project(project_gid, completed_since=completed_since, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->get_tasks_for_project: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **project_gid** | **str**| Globally unique identifier for the project. | - **completed_since** | **str**| Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. | [optional] - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseArray**](TaskResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_tasks_for_section** -> TaskResponseArray get_tasks_for_section(section_gid, limit=limit, offset=offset, completed_since=completed_since, opt_fields=opt_fields) - -Get tasks from a section - -*Board view only*: Returns the compact section records for all tasks within the given section. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -section_gid = '321654' # str | The globally unique identifier for the section. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -completed_since = '2012-02-22T02:06:58.158Z' # str | Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. (optional) -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get tasks from a section - api_response = api_instance.get_tasks_for_section(section_gid, limit=limit, offset=offset, completed_since=completed_since, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->get_tasks_for_section: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **section_gid** | **str**| The globally unique identifier for the section. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **completed_since** | **str**| Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseArray**](TaskResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_tasks_for_tag** -> TaskResponseArray get_tasks_for_tag(tag_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get tasks from a tag - -Returns the compact task records for all tasks with the given tag. Tasks can have more than one tag at a time. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -tag_gid = '11235' # str | Globally unique identifier for the tag. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get tasks from a tag - api_response = api_instance.get_tasks_for_tag(tag_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->get_tasks_for_tag: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **tag_gid** | **str**| Globally unique identifier for the tag. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseArray**](TaskResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_tasks_for_user_task_list** -> TaskResponseArray get_tasks_for_user_task_list(user_task_list_gid, completed_since=completed_since, limit=limit, offset=offset, opt_fields=opt_fields) - -Get tasks from a user task list - -Returns the compact list of tasks in a user’s My Tasks list. *Note: Access control is enforced for this endpoint as with all Asana API endpoints, meaning a user’s private tasks will be filtered out if the API-authenticated user does not have access to them.* *Note: Both complete and incomplete tasks are returned by default unless they are filtered out (for example, setting `completed_since=now` will return only incomplete tasks, which is the default view for “My Tasks” in Asana.)* - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -user_task_list_gid = '12345' # str | Globally unique identifier for the user task list. -completed_since = '2012-02-22T02:06:58.158Z' # str | Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. (optional) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get tasks from a user task list - api_response = api_instance.get_tasks_for_user_task_list(user_task_list_gid, completed_since=completed_since, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->get_tasks_for_user_task_list: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user_task_list_gid** | **str**| Globally unique identifier for the user task list. | - **completed_since** | **str**| Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. | [optional] - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseArray**](TaskResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_dependencies_for_task** -> EmptyResponseData remove_dependencies_for_task(body, task_gid) - -Unlink dependencies from a task - -Unlinks a set of dependencies from this task. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TaskGidRemoveDependenciesBody({"param1": "value1", "param2": "value2",}) # TaskGidRemoveDependenciesBody | The list of tasks to unlink as dependencies. -task_gid = '321654' # str | The task to operate on. - -try: - # Unlink dependencies from a task - api_response = api_instance.remove_dependencies_for_task(body, task_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->remove_dependencies_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidRemoveDependenciesBody**](TaskGidRemoveDependenciesBody.md)| The list of tasks to unlink as dependencies. | - **task_gid** | **str**| The task to operate on. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_dependents_for_task** -> EmptyResponseData remove_dependents_for_task(body, task_gid) - -Unlink dependents from a task - -Unlinks a set of dependents from this task. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TaskGidRemoveDependentsBody({"param1": "value1", "param2": "value2",}) # TaskGidRemoveDependentsBody | The list of tasks to remove as dependents. -task_gid = '321654' # str | The task to operate on. - -try: - # Unlink dependents from a task - api_response = api_instance.remove_dependents_for_task(body, task_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->remove_dependents_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidRemoveDependentsBody**](TaskGidRemoveDependentsBody.md)| The list of tasks to remove as dependents. | - **task_gid** | **str**| The task to operate on. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_follower_for_task** -> TaskResponseData remove_follower_for_task(body, task_gid, opt_fields=opt_fields) - -Remove followers from a task - -Removes each of the specified followers from the task if they are following. Returns the complete, updated record for the affected task. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TaskGidRemoveFollowersBody({"param1": "value1", "param2": "value2",}) # TaskGidRemoveFollowersBody | The followers to remove from the task. -task_gid = '321654' # str | The task to operate on. -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Remove followers from a task - api_response = api_instance.remove_follower_for_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->remove_follower_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidRemoveFollowersBody**](TaskGidRemoveFollowersBody.md)| The followers to remove from the task. | - **task_gid** | **str**| The task to operate on. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseData**](TaskResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_project_for_task** -> EmptyResponseData remove_project_for_task(body, task_gid) - -Remove a project from a task - -Removes the task from the specified project. The task will still exist in the system, but it will not be in the project anymore. Returns an empty data block. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TaskGidRemoveProjectBody({"param1": "value1", "param2": "value2",}) # TaskGidRemoveProjectBody | The project to remove the task from. -task_gid = '321654' # str | The task to operate on. - -try: - # Remove a project from a task - api_response = api_instance.remove_project_for_task(body, task_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->remove_project_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidRemoveProjectBody**](TaskGidRemoveProjectBody.md)| The project to remove the task from. | - **task_gid** | **str**| The task to operate on. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_tag_for_task** -> EmptyResponseData remove_tag_for_task(body, task_gid) - -Remove a tag from a task - -Removes a tag from a task. Returns an empty data block. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TaskGidRemoveTagBody({"param1": "value1", "param2": "value2",}) # TaskGidRemoveTagBody | The tag to remove from the task. -task_gid = '321654' # str | The task to operate on. - -try: - # Remove a tag from a task - api_response = api_instance.remove_tag_for_task(body, task_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->remove_tag_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidRemoveTagBody**](TaskGidRemoveTagBody.md)| The tag to remove from the task. | - **task_gid** | **str**| The task to operate on. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **search_tasks_for_workspace** -> TaskResponseArray search_tasks_for_workspace(workspace_gid, text=text, resource_subtype=resource_subtype, assignee_any=assignee_any, assignee_not=assignee_not, portfolios_any=portfolios_any, projects_any=projects_any, projects_not=projects_not, projects_all=projects_all, sections_any=sections_any, sections_not=sections_not, sections_all=sections_all, tags_any=tags_any, tags_not=tags_not, tags_all=tags_all, teams_any=teams_any, followers_not=followers_not, created_by_any=created_by_any, created_by_not=created_by_not, assigned_by_any=assigned_by_any, assigned_by_not=assigned_by_not, liked_by_not=liked_by_not, commented_on_by_not=commented_on_by_not, due_on_before=due_on_before, due_on_after=due_on_after, due_on=due_on, due_at_before=due_at_before, due_at_after=due_at_after, start_on_before=start_on_before, start_on_after=start_on_after, start_on=start_on, created_on_before=created_on_before, created_on_after=created_on_after, created_on=created_on, created_at_before=created_at_before, created_at_after=created_at_after, completed_on_before=completed_on_before, completed_on_after=completed_on_after, completed_on=completed_on, completed_at_before=completed_at_before, completed_at_after=completed_at_after, modified_on_before=modified_on_before, modified_on_after=modified_on_after, modified_on=modified_on, modified_at_before=modified_at_before, modified_at_after=modified_at_after, is_blocking=is_blocking, is_blocked=is_blocked, has_attachment=has_attachment, completed=completed, is_subtask=is_subtask, sort_by=sort_by, sort_ascending=sort_ascending, opt_fields=opt_fields) - -Search tasks in a workspace - -To mirror the functionality of the Asana web app's advanced search feature, the Asana API has a task search endpoint that allows you to build complex filters to find and retrieve the exact data you need. #### Premium access Like the Asana web product's advance search feature, this search endpoint will only be available to premium Asana users. A user is premium if any of the following is true: - The workspace in which the search is being performed is a premium workspace - The user is a member of a premium team inside the workspace Even if a user is only a member of a premium team inside a non-premium workspace, search will allow them to find data anywhere in the workspace, not just inside the premium team. Making a search request using credentials of a non-premium user will result in a `402 Payment Required` error. #### Pagination Search results are not stable; repeating the same query multiple times may return the data in a different order, even if the data do not change. Because of this, the traditional [pagination](https://developers.asana.com/docs/#pagination) available elsewhere in the Asana API is not available here. However, you can paginate manually by sorting the search results by their creation time and then modifying each subsequent query to exclude data you have already seen. Page sizes are limited to a maximum of 100 items, and can be specified by the `limit` query parameter. #### Eventual consistency Changes in Asana (regardless of whether they’re made though the web product or the API) are forwarded to our search infrastructure to be indexed. This process can take between 10 and 60 seconds to complete under normal operation, and longer during some production incidents. Making a change to a task that would alter its presence in a particular search query will not be reflected immediately. This is also true of the advanced search feature in the web product. #### Rate limits You may receive a `429 Too Many Requests` response if you hit any of our [rate limits](https://developers.asana.com/docs/#rate-limits). #### Custom field parameters | Parameter name | Custom field type | Accepted type | |---|---|---| | custom_fields.{gid}.is_set | All | Boolean | | custom_fields.{gid}.value | Text | String | | custom_fields.{gid}.value | Number | Number | | custom_fields.{gid}.value | Enum | Enum option ID | | custom_fields.{gid}.starts_with | Text only | String | | custom_fields.{gid}.ends_with | Text only | String | | custom_fields.{gid}.contains | Text only | String | | custom_fields.{gid}.less_than | Number only | Number | | custom_fields.{gid}.greater_than | Number only | Number | For example, if the gid of the custom field is 12345, these query parameter to find tasks where it is set would be `custom_fields.12345.is_set=true`. To match an exact value for an enum custom field, use the gid of the desired enum option and not the name of the enum option: `custom_fields.12345.value=67890`. **Not Supported**: searching for multiple exact matches of a custom field, searching for multi-enum custom field *Note: If you specify `projects.any` and `sections.any`, you will receive tasks for the project **and** tasks for the section. If you're looking for only tasks in a section, omit the `projects.any` from the request.* - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -text = 'Bug' # str | Performs full-text search on both task name and description (optional) -resource_subtype = 'milestone' # str | Filters results by the task's resource_subtype (optional) (default to milestone) -assignee_any = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) -assignee_not = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) -portfolios_any = '12345,23456,34567' # str | Comma-separated list of portfolio IDs (optional) -projects_any = '12345,23456,34567' # str | Comma-separated list of project IDs (optional) -projects_not = '12345,23456,34567' # str | Comma-separated list of project IDs (optional) -projects_all = '12345,23456,34567' # str | Comma-separated list of project IDs (optional) -sections_any = '12345,23456,34567' # str | Comma-separated list of section or column IDs (optional) -sections_not = '12345,23456,34567' # str | Comma-separated list of section or column IDs (optional) -sections_all = '12345,23456,34567' # str | Comma-separated list of section or column IDs (optional) -tags_any = '12345,23456,34567' # str | Comma-separated list of tag IDs (optional) -tags_not = '12345,23456,34567' # str | Comma-separated list of tag IDs (optional) -tags_all = '12345,23456,34567' # str | Comma-separated list of tag IDs (optional) -teams_any = '12345,23456,34567' # str | Comma-separated list of team IDs (optional) -followers_not = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) -created_by_any = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) -created_by_not = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) -assigned_by_any = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) -assigned_by_not = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) -liked_by_not = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) -commented_on_by_not = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) -due_on_before = '2019-09-15' # date | ISO 8601 date string (optional) -due_on_after = '2019-09-15' # date | ISO 8601 date string (optional) -due_on = '2019-09-15' # date | ISO 8601 date string or `null` (optional) -due_at_before = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) -due_at_after = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) -start_on_before = '2019-09-15' # date | ISO 8601 date string (optional) -start_on_after = '2019-09-15' # date | ISO 8601 date string (optional) -start_on = '2019-09-15' # date | ISO 8601 date string or `null` (optional) -created_on_before = '2019-09-15' # date | ISO 8601 date string (optional) -created_on_after = '2019-09-15' # date | ISO 8601 date string (optional) -created_on = '2019-09-15' # date | ISO 8601 date string or `null` (optional) -created_at_before = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) -created_at_after = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) -completed_on_before = '2019-09-15' # date | ISO 8601 date string (optional) -completed_on_after = '2019-09-15' # date | ISO 8601 date string (optional) -completed_on = '2019-09-15' # date | ISO 8601 date string or `null` (optional) -completed_at_before = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) -completed_at_after = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) -modified_on_before = '2019-09-15' # date | ISO 8601 date string (optional) -modified_on_after = '2019-09-15' # date | ISO 8601 date string (optional) -modified_on = '2019-09-15' # date | ISO 8601 date string or `null` (optional) -modified_at_before = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) -modified_at_after = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) -is_blocking = false # bool | Filter to incomplete tasks with dependents (optional) -is_blocked = false # bool | Filter to tasks with incomplete dependencies (optional) -has_attachment = false # bool | Filter to tasks with attachments (optional) -completed = false # bool | Filter to completed tasks (optional) -is_subtask = false # bool | Filter to subtasks (optional) -sort_by = 'modified_at' # str | One of `due_date`, `created_at`, `completed_at`, `likes`, or `modified_at`, defaults to `modified_at` (optional) (default to modified_at) -sort_ascending = false # bool | Default `false` (optional) (default to false) -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) -custom_fields_123_is_set = True # bool | Filiter to tasks with custom field set or unset. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field -custom_fields_123_value = '456' # str or bool or Enum option ID | Filter to tasks with custom field that matches the provided value. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field -custom_fields_123_starts_with = 'start' # string | Filter to tasks with custom field that starts with provided string. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field -custom_fields_123_ends_with = 'end' # string | Filter to tasks with custom field that ends in provided string. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field -custom_fields_123_contains = 'first' # string | Filter to tasks with custom field that contains the provided string. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field -custom_fields_123_less_than = 10 # number | Filter to tasks with custom field with number value less than the provided number. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field -custom_fields_123_greater_than = 100 # number | Filter to tasks with custom field with number value greater than the provided number. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field - -try: - # Search tasks in a workspace - api_response = api_instance.search_tasks_for_workspace(workspace_gid, text=text, resource_subtype=resource_subtype, assignee_any=assignee_any, assignee_not=assignee_not, portfolios_any=portfolios_any, projects_any=projects_any, projects_not=projects_not, projects_all=projects_all, sections_any=sections_any, sections_not=sections_not, sections_all=sections_all, tags_any=tags_any, tags_not=tags_not, tags_all=tags_all, teams_any=teams_any, followers_not=followers_not, created_by_any=created_by_any, created_by_not=created_by_not, assigned_by_any=assigned_by_any, assigned_by_not=assigned_by_not, liked_by_not=liked_by_not, commented_on_by_not=commented_on_by_not, due_on_before=due_on_before, due_on_after=due_on_after, due_on=due_on, due_at_before=due_at_before, due_at_after=due_at_after, start_on_before=start_on_before, start_on_after=start_on_after, start_on=start_on, created_on_before=created_on_before, created_on_after=created_on_after, created_on=created_on, created_at_before=created_at_before, created_at_after=created_at_after, completed_on_before=completed_on_before, completed_on_after=completed_on_after, completed_on=completed_on, completed_at_before=completed_at_before, completed_at_after=completed_at_after, modified_on_before=modified_on_before, modified_on_after=modified_on_after, modified_on=modified_on, modified_at_before=modified_at_before, modified_at_after=modified_at_after, is_blocking=is_blocking, is_blocked=is_blocked, has_attachment=has_attachment, completed=completed, is_subtask=is_subtask, sort_by=sort_by, sort_ascending=sort_ascending, opt_fields=opt_fields, custom_fields_123_value=custom_fields_123_value, custom_fields_123_starts_with=custom_fields_123_starts_with, custom_fields_123_ends_with=custom_fields_123_ends_with, custom_fields_123_contains=custom_fields_123_contains, custom_fields_123_less_than=custom_fields_123_less_than, custom_fields_123_greater_than=custom_fields_123_greater_than) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->search_tasks_for_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **text** | **str**| Performs full-text search on both task name and description | [optional] - **resource_subtype** | **str**| Filters results by the task's resource_subtype | [optional] [default to milestone] - **assignee_any** | **str**| Comma-separated list of user identifiers | [optional] - **assignee_not** | **str**| Comma-separated list of user identifiers | [optional] - **portfolios_any** | **str**| Comma-separated list of portfolio IDs | [optional] - **projects_any** | **str**| Comma-separated list of project IDs | [optional] - **projects_not** | **str**| Comma-separated list of project IDs | [optional] - **projects_all** | **str**| Comma-separated list of project IDs | [optional] - **sections_any** | **str**| Comma-separated list of section or column IDs | [optional] - **sections_not** | **str**| Comma-separated list of section or column IDs | [optional] - **sections_all** | **str**| Comma-separated list of section or column IDs | [optional] - **tags_any** | **str**| Comma-separated list of tag IDs | [optional] - **tags_not** | **str**| Comma-separated list of tag IDs | [optional] - **tags_all** | **str**| Comma-separated list of tag IDs | [optional] - **teams_any** | **str**| Comma-separated list of team IDs | [optional] - **followers_not** | **str**| Comma-separated list of user identifiers | [optional] - **created_by_any** | **str**| Comma-separated list of user identifiers | [optional] - **created_by_not** | **str**| Comma-separated list of user identifiers | [optional] - **assigned_by_any** | **str**| Comma-separated list of user identifiers | [optional] - **assigned_by_not** | **str**| Comma-separated list of user identifiers | [optional] - **liked_by_not** | **str**| Comma-separated list of user identifiers | [optional] - **commented_on_by_not** | **str**| Comma-separated list of user identifiers | [optional] - **due_on_before** | **date**| ISO 8601 date string | [optional] - **due_on_after** | **date**| ISO 8601 date string | [optional] - **due_on** | **date**| ISO 8601 date string or `null` | [optional] - **due_at_before** | **datetime**| ISO 8601 datetime string | [optional] - **due_at_after** | **datetime**| ISO 8601 datetime string | [optional] - **start_on_before** | **date**| ISO 8601 date string | [optional] - **start_on_after** | **date**| ISO 8601 date string | [optional] - **start_on** | **date**| ISO 8601 date string or `null` | [optional] - **created_on_before** | **date**| ISO 8601 date string | [optional] - **created_on_after** | **date**| ISO 8601 date string | [optional] - **created_on** | **date**| ISO 8601 date string or `null` | [optional] - **created_at_before** | **datetime**| ISO 8601 datetime string | [optional] - **created_at_after** | **datetime**| ISO 8601 datetime string | [optional] - **completed_on_before** | **date**| ISO 8601 date string | [optional] - **completed_on_after** | **date**| ISO 8601 date string | [optional] - **completed_on** | **date**| ISO 8601 date string or `null` | [optional] - **completed_at_before** | **datetime**| ISO 8601 datetime string | [optional] - **completed_at_after** | **datetime**| ISO 8601 datetime string | [optional] - **modified_on_before** | **date**| ISO 8601 date string | [optional] - **modified_on_after** | **date**| ISO 8601 date string | [optional] - **modified_on** | **date**| ISO 8601 date string or `null` | [optional] - **modified_at_before** | **datetime**| ISO 8601 datetime string | [optional] - **modified_at_after** | **datetime**| ISO 8601 datetime string | [optional] - **is_blocking** | **bool**| Filter to incomplete tasks with dependents | [optional] - **is_blocked** | **bool**| Filter to tasks with incomplete dependencies | [optional] - **has_attachment** | **bool**| Filter to tasks with attachments | [optional] - **completed** | **bool**| Filter to completed tasks | [optional] - **is_subtask** | **bool**| Filter to subtasks | [optional] - **sort_by** | **str**| One of `due_date`, `created_at`, `completed_at`, `likes`, or `modified_at`, defaults to `modified_at` | [optional] [default to modified_at] - **sort_ascending** | **bool**| Default `false` | [optional] [default to false] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseArray**](TaskResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **set_parent_for_task** -> TaskResponseData set_parent_for_task(body, task_gid, opt_fields=opt_fields) - -Set the parent of a task - -parent, or no parent task at all. Returns an empty data block. When using `insert_before` and `insert_after`, at most one of those two options can be specified, and they must already be subtasks of the parent. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TaskGidSetParentBody({"param1": "value1", "param2": "value2",}) # TaskGidSetParentBody | The new parent of the subtask. -task_gid = '321654' # str | The task to operate on. -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Set the parent of a task - api_response = api_instance.set_parent_for_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->set_parent_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidSetParentBody**](TaskGidSetParentBody.md)| The new parent of the subtask. | - **task_gid** | **str**| The task to operate on. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseData**](TaskResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_task** -> TaskResponseData update_task(body, task_gid, opt_fields=opt_fields) - -Update a task - -A specific, existing task can be updated by making a PUT request on the URL for that task. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the task. Returns the complete updated task record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TasksApi(api_client) -body = asana.TasksTaskGidBody({"param1": "value1", "param2": "value2",}) # TasksTaskGidBody | The task to update. -task_gid = '321654' # str | The task to operate on. -opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a task - api_response = api_instance.update_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TasksApi->update_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TasksTaskGidBody**](TasksTaskGidBody.md)| The task to update. | - **task_gid** | **str**| The task to operate on. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TaskResponseData**](TaskResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/TasksApi.yaml b/docs/TasksApi.yaml deleted file mode 100644 index d814f593..00000000 --- a/docs/TasksApi.yaml +++ /dev/null @@ -1,635 +0,0 @@ -TasksApi: - add_dependencies_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TaskGidAddDependenciesBody({"param1": "value1", "param2": "value2",}) # TaskGidAddDependenciesBody | The list of tasks to set as dependencies. - task_gid = '321654' # str | The task to operate on. - - try: - # Set dependencies for a task - api_response = api_instance.add_dependencies_for_task(body, task_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->add_dependencies_for_task: %s\n" % e) - add_dependents_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TaskGidAddDependentsBody({"param1": "value1", "param2": "value2",}) # TaskGidAddDependentsBody | The list of tasks to add as dependents. - task_gid = '321654' # str | The task to operate on. - - try: - # Set dependents for a task - api_response = api_instance.add_dependents_for_task(body, task_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->add_dependents_for_task: %s\n" % e) - add_followers_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TaskGidAddFollowersBody({"param1": "value1", "param2": "value2",}) # TaskGidAddFollowersBody | The followers to add to the task. - task_gid = '321654' # str | The task to operate on. - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Add followers to a task - api_response = api_instance.add_followers_for_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->add_followers_for_task: %s\n" % e) - add_project_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TaskGidAddProjectBody({"param1": "value1", "param2": "value2",}) # TaskGidAddProjectBody | The project to add the task to. - task_gid = '321654' # str | The task to operate on. - - try: - # Add a project to a task - api_response = api_instance.add_project_for_task(body, task_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->add_project_for_task: %s\n" % e) - add_tag_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TaskGidAddTagBody({"param1": "value1", "param2": "value2",}) # TaskGidAddTagBody | The tag to add to the task. - task_gid = '321654' # str | The task to operate on. - - try: - # Add a tag to a task - api_response = api_instance.add_tag_for_task(body, task_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->add_tag_for_task: %s\n" % e) - create_subtask_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TaskGidSubtasksBody({"param1": "value1", "param2": "value2",}) # TaskGidSubtasksBody | The new subtask to create. - task_gid = '321654' # str | The task to operate on. - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a subtask - api_response = api_instance.create_subtask_for_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->create_subtask_for_task: %s\n" % e) - create_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TasksBody({"param1": "value1", "param2": "value2",}) # TasksBody | The task to create. - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a task - api_response = api_instance.create_task(body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->create_task: %s\n" % e) - delete_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - task_gid = '321654' # str | The task to operate on. - - try: - # Delete a task - api_response = api_instance.delete_task(task_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->delete_task: %s\n" % e) - duplicate_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TaskGidDuplicateBody({"param1": "value1", "param2": "value2",}) # TaskGidDuplicateBody | Describes the duplicate's name and the fields that will be duplicated. - task_gid = '321654' # str | The task to operate on. - opt_fields = ["new_project","new_project.name","new_project_template","new_project_template.name","new_task","new_task.created_by","new_task.name","new_task.resource_subtype","resource_subtype","status"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Duplicate a task - api_response = api_instance.duplicate_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->duplicate_task: %s\n" % e) - get_dependencies_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - task_gid = '321654' # str | The task to operate on. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get dependencies from a task - api_response = api_instance.get_dependencies_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->get_dependencies_for_task: %s\n" % e) - get_dependents_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - task_gid = '321654' # str | The task to operate on. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get dependents from a task - api_response = api_instance.get_dependents_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->get_dependents_for_task: %s\n" % e) - get_subtasks_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - task_gid = '321654' # str | The task to operate on. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get subtasks from a task - api_response = api_instance.get_subtasks_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->get_subtasks_for_task: %s\n" % e) - get_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - task_gid = '321654' # str | The task to operate on. - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a task - api_response = api_instance.get_task(task_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->get_task: %s\n" % e) - get_tasks: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - assignee = '14641' # str | The assignee to filter tasks on. If searching for unassigned tasks, assignee.any = null can be specified. *Note: If you specify `assignee`, you must also specify the `workspace` to filter on.* (optional) - project = '321654' # str | The project to filter tasks on. (optional) - section = '321654' # str | The section to filter tasks on. (optional) - workspace = '321654' # str | The workspace to filter tasks on. *Note: If you specify `workspace`, you must also specify the `assignee` to filter on.* (optional) - completed_since = '2012-02-22T02:06:58.158Z' # datetime | Only return tasks that are either incomplete or that have been completed since this time. (optional) - modified_since = '2012-02-22T02:06:58.158Z' # datetime | Only return tasks that have been modified since the given time. *Note: A task is considered “modified” if any of its properties change, or associations between it and other objects are modified (e.g. a task being added to a project). A task is not considered modified just because another object it is associated with (e.g. a subtask) is modified. Actions that count as modifying the task include assigning, renaming, completing, and adding stories.* (optional) - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get multiple tasks - api_response = api_instance.get_tasks(limit=limit, offset=offset, assignee=assignee, project=project, section=section, workspace=workspace, completed_since=completed_since, modified_since=modified_since, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->get_tasks: %s\n" % e) - get_tasks_for_project: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - project_gid = '1331' # str | Globally unique identifier for the project. - completed_since = '2012-02-22T02:06:58.158Z' # str | Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. (optional) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get tasks from a project - api_response = api_instance.get_tasks_for_project(project_gid, completed_since=completed_since, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->get_tasks_for_project: %s\n" % e) - get_tasks_for_section: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - section_gid = '321654' # str | The globally unique identifier for the section. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - completed_since = '2012-02-22T02:06:58.158Z' # str | Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. (optional) - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get tasks from a section - api_response = api_instance.get_tasks_for_section(section_gid, limit=limit, offset=offset, completed_since=completed_since, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->get_tasks_for_section: %s\n" % e) - get_tasks_for_tag: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - tag_gid = '11235' # str | Globally unique identifier for the tag. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get tasks from a tag - api_response = api_instance.get_tasks_for_tag(tag_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->get_tasks_for_tag: %s\n" % e) - get_tasks_for_user_task_list: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - user_task_list_gid = '12345' # str | Globally unique identifier for the user task list. - completed_since = '2012-02-22T02:06:58.158Z' # str | Only return tasks that are either incomplete or that have been completed since this time. Accepts a date-time string or the keyword *now*. (optional) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","offset","parent","parent.created_by","parent.name","parent.resource_subtype","path","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","uri","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get tasks from a user task list - api_response = api_instance.get_tasks_for_user_task_list(user_task_list_gid, completed_since=completed_since, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->get_tasks_for_user_task_list: %s\n" % e) - remove_dependencies_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TaskGidRemoveDependenciesBody({"param1": "value1", "param2": "value2",}) # TaskGidRemoveDependenciesBody | The list of tasks to unlink as dependencies. - task_gid = '321654' # str | The task to operate on. - - try: - # Unlink dependencies from a task - api_response = api_instance.remove_dependencies_for_task(body, task_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->remove_dependencies_for_task: %s\n" % e) - remove_dependents_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TaskGidRemoveDependentsBody({"param1": "value1", "param2": "value2",}) # TaskGidRemoveDependentsBody | The list of tasks to remove as dependents. - task_gid = '321654' # str | The task to operate on. - - try: - # Unlink dependents from a task - api_response = api_instance.remove_dependents_for_task(body, task_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->remove_dependents_for_task: %s\n" % e) - remove_follower_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TaskGidRemoveFollowersBody({"param1": "value1", "param2": "value2",}) # TaskGidRemoveFollowersBody | The followers to remove from the task. - task_gid = '321654' # str | The task to operate on. - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Remove followers from a task - api_response = api_instance.remove_follower_for_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->remove_follower_for_task: %s\n" % e) - remove_project_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TaskGidRemoveProjectBody({"param1": "value1", "param2": "value2",}) # TaskGidRemoveProjectBody | The project to remove the task from. - task_gid = '321654' # str | The task to operate on. - - try: - # Remove a project from a task - api_response = api_instance.remove_project_for_task(body, task_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->remove_project_for_task: %s\n" % e) - remove_tag_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TaskGidRemoveTagBody({"param1": "value1", "param2": "value2",}) # TaskGidRemoveTagBody | The tag to remove from the task. - task_gid = '321654' # str | The task to operate on. - - try: - # Remove a tag from a task - api_response = api_instance.remove_tag_for_task(body, task_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->remove_tag_for_task: %s\n" % e) - search_tasks_for_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - text = 'Bug' # str | Performs full-text search on both task name and description (optional) - resource_subtype = 'milestone' # str | Filters results by the task's resource_subtype (optional) (default to milestone) - assignee_any = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) - assignee_not = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) - portfolios_any = '12345,23456,34567' # str | Comma-separated list of portfolio IDs (optional) - projects_any = '12345,23456,34567' # str | Comma-separated list of project IDs (optional) - projects_not = '12345,23456,34567' # str | Comma-separated list of project IDs (optional) - projects_all = '12345,23456,34567' # str | Comma-separated list of project IDs (optional) - sections_any = '12345,23456,34567' # str | Comma-separated list of section or column IDs (optional) - sections_not = '12345,23456,34567' # str | Comma-separated list of section or column IDs (optional) - sections_all = '12345,23456,34567' # str | Comma-separated list of section or column IDs (optional) - tags_any = '12345,23456,34567' # str | Comma-separated list of tag IDs (optional) - tags_not = '12345,23456,34567' # str | Comma-separated list of tag IDs (optional) - tags_all = '12345,23456,34567' # str | Comma-separated list of tag IDs (optional) - teams_any = '12345,23456,34567' # str | Comma-separated list of team IDs (optional) - followers_not = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) - created_by_any = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) - created_by_not = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) - assigned_by_any = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) - assigned_by_not = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) - liked_by_not = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) - commented_on_by_not = '12345,23456,34567' # str | Comma-separated list of user identifiers (optional) - due_on_before = '2019-09-15' # date | ISO 8601 date string (optional) - due_on_after = '2019-09-15' # date | ISO 8601 date string (optional) - due_on = '2019-09-15' # date | ISO 8601 date string or `null` (optional) - due_at_before = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) - due_at_after = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) - start_on_before = '2019-09-15' # date | ISO 8601 date string (optional) - start_on_after = '2019-09-15' # date | ISO 8601 date string (optional) - start_on = '2019-09-15' # date | ISO 8601 date string or `null` (optional) - created_on_before = '2019-09-15' # date | ISO 8601 date string (optional) - created_on_after = '2019-09-15' # date | ISO 8601 date string (optional) - created_on = '2019-09-15' # date | ISO 8601 date string or `null` (optional) - created_at_before = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) - created_at_after = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) - completed_on_before = '2019-09-15' # date | ISO 8601 date string (optional) - completed_on_after = '2019-09-15' # date | ISO 8601 date string (optional) - completed_on = '2019-09-15' # date | ISO 8601 date string or `null` (optional) - completed_at_before = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) - completed_at_after = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) - modified_on_before = '2019-09-15' # date | ISO 8601 date string (optional) - modified_on_after = '2019-09-15' # date | ISO 8601 date string (optional) - modified_on = '2019-09-15' # date | ISO 8601 date string or `null` (optional) - modified_at_before = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) - modified_at_after = '2019-04-15T01:01:46.055Z' # datetime | ISO 8601 datetime string (optional) - is_blocking = false # bool | Filter to incomplete tasks with dependents (optional) - is_blocked = false # bool | Filter to tasks with incomplete dependencies (optional) - has_attachment = false # bool | Filter to tasks with attachments (optional) - completed = false # bool | Filter to completed tasks (optional) - is_subtask = false # bool | Filter to subtasks (optional) - sort_by = 'modified_at' # str | One of `due_date`, `created_at`, `completed_at`, `likes`, or `modified_at`, defaults to `modified_at` (optional) (default to modified_at) - sort_ascending = false # bool | Default `false` (optional) (default to false) - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - custom_fields_123_is_set = True # bool | Filiter to tasks with custom field set or unset. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field - custom_fields_123_value = '456' # str or bool or Enum option ID | Filter to tasks with custom field that matches the provided value. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field - custom_fields_123_starts_with = 'start' # string | Filter to tasks with custom field that starts with provided string. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field - custom_fields_123_ends_with = 'end' # string | Filter to tasks with custom field that ends in provided string. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field - custom_fields_123_contains = 'first' # string | Filter to tasks with custom field that contains the provided string. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field - custom_fields_123_less_than = 10 # number | Filter to tasks with custom field with number value less than the provided number. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field - custom_fields_123_greater_than = 100 # number | Filter to tasks with custom field with number value greater than the provided number. NOTE: searching for multiple exact matches of a custom field, searching for multi-enum custom field - - try: - # Search tasks in a workspace - api_response = api_instance.search_tasks_for_workspace(workspace_gid, text=text, resource_subtype=resource_subtype, assignee_any=assignee_any, assignee_not=assignee_not, portfolios_any=portfolios_any, projects_any=projects_any, projects_not=projects_not, projects_all=projects_all, sections_any=sections_any, sections_not=sections_not, sections_all=sections_all, tags_any=tags_any, tags_not=tags_not, tags_all=tags_all, teams_any=teams_any, followers_not=followers_not, created_by_any=created_by_any, created_by_not=created_by_not, assigned_by_any=assigned_by_any, assigned_by_not=assigned_by_not, liked_by_not=liked_by_not, commented_on_by_not=commented_on_by_not, due_on_before=due_on_before, due_on_after=due_on_after, due_on=due_on, due_at_before=due_at_before, due_at_after=due_at_after, start_on_before=start_on_before, start_on_after=start_on_after, start_on=start_on, created_on_before=created_on_before, created_on_after=created_on_after, created_on=created_on, created_at_before=created_at_before, created_at_after=created_at_after, completed_on_before=completed_on_before, completed_on_after=completed_on_after, completed_on=completed_on, completed_at_before=completed_at_before, completed_at_after=completed_at_after, modified_on_before=modified_on_before, modified_on_after=modified_on_after, modified_on=modified_on, modified_at_before=modified_at_before, modified_at_after=modified_at_after, is_blocking=is_blocking, is_blocked=is_blocked, has_attachment=has_attachment, completed=completed, is_subtask=is_subtask, sort_by=sort_by, sort_ascending=sort_ascending, opt_fields=opt_fields, custom_fields_123_value=custom_fields_123_value, custom_fields_123_starts_with=custom_fields_123_starts_with, custom_fields_123_ends_with=custom_fields_123_ends_with, custom_fields_123_contains=custom_fields_123_contains, custom_fields_123_less_than=custom_fields_123_less_than, custom_fields_123_greater_than=custom_fields_123_greater_than) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->search_tasks_for_workspace: %s\n" % e) - set_parent_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TaskGidSetParentBody({"param1": "value1", "param2": "value2",}) # TaskGidSetParentBody | The new parent of the subtask. - task_gid = '321654' # str | The task to operate on. - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Set the parent of a task - api_response = api_instance.set_parent_for_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->set_parent_for_task: %s\n" % e) - update_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TasksApi(api_client) - body = asana.TasksTaskGidBody({"param1": "value1", "param2": "value2",}) # TasksTaskGidBody | The task to update. - task_gid = '321654' # str | The task to operate on. - opt_fields = ["actual_time_minutes","approval_status","assignee","assignee.name","assignee_section","assignee_section.name","assignee_status","completed","completed_at","completed_by","completed_by.name","created_at","created_by","custom_fields","custom_fields.asana_created_field","custom_fields.created_by","custom_fields.created_by.name","custom_fields.currency_code","custom_fields.custom_label","custom_fields.custom_label_position","custom_fields.date_value","custom_fields.date_value.date","custom_fields.date_value.date_time","custom_fields.description","custom_fields.display_value","custom_fields.enabled","custom_fields.enum_options","custom_fields.enum_options.color","custom_fields.enum_options.enabled","custom_fields.enum_options.name","custom_fields.enum_value","custom_fields.enum_value.color","custom_fields.enum_value.enabled","custom_fields.enum_value.name","custom_fields.format","custom_fields.has_notifications_enabled","custom_fields.is_formula_field","custom_fields.is_global_to_workspace","custom_fields.is_value_read_only","custom_fields.multi_enum_values","custom_fields.multi_enum_values.color","custom_fields.multi_enum_values.enabled","custom_fields.multi_enum_values.name","custom_fields.name","custom_fields.number_value","custom_fields.people_value","custom_fields.people_value.name","custom_fields.precision","custom_fields.resource_subtype","custom_fields.text_value","custom_fields.type","dependencies","dependents","due_at","due_on","external","external.data","followers","followers.name","hearted","hearts","hearts.user","hearts.user.name","html_notes","is_rendered_as_separator","liked","likes","likes.user","likes.user.name","memberships","memberships.project","memberships.project.name","memberships.section","memberships.section.name","modified_at","name","notes","num_hearts","num_likes","num_subtasks","parent","parent.created_by","parent.name","parent.resource_subtype","permalink_url","projects","projects.name","resource_subtype","start_at","start_on","tags","tags.name","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a task - api_response = api_instance.update_task(body, task_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TasksApi->update_task: %s\n" % e) diff --git a/docs/TasksBody.md b/docs/TasksBody.md deleted file mode 100644 index 35fafceb..00000000 --- a/docs/TasksBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TasksBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskRequest**](TaskRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TasksTaskGidBody.md b/docs/TasksTaskGidBody.md deleted file mode 100644 index 7dbf9ceb..00000000 --- a/docs/TasksTaskGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TasksTaskGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TaskRequest**](TaskRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamAddUserRequest.md b/docs/TeamAddUserRequest.md deleted file mode 100644 index 2e64cf84..00000000 --- a/docs/TeamAddUserRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# TeamAddUserRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**user** | **str** | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamBase.md b/docs/TeamBase.md deleted file mode 100644 index 7e9119b4..00000000 --- a/docs/TeamBase.md +++ /dev/null @@ -1,11 +0,0 @@ -# TeamBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the team. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamCompact.md b/docs/TeamCompact.md deleted file mode 100644 index 337f2c79..00000000 --- a/docs/TeamCompact.md +++ /dev/null @@ -1,11 +0,0 @@ -# TeamCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the team. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamGidAddUserBody.md b/docs/TeamGidAddUserBody.md deleted file mode 100644 index 93f6f60d..00000000 --- a/docs/TeamGidAddUserBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TeamGidAddUserBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TeamAddUserRequest**](TeamAddUserRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamGidProjectsBody.md b/docs/TeamGidProjectsBody.md deleted file mode 100644 index 7f383d1d..00000000 --- a/docs/TeamGidProjectsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TeamGidProjectsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectRequest**](ProjectRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamGidRemoveUserBody.md b/docs/TeamGidRemoveUserBody.md deleted file mode 100644 index 7a2e35d1..00000000 --- a/docs/TeamGidRemoveUserBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TeamGidRemoveUserBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TeamRemoveUserRequest**](TeamRemoveUserRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamMembershipBase.md b/docs/TeamMembershipBase.md deleted file mode 100644 index 621d6fdb..00000000 --- a/docs/TeamMembershipBase.md +++ /dev/null @@ -1,15 +0,0 @@ -# TeamMembershipBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**team** | [**ProjectTemplateBaseTeam**](ProjectTemplateBaseTeam.md) | | [optional] -**is_guest** | **bool** | Describes if the user is a guest in the team. | [optional] -**is_limited_access** | **bool** | Describes if the user has limited access to the team. | [optional] -**is_admin** | **bool** | Describes if the user is a team admin. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamMembershipCompact.md b/docs/TeamMembershipCompact.md deleted file mode 100644 index 0b62aca8..00000000 --- a/docs/TeamMembershipCompact.md +++ /dev/null @@ -1,15 +0,0 @@ -# TeamMembershipCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**team** | [**ProjectTemplateBaseTeam**](ProjectTemplateBaseTeam.md) | | [optional] -**is_guest** | **bool** | Describes if the user is a guest in the team. | [optional] -**is_limited_access** | **bool** | Describes if the user has limited access to the team. | [optional] -**is_admin** | **bool** | Describes if the user is a team admin. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamMembershipResponse.md b/docs/TeamMembershipResponse.md deleted file mode 100644 index 180e4185..00000000 --- a/docs/TeamMembershipResponse.md +++ /dev/null @@ -1,15 +0,0 @@ -# TeamMembershipResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**team** | [**ProjectTemplateBaseTeam**](ProjectTemplateBaseTeam.md) | | [optional] -**is_guest** | **bool** | Describes if the user is a guest in the team. | [optional] -**is_limited_access** | **bool** | Describes if the user has limited access to the team. | [optional] -**is_admin** | **bool** | Describes if the user is a team admin. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamMembershipResponseArray.md b/docs/TeamMembershipResponseArray.md deleted file mode 100644 index 6ca102de..00000000 --- a/docs/TeamMembershipResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# TeamMembershipResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[TeamMembershipResponse]**](TeamMembershipResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamMembershipResponseData.md b/docs/TeamMembershipResponseData.md deleted file mode 100644 index fad374b5..00000000 --- a/docs/TeamMembershipResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# TeamMembershipResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TeamMembershipResponse**](TeamMembershipResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamMembershipsApi.md b/docs/TeamMembershipsApi.md deleted file mode 100644 index ee0bab31..00000000 --- a/docs/TeamMembershipsApi.md +++ /dev/null @@ -1,241 +0,0 @@ -# asana.TeamMembershipsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**get_team_membership**](TeamMembershipsApi.md#get_team_membership) | **GET** /team_memberships/{team_membership_gid} | Get a team membership -[**get_team_memberships**](TeamMembershipsApi.md#get_team_memberships) | **GET** /team_memberships | Get team memberships -[**get_team_memberships_for_team**](TeamMembershipsApi.md#get_team_memberships_for_team) | **GET** /teams/{team_gid}/team_memberships | Get memberships from a team -[**get_team_memberships_for_user**](TeamMembershipsApi.md#get_team_memberships_for_user) | **GET** /users/{user_gid}/team_memberships | Get memberships from a user - -# **get_team_membership** -> TeamMembershipResponseData get_team_membership(team_membership_gid, opt_fields=opt_fields) - -Get a team membership - -Returns the complete team membership record for a single team membership. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TeamMembershipsApi(api_client) -team_membership_gid = '724362' # str | -opt_fields = ["is_admin","is_guest","is_limited_access","team","team.name","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a team membership - api_response = api_instance.get_team_membership(team_membership_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TeamMembershipsApi->get_team_membership: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **team_membership_gid** | **str**| | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TeamMembershipResponseData**](TeamMembershipResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_team_memberships** -> TeamMembershipResponseArray get_team_memberships(limit=limit, offset=offset, team=team, user=user, workspace=workspace, opt_fields=opt_fields) - -Get team memberships - -Returns compact team membership records. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TeamMembershipsApi(api_client) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -team = '159874' # str | Globally unique identifier for the team. (optional) -user = '512241' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. This parameter must be used with the workspace parameter. (optional) -workspace = '31326' # str | Globally unique identifier for the workspace. This parameter must be used with the user parameter. (optional) -opt_fields = ["is_admin","is_guest","is_limited_access","offset","path","team","team.name","uri","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get team memberships - api_response = api_instance.get_team_memberships(limit=limit, offset=offset, team=team, user=user, workspace=workspace, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TeamMembershipsApi->get_team_memberships: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **team** | **str**| Globally unique identifier for the team. | [optional] - **user** | **str**| A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. This parameter must be used with the workspace parameter. | [optional] - **workspace** | **str**| Globally unique identifier for the workspace. This parameter must be used with the user parameter. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TeamMembershipResponseArray**](TeamMembershipResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_team_memberships_for_team** -> TeamMembershipResponseArray get_team_memberships_for_team(team_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get memberships from a team - -Returns the compact team memberships for the team. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TeamMembershipsApi(api_client) -team_gid = '159874' # str | Globally unique identifier for the team. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["is_admin","is_guest","is_limited_access","offset","path","team","team.name","uri","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get memberships from a team - api_response = api_instance.get_team_memberships_for_team(team_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TeamMembershipsApi->get_team_memberships_for_team: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **team_gid** | **str**| Globally unique identifier for the team. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TeamMembershipResponseArray**](TeamMembershipResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_team_memberships_for_user** -> TeamMembershipResponseArray get_team_memberships_for_user(user_gid, workspace, limit=limit, offset=offset, opt_fields=opt_fields) - -Get memberships from a user - -Returns the compact team membership records for the user. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TeamMembershipsApi(api_client) -user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. -workspace = '31326' # str | Globally unique identifier for the workspace. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["is_admin","is_guest","is_limited_access","offset","path","team","team.name","uri","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get memberships from a user - api_response = api_instance.get_team_memberships_for_user(user_gid, workspace, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TeamMembershipsApi->get_team_memberships_for_user: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user_gid** | **str**| A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | - **workspace** | **str**| Globally unique identifier for the workspace. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TeamMembershipResponseArray**](TeamMembershipResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/TeamMembershipsApi.yaml b/docs/TeamMembershipsApi.yaml deleted file mode 100644 index 75ddcbbb..00000000 --- a/docs/TeamMembershipsApi.yaml +++ /dev/null @@ -1,94 +0,0 @@ -TeamMembershipsApi: - get_team_membership: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TeamMembershipsApi(api_client) - team_membership_gid = '724362' # str | - opt_fields = ["is_admin","is_guest","is_limited_access","team","team.name","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a team membership - api_response = api_instance.get_team_membership(team_membership_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TeamMembershipsApi->get_team_membership: %s\n" % e) - get_team_memberships: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TeamMembershipsApi(api_client) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - team = '159874' # str | Globally unique identifier for the team. (optional) - user = '512241' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. This parameter must be used with the workspace parameter. (optional) - workspace = '31326' # str | Globally unique identifier for the workspace. This parameter must be used with the user parameter. (optional) - opt_fields = ["is_admin","is_guest","is_limited_access","offset","path","team","team.name","uri","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get team memberships - api_response = api_instance.get_team_memberships(limit=limit, offset=offset, team=team, user=user, workspace=workspace, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TeamMembershipsApi->get_team_memberships: %s\n" % e) - get_team_memberships_for_team: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TeamMembershipsApi(api_client) - team_gid = '159874' # str | Globally unique identifier for the team. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["is_admin","is_guest","is_limited_access","offset","path","team","team.name","uri","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get memberships from a team - api_response = api_instance.get_team_memberships_for_team(team_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TeamMembershipsApi->get_team_memberships_for_team: %s\n" % e) - get_team_memberships_for_user: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TeamMembershipsApi(api_client) - user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - workspace = '31326' # str | Globally unique identifier for the workspace. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["is_admin","is_guest","is_limited_access","offset","path","team","team.name","uri","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get memberships from a user - api_response = api_instance.get_team_memberships_for_user(user_gid, workspace, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TeamMembershipsApi->get_team_memberships_for_user: %s\n" % e) diff --git a/docs/TeamRemoveUserRequest.md b/docs/TeamRemoveUserRequest.md deleted file mode 100644 index bb29facf..00000000 --- a/docs/TeamRemoveUserRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# TeamRemoveUserRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**user** | **str** | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamRequest.md b/docs/TeamRequest.md deleted file mode 100644 index 506cbde2..00000000 --- a/docs/TeamRequest.md +++ /dev/null @@ -1,21 +0,0 @@ -# TeamRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the team. | [optional] -**description** | **str** | The description of the team. | [optional] -**html_description** | **str** | The description of the team with formatting as HTML. | [optional] -**organization** | **str** | The organization/workspace the team belongs to. This must be the same organization you are in and cannot be changed once set. | [optional] -**visibility** | **str** | The visibility of the team to users in the same organization | [optional] -**edit_team_name_or_description_access_level** | **str** | Controls who can edit team name and description | [optional] -**edit_team_visibility_or_trash_team_access_level** | **str** | Controls who can edit team visibility and trash teams | [optional] -**member_invite_management_access_level** | **str** | Controls who can accept or deny member invites for a given team | [optional] -**guest_invite_management_access_level** | **str** | Controls who can accept or deny guest invites for a given team | [optional] -**join_request_management_access_level** | **str** | Controls who can accept or deny join team requests for a Membership by Request team | [optional] -**team_member_removal_access_level** | **str** | Controls who can remove team members | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamResponse.md b/docs/TeamResponse.md deleted file mode 100644 index 1e15531e..00000000 --- a/docs/TeamResponse.md +++ /dev/null @@ -1,22 +0,0 @@ -# TeamResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the team. | [optional] -**description** | **str** | [Opt In](/docs/inputoutput-options). The description of the team. | [optional] -**html_description** | **str** | [Opt In](/docs/inputoutput-options). The description of the team with formatting as HTML. | [optional] -**organization** | [**TeamResponseOrganization**](TeamResponseOrganization.md) | | [optional] -**permalink_url** | **str** | A url that points directly to the object within Asana. | [optional] -**visibility** | **str** | The visibility of the team to users in the same organization | [optional] -**edit_team_name_or_description_access_level** | **str** | Controls who can edit team name and description | [optional] -**edit_team_visibility_or_trash_team_access_level** | **str** | Controls who can edit team visibility and trash teams | [optional] -**member_invite_management_access_level** | **str** | Controls who can accept or deny member invites for a given team | [optional] -**guest_invite_management_access_level** | **str** | Controls who can accept or deny guest invites for a given team | [optional] -**join_request_management_access_level** | **str** | Controls who can accept or deny join team requests for a Membership by Request team | [optional] -**team_member_removal_access_level** | **str** | Controls who can remove team members | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamResponseArray.md b/docs/TeamResponseArray.md deleted file mode 100644 index 9ffce711..00000000 --- a/docs/TeamResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# TeamResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[TeamResponse]**](TeamResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamResponseData.md b/docs/TeamResponseData.md deleted file mode 100644 index dcc55420..00000000 --- a/docs/TeamResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# TeamResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TeamResponse**](TeamResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamResponseOrganization.md b/docs/TeamResponseOrganization.md deleted file mode 100644 index 9fcadd26..00000000 --- a/docs/TeamResponseOrganization.md +++ /dev/null @@ -1,11 +0,0 @@ -# TeamResponseOrganization - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the workspace. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamsApi.md b/docs/TeamsApi.md deleted file mode 100644 index f90605a2..00000000 --- a/docs/TeamsApi.md +++ /dev/null @@ -1,399 +0,0 @@ -# asana.TeamsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**add_user_for_team**](TeamsApi.md#add_user_for_team) | **POST** /teams/{team_gid}/addUser | Add a user to a team -[**create_team**](TeamsApi.md#create_team) | **POST** /teams | Create a team -[**get_team**](TeamsApi.md#get_team) | **GET** /teams/{team_gid} | Get a team -[**get_teams_for_user**](TeamsApi.md#get_teams_for_user) | **GET** /users/{user_gid}/teams | Get teams for a user -[**get_teams_for_workspace**](TeamsApi.md#get_teams_for_workspace) | **GET** /workspaces/{workspace_gid}/teams | Get teams in a workspace -[**remove_user_for_team**](TeamsApi.md#remove_user_for_team) | **POST** /teams/{team_gid}/removeUser | Remove a user from a team -[**update_team**](TeamsApi.md#update_team) | **PUT** /teams/{team_gid} | Update a team - -# **add_user_for_team** -> TeamMembershipResponseData add_user_for_team(body, team_gid, opt_fields=opt_fields) - -Add a user to a team - -The user making this call must be a member of the team in order to add others. The user being added must exist in the same organization as the team. Returns the complete team membership record for the newly added user. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TeamsApi(api_client) -body = asana.TeamGidAddUserBody({"param1": "value1", "param2": "value2",}) # TeamGidAddUserBody | The user to add to the team. -team_gid = '159874' # str | Globally unique identifier for the team. -opt_fields = ["is_admin","is_guest","is_limited_access","team","team.name","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Add a user to a team - api_response = api_instance.add_user_for_team(body, team_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TeamsApi->add_user_for_team: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TeamGidAddUserBody**](TeamGidAddUserBody.md)| The user to add to the team. | - **team_gid** | **str**| Globally unique identifier for the team. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TeamMembershipResponseData**](TeamMembershipResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **create_team** -> TeamResponseData create_team(body, opt_fields=opt_fields) - -Create a team - -Creates a team within the current workspace. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TeamsApi(api_client) -body = asana.TeamsBody({"param1": "value1", "param2": "value2",}) # TeamsBody | The team to create. -opt_fields = ["description","edit_team_name_or_description_access_level","edit_team_visibility_or_trash_team_access_level","guest_invite_management_access_level","html_description","join_request_management_access_level","member_invite_management_access_level","name","organization","organization.name","permalink_url","team_member_removal_access_level","visibility"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a team - api_response = api_instance.create_team(body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TeamsApi->create_team: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TeamsBody**](TeamsBody.md)| The team to create. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TeamResponseData**](TeamResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_team** -> TeamResponseData get_team(team_gid, opt_fields=opt_fields) - -Get a team - -Returns the full record for a single team. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TeamsApi(api_client) -team_gid = '159874' # str | Globally unique identifier for the team. -opt_fields = ["description","edit_team_name_or_description_access_level","edit_team_visibility_or_trash_team_access_level","guest_invite_management_access_level","html_description","join_request_management_access_level","member_invite_management_access_level","name","organization","organization.name","permalink_url","team_member_removal_access_level","visibility"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a team - api_response = api_instance.get_team(team_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TeamsApi->get_team: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **team_gid** | **str**| Globally unique identifier for the team. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TeamResponseData**](TeamResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_teams_for_user** -> TeamResponseArray get_teams_for_user(user_gid, organization, limit=limit, offset=offset, opt_fields=opt_fields) - -Get teams for a user - -Returns the compact records for all teams to which the given user is assigned. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TeamsApi(api_client) -user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. -organization = '1331' # str | The workspace or organization to filter teams on. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["description","edit_team_name_or_description_access_level","edit_team_visibility_or_trash_team_access_level","guest_invite_management_access_level","html_description","join_request_management_access_level","member_invite_management_access_level","name","offset","organization","organization.name","path","permalink_url","team_member_removal_access_level","uri","visibility"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get teams for a user - api_response = api_instance.get_teams_for_user(user_gid, organization, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TeamsApi->get_teams_for_user: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user_gid** | **str**| A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | - **organization** | **str**| The workspace or organization to filter teams on. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TeamResponseArray**](TeamResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_teams_for_workspace** -> TeamResponseArray get_teams_for_workspace(workspace_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get teams in a workspace - -Returns the compact records for all teams in the workspace visible to the authorized user. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TeamsApi(api_client) -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["description","edit_team_name_or_description_access_level","edit_team_visibility_or_trash_team_access_level","guest_invite_management_access_level","html_description","join_request_management_access_level","member_invite_management_access_level","name","offset","organization","organization.name","path","permalink_url","team_member_removal_access_level","uri","visibility"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get teams in a workspace - api_response = api_instance.get_teams_for_workspace(workspace_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TeamsApi->get_teams_for_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TeamResponseArray**](TeamResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_user_for_team** -> EmptyResponseData remove_user_for_team(body, team_gid) - -Remove a user from a team - -The user making this call must be a member of the team in order to remove themselves or others. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TeamsApi(api_client) -body = asana.TeamGidRemoveUserBody({"param1": "value1", "param2": "value2",}) # TeamGidRemoveUserBody | The user to remove from the team. -team_gid = '159874' # str | Globally unique identifier for the team. - -try: - # Remove a user from a team - api_response = api_instance.remove_user_for_team(body, team_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TeamsApi->remove_user_for_team: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TeamGidRemoveUserBody**](TeamGidRemoveUserBody.md)| The user to remove from the team. | - **team_gid** | **str**| Globally unique identifier for the team. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_team** -> TeamResponseData update_team(body, team_gid, opt_fields=opt_fields) - -Update a team - -Updates a team within the current workspace. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TeamsApi(api_client) -body = asana.TeamsTeamGidBody({"param1": "value1", "param2": "value2",}) # TeamsTeamGidBody | The team to update. -team_gid = '159874' # str | Globally unique identifier for the team. -opt_fields = ["description","edit_team_name_or_description_access_level","edit_team_visibility_or_trash_team_access_level","guest_invite_management_access_level","html_description","join_request_management_access_level","member_invite_management_access_level","name","organization","organization.name","permalink_url","team_member_removal_access_level","visibility"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a team - api_response = api_instance.update_team(body, team_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TeamsApi->update_team: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TeamsTeamGidBody**](TeamsTeamGidBody.md)| The team to update. | - **team_gid** | **str**| Globally unique identifier for the team. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TeamResponseData**](TeamResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/TeamsApi.yaml b/docs/TeamsApi.yaml deleted file mode 100644 index 24dab33e..00000000 --- a/docs/TeamsApi.yaml +++ /dev/null @@ -1,155 +0,0 @@ -TeamsApi: - add_user_for_team: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TeamsApi(api_client) - body = asana.TeamGidAddUserBody({"param1": "value1", "param2": "value2",}) # TeamGidAddUserBody | The user to add to the team. - team_gid = '159874' # str | Globally unique identifier for the team. - opt_fields = ["is_admin","is_guest","is_limited_access","team","team.name","user","user.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Add a user to a team - api_response = api_instance.add_user_for_team(body, team_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TeamsApi->add_user_for_team: %s\n" % e) - create_team: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TeamsApi(api_client) - body = asana.TeamsBody({"param1": "value1", "param2": "value2",}) # TeamsBody | The team to create. - opt_fields = ["description","edit_team_name_or_description_access_level","edit_team_visibility_or_trash_team_access_level","guest_invite_management_access_level","html_description","join_request_management_access_level","member_invite_management_access_level","name","organization","organization.name","permalink_url","team_member_removal_access_level","visibility"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a team - api_response = api_instance.create_team(body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TeamsApi->create_team: %s\n" % e) - get_team: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TeamsApi(api_client) - team_gid = '159874' # str | Globally unique identifier for the team. - opt_fields = ["description","edit_team_name_or_description_access_level","edit_team_visibility_or_trash_team_access_level","guest_invite_management_access_level","html_description","join_request_management_access_level","member_invite_management_access_level","name","organization","organization.name","permalink_url","team_member_removal_access_level","visibility"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a team - api_response = api_instance.get_team(team_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TeamsApi->get_team: %s\n" % e) - get_teams_for_user: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TeamsApi(api_client) - user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - organization = '1331' # str | The workspace or organization to filter teams on. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["description","edit_team_name_or_description_access_level","edit_team_visibility_or_trash_team_access_level","guest_invite_management_access_level","html_description","join_request_management_access_level","member_invite_management_access_level","name","offset","organization","organization.name","path","permalink_url","team_member_removal_access_level","uri","visibility"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get teams for a user - api_response = api_instance.get_teams_for_user(user_gid, organization, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TeamsApi->get_teams_for_user: %s\n" % e) - get_teams_for_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TeamsApi(api_client) - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["description","edit_team_name_or_description_access_level","edit_team_visibility_or_trash_team_access_level","guest_invite_management_access_level","html_description","join_request_management_access_level","member_invite_management_access_level","name","offset","organization","organization.name","path","permalink_url","team_member_removal_access_level","uri","visibility"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get teams in a workspace - api_response = api_instance.get_teams_for_workspace(workspace_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TeamsApi->get_teams_for_workspace: %s\n" % e) - remove_user_for_team: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TeamsApi(api_client) - body = asana.TeamGidRemoveUserBody({"param1": "value1", "param2": "value2",}) # TeamGidRemoveUserBody | The user to remove from the team. - team_gid = '159874' # str | Globally unique identifier for the team. - - try: - # Remove a user from a team - api_response = api_instance.remove_user_for_team(body, team_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling TeamsApi->remove_user_for_team: %s\n" % e) - update_team: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TeamsApi(api_client) - body = asana.TeamsTeamGidBody({"param1": "value1", "param2": "value2",}) # TeamsTeamGidBody | The team to update. - team_gid = '159874' # str | Globally unique identifier for the team. - opt_fields = ["description","edit_team_name_or_description_access_level","edit_team_visibility_or_trash_team_access_level","guest_invite_management_access_level","html_description","join_request_management_access_level","member_invite_management_access_level","name","organization","organization.name","permalink_url","team_member_removal_access_level","visibility"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a team - api_response = api_instance.update_team(body, team_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TeamsApi->update_team: %s\n" % e) diff --git a/docs/TeamsBody.md b/docs/TeamsBody.md deleted file mode 100644 index 5d6a1b6b..00000000 --- a/docs/TeamsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TeamsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TeamRequest**](TeamRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TeamsTeamGidBody.md b/docs/TeamsTeamGidBody.md deleted file mode 100644 index b2569554..00000000 --- a/docs/TeamsTeamGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TeamsTeamGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TeamRequest**](TeamRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TemplateRole.md b/docs/TemplateRole.md deleted file mode 100644 index 32d2796f..00000000 --- a/docs/TemplateRole.md +++ /dev/null @@ -1,11 +0,0 @@ -# TemplateRole - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | Name of the template role. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TimePeriodBase.md b/docs/TimePeriodBase.md deleted file mode 100644 index cd75c273..00000000 --- a/docs/TimePeriodBase.md +++ /dev/null @@ -1,15 +0,0 @@ -# TimePeriodBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**end_on** | **str** | The localized end date of the time period in `YYYY-MM-DD` format. | [optional] -**start_on** | **str** | The localized start date of the time period in `YYYY-MM-DD` format. | [optional] -**period** | **str** | The cadence and index of the time period. The value is one of: `FY`, `H1`, `H2`, `Q1`, `Q2`, `Q3`, or `Q4`. | [optional] -**display_name** | **str** | A string representing the cadence code and the fiscal year. | [optional] -**parent** | [**GoalResponseTimePeriod**](GoalResponseTimePeriod.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TimePeriodCompact.md b/docs/TimePeriodCompact.md deleted file mode 100644 index 19bfa1bd..00000000 --- a/docs/TimePeriodCompact.md +++ /dev/null @@ -1,14 +0,0 @@ -# TimePeriodCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**end_on** | **str** | The localized end date of the time period in `YYYY-MM-DD` format. | [optional] -**start_on** | **str** | The localized start date of the time period in `YYYY-MM-DD` format. | [optional] -**period** | **str** | The cadence and index of the time period. The value is one of: `FY`, `H1`, `H2`, `Q1`, `Q2`, `Q3`, or `Q4`. | [optional] -**display_name** | **str** | A string representing the cadence code and the fiscal year. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TimePeriodResponse.md b/docs/TimePeriodResponse.md deleted file mode 100644 index cf3e1614..00000000 --- a/docs/TimePeriodResponse.md +++ /dev/null @@ -1,15 +0,0 @@ -# TimePeriodResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**end_on** | **str** | The localized end date of the time period in `YYYY-MM-DD` format. | [optional] -**start_on** | **str** | The localized start date of the time period in `YYYY-MM-DD` format. | [optional] -**period** | **str** | The cadence and index of the time period. The value is one of: `FY`, `H1`, `H2`, `Q1`, `Q2`, `Q3`, or `Q4`. | [optional] -**display_name** | **str** | A string representing the cadence code and the fiscal year. | [optional] -**parent** | [**GoalResponseTimePeriod**](GoalResponseTimePeriod.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TimePeriodResponseArray.md b/docs/TimePeriodResponseArray.md deleted file mode 100644 index 4de452c7..00000000 --- a/docs/TimePeriodResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# TimePeriodResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[TimePeriodResponse]**](TimePeriodResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TimePeriodResponseData.md b/docs/TimePeriodResponseData.md deleted file mode 100644 index 0447a5d1..00000000 --- a/docs/TimePeriodResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# TimePeriodResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TimePeriodResponse**](TimePeriodResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TimePeriodsApi.md b/docs/TimePeriodsApi.md deleted file mode 100644 index a2962dd1..00000000 --- a/docs/TimePeriodsApi.md +++ /dev/null @@ -1,123 +0,0 @@ -# asana.TimePeriodsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**get_time_period**](TimePeriodsApi.md#get_time_period) | **GET** /time_periods/{time_period_gid} | Get a time period -[**get_time_periods**](TimePeriodsApi.md#get_time_periods) | **GET** /time_periods | Get time periods - -# **get_time_period** -> TimePeriodResponseData get_time_period(time_period_gid, opt_fields=opt_fields) - -Get a time period - -Returns the full record for a single time period. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TimePeriodsApi(api_client) -time_period_gid = '917392' # str | Globally unique identifier for the time period. -opt_fields = ["display_name","end_on","parent","parent.display_name","parent.end_on","parent.period","parent.start_on","period","start_on"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a time period - api_response = api_instance.get_time_period(time_period_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TimePeriodsApi->get_time_period: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **time_period_gid** | **str**| Globally unique identifier for the time period. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TimePeriodResponseData**](TimePeriodResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_time_periods** -> TimePeriodResponseArray get_time_periods(workspace, limit=limit, offset=offset, start_on=start_on, end_on=end_on, opt_fields=opt_fields) - -Get time periods - -Returns compact time period records. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TimePeriodsApi(api_client) -workspace = '31326' # str | Globally unique identifier for the workspace. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -start_on = '2019-09-15' # date | ISO 8601 date string (optional) -end_on = '2019-09-15' # date | ISO 8601 date string (optional) -opt_fields = ["display_name","end_on","offset","parent","parent.display_name","parent.end_on","parent.period","parent.start_on","path","period","start_on","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get time periods - api_response = api_instance.get_time_periods(workspace, limit=limit, offset=offset, start_on=start_on, end_on=end_on, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TimePeriodsApi->get_time_periods: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace** | **str**| Globally unique identifier for the workspace. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **start_on** | **date**| ISO 8601 date string | [optional] - **end_on** | **date**| ISO 8601 date string | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TimePeriodResponseArray**](TimePeriodResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/TimePeriodsApi.yaml b/docs/TimePeriodsApi.yaml deleted file mode 100644 index daeb7ccd..00000000 --- a/docs/TimePeriodsApi.yaml +++ /dev/null @@ -1,47 +0,0 @@ -TimePeriodsApi: - get_time_period: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TimePeriodsApi(api_client) - time_period_gid = '917392' # str | Globally unique identifier for the time period. - opt_fields = ["display_name","end_on","parent","parent.display_name","parent.end_on","parent.period","parent.start_on","period","start_on"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a time period - api_response = api_instance.get_time_period(time_period_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TimePeriodsApi->get_time_period: %s\n" % e) - get_time_periods: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TimePeriodsApi(api_client) - workspace = '31326' # str | Globally unique identifier for the workspace. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - start_on = '2019-09-15' # date | ISO 8601 date string (optional) - end_on = '2019-09-15' # date | ISO 8601 date string (optional) - opt_fields = ["display_name","end_on","offset","parent","parent.display_name","parent.end_on","parent.period","parent.start_on","path","period","start_on","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get time periods - api_response = api_instance.get_time_periods(workspace, limit=limit, offset=offset, start_on=start_on, end_on=end_on, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TimePeriodsApi->get_time_periods: %s\n" % e) diff --git a/docs/TimeTrackingEntriesApi.md b/docs/TimeTrackingEntriesApi.md deleted file mode 100644 index 2fc1aadc..00000000 --- a/docs/TimeTrackingEntriesApi.md +++ /dev/null @@ -1,283 +0,0 @@ -# asana.TimeTrackingEntriesApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_time_tracking_entry**](TimeTrackingEntriesApi.md#create_time_tracking_entry) | **POST** /tasks/{task_gid}/time_tracking_entries | Create a time tracking entry -[**delete_time_tracking_entry**](TimeTrackingEntriesApi.md#delete_time_tracking_entry) | **DELETE** /time_tracking_entries/{time_tracking_entry_gid} | Delete a time tracking entry -[**get_time_tracking_entries_for_task**](TimeTrackingEntriesApi.md#get_time_tracking_entries_for_task) | **GET** /tasks/{task_gid}/time_tracking_entries | Get time tracking entries for a task -[**get_time_tracking_entry**](TimeTrackingEntriesApi.md#get_time_tracking_entry) | **GET** /time_tracking_entries/{time_tracking_entry_gid} | Get a time tracking entry -[**update_time_tracking_entry**](TimeTrackingEntriesApi.md#update_time_tracking_entry) | **PUT** /time_tracking_entries/{time_tracking_entry_gid} | Update a time tracking entry - -# **create_time_tracking_entry** -> TimeTrackingEntryBaseData create_time_tracking_entry(body, task_gid, opt_fields=opt_fields) - -Create a time tracking entry - -Creates a time tracking entry on a given task. Returns the record of the newly created time tracking entry. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TimeTrackingEntriesApi(api_client) -body = asana.TaskGidTimeTrackingEntriesBody({"param1": "value1", "param2": "value2",}) # TaskGidTimeTrackingEntriesBody | Information about the time tracking entry. -task_gid = '321654' # str | The task to operate on. -opt_fields = ["created_at","created_by","created_by.name","duration_minutes","entered_on","task","task.created_by","task.name","task.resource_subtype"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Create a time tracking entry - api_response = api_instance.create_time_tracking_entry(body, task_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TimeTrackingEntriesApi->create_time_tracking_entry: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TaskGidTimeTrackingEntriesBody**](TaskGidTimeTrackingEntriesBody.md)| Information about the time tracking entry. | - **task_gid** | **str**| The task to operate on. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TimeTrackingEntryBaseData**](TimeTrackingEntryBaseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_time_tracking_entry** -> EmptyResponseData delete_time_tracking_entry(time_tracking_entry_gid) - -Delete a time tracking entry - -A specific, existing time tracking entry can be deleted by making a `DELETE` request on the URL for that time tracking entry. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TimeTrackingEntriesApi(api_client) -time_tracking_entry_gid = '917392' # str | Globally unique identifier for the time tracking entry. - -try: - # Delete a time tracking entry - api_response = api_instance.delete_time_tracking_entry(time_tracking_entry_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling TimeTrackingEntriesApi->delete_time_tracking_entry: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **time_tracking_entry_gid** | **str**| Globally unique identifier for the time tracking entry. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_time_tracking_entries_for_task** -> TimeTrackingEntryCompactArray get_time_tracking_entries_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get time tracking entries for a task - -Returns time tracking entries for a given task. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TimeTrackingEntriesApi(api_client) -task_gid = '321654' # str | The task to operate on. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["created_by","created_by.name","duration_minutes","entered_on","offset","path","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get time tracking entries for a task - api_response = api_instance.get_time_tracking_entries_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TimeTrackingEntriesApi->get_time_tracking_entries_for_task: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **task_gid** | **str**| The task to operate on. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TimeTrackingEntryCompactArray**](TimeTrackingEntryCompactArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_time_tracking_entry** -> TimeTrackingEntryBaseData get_time_tracking_entry(time_tracking_entry_gid, opt_fields=opt_fields) - -Get a time tracking entry - -Returns the complete time tracking entry record for a single time tracking entry. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TimeTrackingEntriesApi(api_client) -time_tracking_entry_gid = '917392' # str | Globally unique identifier for the time tracking entry. -opt_fields = ["created_at","created_by","created_by.name","duration_minutes","entered_on","task","task.created_by","task.name","task.resource_subtype"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a time tracking entry - api_response = api_instance.get_time_tracking_entry(time_tracking_entry_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TimeTrackingEntriesApi->get_time_tracking_entry: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **time_tracking_entry_gid** | **str**| Globally unique identifier for the time tracking entry. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TimeTrackingEntryBaseData**](TimeTrackingEntryBaseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_time_tracking_entry** -> TimeTrackingEntryBaseData update_time_tracking_entry(body, time_tracking_entry_gid, opt_fields=opt_fields) - -Update a time tracking entry - -A specific, existing time tracking entry can be updated by making a `PUT` request on the URL for that time tracking entry. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. When using this method, it is best to specify only those fields you wish to change, or else you may overwrite changes made by another user since you last retrieved the task. Returns the complete updated time tracking entry record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TimeTrackingEntriesApi(api_client) -body = asana.TimeTrackingEntriesTimeTrackingEntryGidBody({"param1": "value1", "param2": "value2",}) # TimeTrackingEntriesTimeTrackingEntryGidBody | The updated fields for the time tracking entry. -time_tracking_entry_gid = '917392' # str | Globally unique identifier for the time tracking entry. -opt_fields = ["created_at","created_by","created_by.name","duration_minutes","entered_on","task","task.created_by","task.name","task.resource_subtype"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a time tracking entry - api_response = api_instance.update_time_tracking_entry(body, time_tracking_entry_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TimeTrackingEntriesApi->update_time_tracking_entry: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**TimeTrackingEntriesTimeTrackingEntryGidBody**](TimeTrackingEntriesTimeTrackingEntryGidBody.md)| The updated fields for the time tracking entry. | - **time_tracking_entry_gid** | **str**| Globally unique identifier for the time tracking entry. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**TimeTrackingEntryBaseData**](TimeTrackingEntryBaseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/TimeTrackingEntriesApi.yaml b/docs/TimeTrackingEntriesApi.yaml deleted file mode 100644 index c5180365..00000000 --- a/docs/TimeTrackingEntriesApi.yaml +++ /dev/null @@ -1,109 +0,0 @@ -TimeTrackingEntriesApi: - create_time_tracking_entry: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TimeTrackingEntriesApi(api_client) - body = asana.TaskGidTimeTrackingEntriesBody({"param1": "value1", "param2": "value2",}) # TaskGidTimeTrackingEntriesBody | Information about the time tracking entry. - task_gid = '321654' # str | The task to operate on. - opt_fields = ["created_at","created_by","created_by.name","duration_minutes","entered_on","task","task.created_by","task.name","task.resource_subtype"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Create a time tracking entry - api_response = api_instance.create_time_tracking_entry(body, task_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TimeTrackingEntriesApi->create_time_tracking_entry: %s\n" % e) - delete_time_tracking_entry: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TimeTrackingEntriesApi(api_client) - time_tracking_entry_gid = '917392' # str | Globally unique identifier for the time tracking entry. - - try: - # Delete a time tracking entry - api_response = api_instance.delete_time_tracking_entry(time_tracking_entry_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling TimeTrackingEntriesApi->delete_time_tracking_entry: %s\n" % e) - get_time_tracking_entries_for_task: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TimeTrackingEntriesApi(api_client) - task_gid = '321654' # str | The task to operate on. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["created_by","created_by.name","duration_minutes","entered_on","offset","path","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get time tracking entries for a task - api_response = api_instance.get_time_tracking_entries_for_task(task_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TimeTrackingEntriesApi->get_time_tracking_entries_for_task: %s\n" % e) - get_time_tracking_entry: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TimeTrackingEntriesApi(api_client) - time_tracking_entry_gid = '917392' # str | Globally unique identifier for the time tracking entry. - opt_fields = ["created_at","created_by","created_by.name","duration_minutes","entered_on","task","task.created_by","task.name","task.resource_subtype"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a time tracking entry - api_response = api_instance.get_time_tracking_entry(time_tracking_entry_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TimeTrackingEntriesApi->get_time_tracking_entry: %s\n" % e) - update_time_tracking_entry: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TimeTrackingEntriesApi(api_client) - body = asana.TimeTrackingEntriesTimeTrackingEntryGidBody({"param1": "value1", "param2": "value2",}) # TimeTrackingEntriesTimeTrackingEntryGidBody | The updated fields for the time tracking entry. - time_tracking_entry_gid = '917392' # str | Globally unique identifier for the time tracking entry. - opt_fields = ["created_at","created_by","created_by.name","duration_minutes","entered_on","task","task.created_by","task.name","task.resource_subtype"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a time tracking entry - api_response = api_instance.update_time_tracking_entry(body, time_tracking_entry_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TimeTrackingEntriesApi->update_time_tracking_entry: %s\n" % e) diff --git a/docs/TimeTrackingEntriesTimeTrackingEntryGidBody.md b/docs/TimeTrackingEntriesTimeTrackingEntryGidBody.md deleted file mode 100644 index 64ea9606..00000000 --- a/docs/TimeTrackingEntriesTimeTrackingEntryGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# TimeTrackingEntriesTimeTrackingEntryGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**UpdateTimeTrackingEntryRequest**](UpdateTimeTrackingEntryRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TimeTrackingEntryBase.md b/docs/TimeTrackingEntryBase.md deleted file mode 100644 index 458de70f..00000000 --- a/docs/TimeTrackingEntryBase.md +++ /dev/null @@ -1,15 +0,0 @@ -# TimeTrackingEntryBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**duration_minutes** | **int** | Time in minutes tracked by the entry. | [optional] -**entered_on** | **date** | The day that this entry is logged on. | [optional] -**created_by** | [**StoryResponseAssignee**](StoryResponseAssignee.md) | | [optional] -**task** | [**StoryResponseTask**](StoryResponseTask.md) | | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TimeTrackingEntryBaseData.md b/docs/TimeTrackingEntryBaseData.md deleted file mode 100644 index df52b924..00000000 --- a/docs/TimeTrackingEntryBaseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# TimeTrackingEntryBaseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TimeTrackingEntryBase**](TimeTrackingEntryBase.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TimeTrackingEntryCompact.md b/docs/TimeTrackingEntryCompact.md deleted file mode 100644 index 6c2a5e50..00000000 --- a/docs/TimeTrackingEntryCompact.md +++ /dev/null @@ -1,13 +0,0 @@ -# TimeTrackingEntryCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**duration_minutes** | **int** | Time in minutes tracked by the entry. | [optional] -**entered_on** | **date** | The day that this entry is logged on. | [optional] -**created_by** | [**StoryResponseAssignee**](StoryResponseAssignee.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TimeTrackingEntryCompactArray.md b/docs/TimeTrackingEntryCompactArray.md deleted file mode 100644 index e2d176da..00000000 --- a/docs/TimeTrackingEntryCompactArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# TimeTrackingEntryCompactArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[TimeTrackingEntryCompact]**](TimeTrackingEntryCompact.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/TypeaheadApi.md b/docs/TypeaheadApi.md deleted file mode 100644 index d816ddc4..00000000 --- a/docs/TypeaheadApi.md +++ /dev/null @@ -1,69 +0,0 @@ -# asana.TypeaheadApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**typeahead_for_workspace**](TypeaheadApi.md#typeahead_for_workspace) | **GET** /workspaces/{workspace_gid}/typeahead | Get objects via typeahead - -# **typeahead_for_workspace** -> AsanaNamedResourceArray typeahead_for_workspace(workspace_gid, resource_type, type=type, query=query, count=count, opt_fields=opt_fields) - -Get objects via typeahead - -Retrieves objects in the workspace based via an auto-completion/typeahead search algorithm. This feature is meant to provide results quickly, so do not rely on this API to provide extremely accurate search results. The result set is limited to a single page of results with a maximum size, so you won’t be able to fetch large numbers of results. The typeahead search API provides search for objects from a single workspace. This endpoint should be used to query for objects when creating an auto-completion/typeahead search feature. This API is meant to provide results quickly and should not be relied upon for accurate or exhaustive search results. The results sets are limited in size and cannot be paginated. Queries return a compact representation of each object which is typically the gid and name fields. Interested in a specific set of fields or all of the fields?! Of course you are. Use field selectors to manipulate what data is included in a response. Resources with type `user` are returned in order of most contacted to least contacted. This is determined by task assignments, adding the user to projects, and adding the user as a follower to tasks, messages, etc. Resources with type `project` are returned in order of recency. This is determined when the user visits the project, is added to the project, and completes tasks in the project. Resources with type `task` are returned with priority placed on tasks the user is following, but no guarantee on the order of those tasks. Resources with type `project_template` are returned with priority placed on favorited project templates. Leaving the `query` string empty or omitted will give you results, still following the resource ordering above. This could be used to list users or projects that are relevant for the requesting user's api token. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.TypeaheadApi(api_client) -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -resource_type = 'user' # str | The type of values the typeahead should return. You can choose from one of the following: `custom_field`, `project`, `project_template`, `portfolio`, `tag`, `task`, and `user`. Note that unlike in the names of endpoints, the types listed here are in singular form (e.g. `task`). Using multiple types is not yet supported. (default to user) -type = 'user' # str | *Deprecated: new integrations should prefer the resource_type field.* (optional) (default to user) -query = 'Greg' # str | The string that will be used to search for relevant objects. If an empty string is passed in, the API will return results. (optional) -count = 20 # int | The number of results to return. The default is 20 if this parameter is omitted, with a minimum of 1 and a maximum of 100. If there are fewer results found than requested, all will be returned. (optional) -opt_fields = ["name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get objects via typeahead - api_response = api_instance.typeahead_for_workspace(workspace_gid, resource_type, type=type, query=query, count=count, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling TypeaheadApi->typeahead_for_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **resource_type** | **str**| The type of values the typeahead should return. You can choose from one of the following: `custom_field`, `project`, `project_template`, `portfolio`, `tag`, `task`, and `user`. Note that unlike in the names of endpoints, the types listed here are in singular form (e.g. `task`). Using multiple types is not yet supported. | [default to user] - **type** | **str**| *Deprecated: new integrations should prefer the resource_type field.* | [optional] [default to user] - **query** | **str**| The string that will be used to search for relevant objects. If an empty string is passed in, the API will return results. | [optional] - **count** | **int**| The number of results to return. The default is 20 if this parameter is omitted, with a minimum of 1 and a maximum of 100. If there are fewer results found than requested, all will be returned. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**AsanaNamedResourceArray**](AsanaNamedResourceArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/TypeaheadApi.yaml b/docs/TypeaheadApi.yaml deleted file mode 100644 index d158560f..00000000 --- a/docs/TypeaheadApi.yaml +++ /dev/null @@ -1,26 +0,0 @@ -TypeaheadApi: - typeahead_for_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.TypeaheadApi(api_client) - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - resource_type = 'user' # str | The type of values the typeahead should return. You can choose from one of the following: `custom_field`, `project`, `project_template`, `portfolio`, `tag`, `task`, and `user`. Note that unlike in the names of endpoints, the types listed here are in singular form (e.g. `task`). Using multiple types is not yet supported. (default to user) - type = 'user' # str | *Deprecated: new integrations should prefer the resource_type field.* (optional) (default to user) - query = 'Greg' # str | The string that will be used to search for relevant objects. If an empty string is passed in, the API will return results. (optional) - count = 20 # int | The number of results to return. The default is 20 if this parameter is omitted, with a minimum of 1 and a maximum of 100. If there are fewer results found than requested, all will be returned. (optional) - opt_fields = ["name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get objects via typeahead - api_response = api_instance.typeahead_for_workspace(workspace_gid, resource_type, type=type, query=query, count=count, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling TypeaheadApi->typeahead_for_workspace: %s\n" % e) diff --git a/docs/UpdateTimeTrackingEntryRequest.md b/docs/UpdateTimeTrackingEntryRequest.md deleted file mode 100644 index dd926ae7..00000000 --- a/docs/UpdateTimeTrackingEntryRequest.md +++ /dev/null @@ -1,10 +0,0 @@ -# UpdateTimeTrackingEntryRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**duration_minutes** | **int** | *Optional*. Time in minutes tracked by the entry | [optional] -**entered_on** | **date** | *Optional*. The day that this entry is logged on. Defaults to today if no day specified | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserBase.md b/docs/UserBase.md deleted file mode 100644 index 329200ef..00000000 --- a/docs/UserBase.md +++ /dev/null @@ -1,11 +0,0 @@ -# UserBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | *Read-only except when same user as requester*. The user’s name. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserBaseResponse.md b/docs/UserBaseResponse.md deleted file mode 100644 index 065c9ee6..00000000 --- a/docs/UserBaseResponse.md +++ /dev/null @@ -1,13 +0,0 @@ -# UserBaseResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | *Read-only except when same user as requester*. The user’s name. | [optional] -**email** | **str** | The user's email address. | [optional] -**photo** | [**UserBaseResponsePhoto**](UserBaseResponsePhoto.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserBaseResponseData.md b/docs/UserBaseResponseData.md deleted file mode 100644 index 19f76922..00000000 --- a/docs/UserBaseResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# UserBaseResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**UserBaseResponse**](UserBaseResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserBaseResponsePhoto.md b/docs/UserBaseResponsePhoto.md deleted file mode 100644 index bb48a3c1..00000000 --- a/docs/UserBaseResponsePhoto.md +++ /dev/null @@ -1,14 +0,0 @@ -# UserBaseResponsePhoto - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**image_21x21** | **str** | | [optional] -**image_27x27** | **str** | | [optional] -**image_36x36** | **str** | | [optional] -**image_60x60** | **str** | | [optional] -**image_128x128** | **str** | | [optional] -**image_1024x1024** | **str** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserCompact.md b/docs/UserCompact.md deleted file mode 100644 index c1627fba..00000000 --- a/docs/UserCompact.md +++ /dev/null @@ -1,11 +0,0 @@ -# UserCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | *Read-only except when same user as requester*. The user’s name. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserRequest.md b/docs/UserRequest.md deleted file mode 100644 index af24808f..00000000 --- a/docs/UserRequest.md +++ /dev/null @@ -1,11 +0,0 @@ -# UserRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | *Read-only except when same user as requester*. The user’s name. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserResponse.md b/docs/UserResponse.md deleted file mode 100644 index 2058617e..00000000 --- a/docs/UserResponse.md +++ /dev/null @@ -1,14 +0,0 @@ -# UserResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | *Read-only except when same user as requester*. The user’s name. | [optional] -**email** | **str** | The user's email address. | [optional] -**photo** | [**UserBaseResponsePhoto**](UserBaseResponsePhoto.md) | | [optional] -**workspaces** | [**list[GoalResponseWorkspace]**](GoalResponseWorkspace.md) | Workspaces and organizations this user may access. Note\\: The API will only return workspaces and organizations that also contain the authenticated user. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserResponseArray.md b/docs/UserResponseArray.md deleted file mode 100644 index 995393bb..00000000 --- a/docs/UserResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# UserResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[UserResponse]**](UserResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserResponseData.md b/docs/UserResponseData.md deleted file mode 100644 index efa5a307..00000000 --- a/docs/UserResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# UserResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**UserResponse**](UserResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserTaskListBase.md b/docs/UserTaskListBase.md deleted file mode 100644 index d9a152de..00000000 --- a/docs/UserTaskListBase.md +++ /dev/null @@ -1,13 +0,0 @@ -# UserTaskListBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the user task list. | [optional] -**owner** | **AllOfUserTaskListBaseOwner** | The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. | [optional] -**workspace** | **AllOfUserTaskListBaseWorkspace** | The workspace in which the user task list is located. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserTaskListCompact.md b/docs/UserTaskListCompact.md deleted file mode 100644 index 29cb8aa1..00000000 --- a/docs/UserTaskListCompact.md +++ /dev/null @@ -1,13 +0,0 @@ -# UserTaskListCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the user task list. | [optional] -**owner** | **AllOfUserTaskListCompactOwner** | The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. | [optional] -**workspace** | **AllOfUserTaskListCompactWorkspace** | The workspace in which the user task list is located. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserTaskListRequest.md b/docs/UserTaskListRequest.md deleted file mode 100644 index 46655a8b..00000000 --- a/docs/UserTaskListRequest.md +++ /dev/null @@ -1,13 +0,0 @@ -# UserTaskListRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the user task list. | [optional] -**owner** | **AllOfUserTaskListRequestOwner** | The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. | [optional] -**workspace** | **AllOfUserTaskListRequestWorkspace** | The workspace in which the user task list is located. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserTaskListResponse.md b/docs/UserTaskListResponse.md deleted file mode 100644 index 3daaa730..00000000 --- a/docs/UserTaskListResponse.md +++ /dev/null @@ -1,13 +0,0 @@ -# UserTaskListResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the user task list. | [optional] -**owner** | **AllOfUserTaskListResponseOwner** | The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. | [optional] -**workspace** | **AllOfUserTaskListResponseWorkspace** | The workspace in which the user task list is located. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserTaskListResponseData.md b/docs/UserTaskListResponseData.md deleted file mode 100644 index 8ac5af34..00000000 --- a/docs/UserTaskListResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# UserTaskListResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**UserTaskListResponse**](UserTaskListResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/UserTaskListsApi.md b/docs/UserTaskListsApi.md deleted file mode 100644 index 38381d32..00000000 --- a/docs/UserTaskListsApi.md +++ /dev/null @@ -1,117 +0,0 @@ -# asana.UserTaskListsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**get_user_task_list**](UserTaskListsApi.md#get_user_task_list) | **GET** /user_task_lists/{user_task_list_gid} | Get a user task list -[**get_user_task_list_for_user**](UserTaskListsApi.md#get_user_task_list_for_user) | **GET** /users/{user_gid}/user_task_list | Get a user's task list - -# **get_user_task_list** -> UserTaskListResponseData get_user_task_list(user_task_list_gid, opt_fields=opt_fields) - -Get a user task list - -Returns the full record for a user task list. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.UserTaskListsApi(api_client) -user_task_list_gid = '12345' # str | Globally unique identifier for the user task list. -opt_fields = ["name","owner","workspace"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a user task list - api_response = api_instance.get_user_task_list(user_task_list_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling UserTaskListsApi->get_user_task_list: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user_task_list_gid** | **str**| Globally unique identifier for the user task list. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**UserTaskListResponseData**](UserTaskListResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_user_task_list_for_user** -> UserTaskListResponseData get_user_task_list_for_user(user_gid, workspace, opt_fields=opt_fields) - -Get a user's task list - -Returns the full record for a user's task list. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.UserTaskListsApi(api_client) -user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. -workspace = '1234' # str | The workspace in which to get the user task list. -opt_fields = ["name","owner","workspace"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a user's task list - api_response = api_instance.get_user_task_list_for_user(user_gid, workspace, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling UserTaskListsApi->get_user_task_list_for_user: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user_gid** | **str**| A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | - **workspace** | **str**| The workspace in which to get the user task list. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**UserTaskListResponseData**](UserTaskListResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/UserTaskListsApi.yaml b/docs/UserTaskListsApi.yaml deleted file mode 100644 index 25557436..00000000 --- a/docs/UserTaskListsApi.yaml +++ /dev/null @@ -1,44 +0,0 @@ -UserTaskListsApi: - get_user_task_list: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.UserTaskListsApi(api_client) - user_task_list_gid = '12345' # str | Globally unique identifier for the user task list. - opt_fields = ["name","owner","workspace"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a user task list - api_response = api_instance.get_user_task_list(user_task_list_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling UserTaskListsApi->get_user_task_list: %s\n" % e) - get_user_task_list_for_user: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.UserTaskListsApi(api_client) - user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - workspace = '1234' # str | The workspace in which to get the user task list. - opt_fields = ["name","owner","workspace"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a user's task list - api_response = api_instance.get_user_task_list_for_user(user_gid, workspace, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling UserTaskListsApi->get_user_task_list_for_user: %s\n" % e) diff --git a/docs/UsersApi.md b/docs/UsersApi.md deleted file mode 100644 index ccd10173..00000000 --- a/docs/UsersApi.md +++ /dev/null @@ -1,295 +0,0 @@ -# asana.UsersApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**get_favorites_for_user**](UsersApi.md#get_favorites_for_user) | **GET** /users/{user_gid}/favorites | Get a user's favorites -[**get_user**](UsersApi.md#get_user) | **GET** /users/{user_gid} | Get a user -[**get_users**](UsersApi.md#get_users) | **GET** /users | Get multiple users -[**get_users_for_team**](UsersApi.md#get_users_for_team) | **GET** /teams/{team_gid}/users | Get users in a team -[**get_users_for_workspace**](UsersApi.md#get_users_for_workspace) | **GET** /workspaces/{workspace_gid}/users | Get users in a workspace or organization - -# **get_favorites_for_user** -> AsanaNamedResourceArray get_favorites_for_user(user_gid, resource_type, workspace, limit=limit, offset=offset, opt_fields=opt_fields) - -Get a user's favorites - -Returns all of a user's favorites in the given workspace, of the given type. Results are given in order (The same order as Asana's sidebar). - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.UsersApi(api_client) -user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. -resource_type = 'project' # str | The resource type of favorites to be returned. (default to project) -workspace = '1234' # str | The workspace in which to get favorites. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["name","offset","path","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a user's favorites - api_response = api_instance.get_favorites_for_user(user_gid, resource_type, workspace, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling UsersApi->get_favorites_for_user: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user_gid** | **str**| A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | - **resource_type** | **str**| The resource type of favorites to be returned. | [default to project] - **workspace** | **str**| The workspace in which to get favorites. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**AsanaNamedResourceArray**](AsanaNamedResourceArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_user** -> UserResponseData get_user(user_gid, opt_fields=opt_fields) - -Get a user - -Returns the full user record for the single user with the provided ID. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.UsersApi(api_client) -user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. -opt_fields = ["email","name","photo","photo.image_1024x1024","photo.image_128x128","photo.image_21x21","photo.image_27x27","photo.image_36x36","photo.image_60x60","workspaces","workspaces.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a user - api_response = api_instance.get_user(user_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling UsersApi->get_user: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user_gid** | **str**| A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**UserResponseData**](UserResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_users** -> UserResponseArray get_users(workspace=workspace, team=team, limit=limit, offset=offset, opt_fields=opt_fields) - -Get multiple users - -Returns the user records for all users in all workspaces and organizations accessible to the authenticated user. Accepts an optional workspace ID parameter. Results are sorted by user ID. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.UsersApi(api_client) -workspace = '1331' # str | The workspace or organization ID to filter users on. (optional) -team = '15627' # str | The team ID to filter users on. (optional) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["email","name","offset","path","photo","photo.image_1024x1024","photo.image_128x128","photo.image_21x21","photo.image_27x27","photo.image_36x36","photo.image_60x60","uri","workspaces","workspaces.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get multiple users - api_response = api_instance.get_users(workspace=workspace, team=team, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling UsersApi->get_users: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace** | **str**| The workspace or organization ID to filter users on. | [optional] - **team** | **str**| The team ID to filter users on. | [optional] - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**UserResponseArray**](UserResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_users_for_team** -> UserResponseArray get_users_for_team(team_gid, offset=offset, opt_fields=opt_fields) - -Get users in a team - -Returns the compact records for all users that are members of the team. Results are sorted alphabetically and limited to 2000. For more results use the `/users` endpoint. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.UsersApi(api_client) -team_gid = '159874' # str | Globally unique identifier for the team. -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["email","name","photo","photo.image_1024x1024","photo.image_128x128","photo.image_21x21","photo.image_27x27","photo.image_36x36","photo.image_60x60","workspaces","workspaces.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get users in a team - api_response = api_instance.get_users_for_team(team_gid, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling UsersApi->get_users_for_team: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **team_gid** | **str**| Globally unique identifier for the team. | - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**UserResponseArray**](UserResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_users_for_workspace** -> UserResponseArray get_users_for_workspace(workspace_gid, offset=offset, opt_fields=opt_fields) - -Get users in a workspace or organization - -Returns the compact records for all users in the specified workspace or organization. Results are sorted alphabetically and limited to 2000. For more results use the `/users` endpoint. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.UsersApi(api_client) -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["email","name","photo","photo.image_1024x1024","photo.image_128x128","photo.image_21x21","photo.image_27x27","photo.image_36x36","photo.image_60x60","workspaces","workspaces.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get users in a workspace or organization - api_response = api_instance.get_users_for_workspace(workspace_gid, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling UsersApi->get_users_for_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**UserResponseArray**](UserResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/UsersApi.yaml b/docs/UsersApi.yaml deleted file mode 100644 index 715f26b1..00000000 --- a/docs/UsersApi.yaml +++ /dev/null @@ -1,115 +0,0 @@ -UsersApi: - get_favorites_for_user: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.UsersApi(api_client) - user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - resource_type = 'project' # str | The resource type of favorites to be returned. (default to project) - workspace = '1234' # str | The workspace in which to get favorites. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["name","offset","path","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a user's favorites - api_response = api_instance.get_favorites_for_user(user_gid, resource_type, workspace, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling UsersApi->get_favorites_for_user: %s\n" % e) - get_user: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.UsersApi(api_client) - user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - opt_fields = ["email","name","photo","photo.image_1024x1024","photo.image_128x128","photo.image_21x21","photo.image_27x27","photo.image_36x36","photo.image_60x60","workspaces","workspaces.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a user - api_response = api_instance.get_user(user_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling UsersApi->get_user: %s\n" % e) - get_users: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.UsersApi(api_client) - workspace = '1331' # str | The workspace or organization ID to filter users on. (optional) - team = '15627' # str | The team ID to filter users on. (optional) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["email","name","offset","path","photo","photo.image_1024x1024","photo.image_128x128","photo.image_21x21","photo.image_27x27","photo.image_36x36","photo.image_60x60","uri","workspaces","workspaces.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get multiple users - api_response = api_instance.get_users(workspace=workspace, team=team, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling UsersApi->get_users: %s\n" % e) - get_users_for_team: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.UsersApi(api_client) - team_gid = '159874' # str | Globally unique identifier for the team. - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["email","name","photo","photo.image_1024x1024","photo.image_128x128","photo.image_21x21","photo.image_27x27","photo.image_36x36","photo.image_60x60","workspaces","workspaces.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get users in a team - api_response = api_instance.get_users_for_team(team_gid, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling UsersApi->get_users_for_team: %s\n" % e) - get_users_for_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.UsersApi(api_client) - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["email","name","photo","photo.image_1024x1024","photo.image_128x128","photo.image_21x21","photo.image_27x27","photo.image_36x36","photo.image_60x60","workspaces","workspaces.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get users in a workspace or organization - api_response = api_instance.get_users_for_workspace(workspace_gid, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling UsersApi->get_users_for_workspace: %s\n" % e) diff --git a/docs/WebhookCompact.md b/docs/WebhookCompact.md deleted file mode 100644 index 2c604922..00000000 --- a/docs/WebhookCompact.md +++ /dev/null @@ -1,13 +0,0 @@ -# WebhookCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**active** | **bool** | If true, the webhook will send events - if false it is considered inactive and will not generate events. | [optional] -**resource** | [**WebhookCompactResource**](WebhookCompactResource.md) | | [optional] -**target** | **str** | The URL to receive the HTTP POST. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WebhookCompactResource.md b/docs/WebhookCompactResource.md deleted file mode 100644 index 6b3e5f68..00000000 --- a/docs/WebhookCompactResource.md +++ /dev/null @@ -1,11 +0,0 @@ -# WebhookCompactResource - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the object. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WebhookFilter.md b/docs/WebhookFilter.md deleted file mode 100644 index 4e662871..00000000 --- a/docs/WebhookFilter.md +++ /dev/null @@ -1,12 +0,0 @@ -# WebhookFilter - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**resource_type** | **str** | The type of the resource which created the event when modified; for example, to filter to changes on regular tasks this field should be set to `task`. | [optional] -**resource_subtype** | **str** | The resource subtype of the resource that the filter applies to. This should be set to the same value as is returned on the `resource_subtype` field on the resources themselves. | [optional] -**action** | **str** | The type of change on the **resource** to pass through the filter. For more information refer to `Event.action` in the [event](/reference/events) schema. This can be one of `changed`, `added`, `removed`, `deleted`, and `undeleted` depending on the nature of what has occurred on the resource. | [optional] -**fields** | **list[str]** | *Conditional.* A whitelist of fields for events which will pass the filter when the resource is changed. These can be any combination of the fields on the resources themselves. This field is only valid for `action` of type `changed` | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WebhookRequest.md b/docs/WebhookRequest.md deleted file mode 100644 index 05a76123..00000000 --- a/docs/WebhookRequest.md +++ /dev/null @@ -1,11 +0,0 @@ -# WebhookRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**resource** | **str** | A resource ID to subscribe to. Many Asana resources are valid to create webhooks on, but higher-level resources require filters. | -**target** | **str** | The URL to receive the HTTP POST. The full URL will be used to deliver events from this webhook (including parameters) which allows encoding of application-specific state when the webhook is created. | -**filters** | [**list[WebhookRequestFilters]**](WebhookRequestFilters.md) | An array of WebhookFilter objects to specify a whitelist of filters to apply to events from this webhook. If a webhook event passes any of the filters the event will be delivered; otherwise no event will be sent to the receiving server. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WebhookRequestFilters.md b/docs/WebhookRequestFilters.md deleted file mode 100644 index 23d6eb2c..00000000 --- a/docs/WebhookRequestFilters.md +++ /dev/null @@ -1,12 +0,0 @@ -# WebhookRequestFilters - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**resource_type** | **str** | The type of the resource which created the event when modified; for example, to filter to changes on regular tasks this field should be set to `task`. | [optional] -**resource_subtype** | **str** | The resource subtype of the resource that the filter applies to. This should be set to the same value as is returned on the `resource_subtype` field on the resources themselves. | [optional] -**action** | **str** | The type of change on the **resource** to pass through the filter. For more information refer to `Event.action` in the [event](/reference/events) schema. This can be one of `changed`, `added`, `removed`, `deleted`, and `undeleted` depending on the nature of what has occurred on the resource. | [optional] -**fields** | **list[str]** | *Conditional.* A whitelist of fields for events which will pass the filter when the resource is changed. These can be any combination of the fields on the resources themselves. This field is only valid for `action` of type `changed` | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WebhookResponse.md b/docs/WebhookResponse.md deleted file mode 100644 index 9572e27c..00000000 --- a/docs/WebhookResponse.md +++ /dev/null @@ -1,18 +0,0 @@ -# WebhookResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**active** | **bool** | If true, the webhook will send events - if false it is considered inactive and will not generate events. | [optional] -**resource** | [**WebhookCompactResource**](WebhookCompactResource.md) | | [optional] -**target** | **str** | The URL to receive the HTTP POST. | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] -**last_failure_at** | **datetime** | The timestamp when the webhook last received an error when sending an event to the target. | [optional] -**last_failure_content** | **str** | The contents of the last error response sent to the webhook when attempting to deliver events to the target. | [optional] -**last_success_at** | **datetime** | The timestamp when the webhook last successfully sent an event to the target. | [optional] -**filters** | [**list[WebhookRequestFilters]**](WebhookRequestFilters.md) | Whitelist of filters to apply to events from this webhook. If a webhook event passes any of the filters the event will be delivered; otherwise no event will be sent to the receiving server. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WebhookResponseArray.md b/docs/WebhookResponseArray.md deleted file mode 100644 index 0ca192fe..00000000 --- a/docs/WebhookResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# WebhookResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[WebhookResponse]**](WebhookResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WebhookResponseData.md b/docs/WebhookResponseData.md deleted file mode 100644 index 5dd9923e..00000000 --- a/docs/WebhookResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# WebhookResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**WebhookResponse**](WebhookResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WebhookUpdateRequest.md b/docs/WebhookUpdateRequest.md deleted file mode 100644 index 287196ce..00000000 --- a/docs/WebhookUpdateRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# WebhookUpdateRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**filters** | [**list[WebhookRequestFilters]**](WebhookRequestFilters.md) | An array of WebhookFilter objects to specify a whitelist of filters to apply to events from this webhook. If a webhook event passes any of the filters the event will be delivered; otherwise no event will be sent to the receiving server. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WebhooksApi.md b/docs/WebhooksApi.md deleted file mode 100644 index 947c2a58..00000000 --- a/docs/WebhooksApi.md +++ /dev/null @@ -1,283 +0,0 @@ -# asana.WebhooksApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_webhook**](WebhooksApi.md#create_webhook) | **POST** /webhooks | Establish a webhook -[**delete_webhook**](WebhooksApi.md#delete_webhook) | **DELETE** /webhooks/{webhook_gid} | Delete a webhook -[**get_webhook**](WebhooksApi.md#get_webhook) | **GET** /webhooks/{webhook_gid} | Get a webhook -[**get_webhooks**](WebhooksApi.md#get_webhooks) | **GET** /webhooks | Get multiple webhooks -[**update_webhook**](WebhooksApi.md#update_webhook) | **PUT** /webhooks/{webhook_gid} | Update a webhook - -# **create_webhook** -> WebhookResponseData create_webhook(body, opt_fields=opt_fields) - -Establish a webhook - -Establishing a webhook is a two-part process. First, a simple HTTP POST request initiates the creation similar to creating any other resource. Next, in the middle of this request comes the confirmation handshake. When a webhook is created, we will send a test POST to the target with an `X-Hook-Secret` header. The target must respond with a `200 OK` or `204 No Content` and a matching `X-Hook-Secret` header to confirm that this webhook subscription is indeed expected. We strongly recommend storing this secret to be used to verify future webhook event signatures. The POST request to create the webhook will then return with the status of the request. If you do not acknowledge the webhook’s confirmation handshake it will fail to setup, and you will receive an error in response to your attempt to create it. This means you need to be able to receive and complete the webhook *while* the POST request is in-flight (in other words, have a server that can handle requests asynchronously). Invalid hostnames like localhost will recieve a 403 Forbidden status code. ``` # Request curl -H \"Authorization: Bearer \" \\ -X POST https://app.asana.com/api/1.0/webhooks \\ -d \"resource=8675309\" \\ -d \"target=https://example.com/receive-webhook/7654\" ``` ``` # Handshake sent to https://example.com/ POST /receive-webhook/7654 X-Hook-Secret: b537207f20cbfa02357cf448134da559e8bd39d61597dcd5631b8012eae53e81 ``` ``` # Handshake response sent by example.com HTTP/1.1 200 X-Hook-Secret: b537207f20cbfa02357cf448134da559e8bd39d61597dcd5631b8012eae53e81 ``` ``` # Response HTTP/1.1 201 { \"data\": { \"gid\": \"43214\", \"resource\": { \"gid\": \"8675309\", \"name\": \"Bugs\" }, \"target\": \"https://example.com/receive-webhook/7654\", \"active\": false, \"last_success_at\": null, \"last_failure_at\": null, \"last_failure_content\": null } } ``` - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.WebhooksApi(api_client) -body = asana.WebhooksBody({"param1": "value1", "param2": "value2",}) # WebhooksBody | The webhook workspace and target. -opt_fields = ["active","created_at","filters","filters.action","filters.fields","filters.resource_subtype","last_failure_at","last_failure_content","last_success_at","resource","resource.name","target"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Establish a webhook - api_response = api_instance.create_webhook(body, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling WebhooksApi->create_webhook: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**WebhooksBody**](WebhooksBody.md)| The webhook workspace and target. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**WebhookResponseData**](WebhookResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **delete_webhook** -> EmptyResponseData delete_webhook(webhook_gid) - -Delete a webhook - -This method *permanently* removes a webhook. Note that it may be possible to receive a request that was already in flight after deleting the webhook, but no further requests will be issued. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.WebhooksApi(api_client) -webhook_gid = '12345' # str | Globally unique identifier for the webhook. - -try: - # Delete a webhook - api_response = api_instance.delete_webhook(webhook_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling WebhooksApi->delete_webhook: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **webhook_gid** | **str**| Globally unique identifier for the webhook. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_webhook** -> WebhookResponseData get_webhook(webhook_gid, opt_fields=opt_fields) - -Get a webhook - -Returns the full record for the given webhook. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.WebhooksApi(api_client) -webhook_gid = '12345' # str | Globally unique identifier for the webhook. -opt_fields = ["active","created_at","filters","filters.action","filters.fields","filters.resource_subtype","last_failure_at","last_failure_content","last_success_at","resource","resource.name","target"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a webhook - api_response = api_instance.get_webhook(webhook_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling WebhooksApi->get_webhook: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **webhook_gid** | **str**| Globally unique identifier for the webhook. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**WebhookResponseData**](WebhookResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_webhooks** -> WebhookResponseArray get_webhooks(workspace, limit=limit, offset=offset, resource=resource, opt_fields=opt_fields) - -Get multiple webhooks - -Get the compact representation of all webhooks your app has registered for the authenticated user in the given workspace. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.WebhooksApi(api_client) -workspace = '1331' # str | The workspace to query for webhooks in. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -resource = '51648' # str | Only return webhooks for the given resource. (optional) -opt_fields = ["active","created_at","filters","filters.action","filters.fields","filters.resource_subtype","last_failure_at","last_failure_content","last_success_at","offset","path","resource","resource.name","target","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get multiple webhooks - api_response = api_instance.get_webhooks(workspace, limit=limit, offset=offset, resource=resource, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling WebhooksApi->get_webhooks: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace** | **str**| The workspace to query for webhooks in. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **resource** | **str**| Only return webhooks for the given resource. | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**WebhookResponseArray**](WebhookResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_webhook** -> WebhookResponseData update_webhook(body, webhook_gid, opt_fields=opt_fields) - -Update a webhook - -An existing webhook's filters can be updated by making a PUT request on the URL for that webhook. Note that the webhook's previous `filters` array will be completely overwritten by the `filters` sent in the PUT request. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.WebhooksApi(api_client) -body = asana.WebhooksWebhookGidBody({"param1": "value1", "param2": "value2",}) # WebhooksWebhookGidBody | The updated filters for the webhook. -webhook_gid = '12345' # str | Globally unique identifier for the webhook. -opt_fields = ["active","created_at","filters","filters.action","filters.fields","filters.resource_subtype","last_failure_at","last_failure_content","last_success_at","resource","resource.name","target"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a webhook - api_response = api_instance.update_webhook(body, webhook_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling WebhooksApi->update_webhook: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**WebhooksWebhookGidBody**](WebhooksWebhookGidBody.md)| The updated filters for the webhook. | - **webhook_gid** | **str**| Globally unique identifier for the webhook. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**WebhookResponseData**](WebhookResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/WebhooksApi.yaml b/docs/WebhooksApi.yaml deleted file mode 100644 index 9b8fd4ff..00000000 --- a/docs/WebhooksApi.yaml +++ /dev/null @@ -1,109 +0,0 @@ -WebhooksApi: - create_webhook: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.WebhooksApi(api_client) - body = asana.WebhooksBody({"param1": "value1", "param2": "value2",}) # WebhooksBody | The webhook workspace and target. - opt_fields = ["active","created_at","filters","filters.action","filters.fields","filters.resource_subtype","last_failure_at","last_failure_content","last_success_at","resource","resource.name","target"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Establish a webhook - api_response = api_instance.create_webhook(body, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling WebhooksApi->create_webhook: %s\n" % e) - delete_webhook: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.WebhooksApi(api_client) - webhook_gid = '12345' # str | Globally unique identifier for the webhook. - - try: - # Delete a webhook - api_response = api_instance.delete_webhook(webhook_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling WebhooksApi->delete_webhook: %s\n" % e) - get_webhook: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.WebhooksApi(api_client) - webhook_gid = '12345' # str | Globally unique identifier for the webhook. - opt_fields = ["active","created_at","filters","filters.action","filters.fields","filters.resource_subtype","last_failure_at","last_failure_content","last_success_at","resource","resource.name","target"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a webhook - api_response = api_instance.get_webhook(webhook_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling WebhooksApi->get_webhook: %s\n" % e) - get_webhooks: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.WebhooksApi(api_client) - workspace = '1331' # str | The workspace to query for webhooks in. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - resource = '51648' # str | Only return webhooks for the given resource. (optional) - opt_fields = ["active","created_at","filters","filters.action","filters.fields","filters.resource_subtype","last_failure_at","last_failure_content","last_success_at","offset","path","resource","resource.name","target","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get multiple webhooks - api_response = api_instance.get_webhooks(workspace, limit=limit, offset=offset, resource=resource, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling WebhooksApi->get_webhooks: %s\n" % e) - update_webhook: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.WebhooksApi(api_client) - body = asana.WebhooksWebhookGidBody({"param1": "value1", "param2": "value2",}) # WebhooksWebhookGidBody | The updated filters for the webhook. - webhook_gid = '12345' # str | Globally unique identifier for the webhook. - opt_fields = ["active","created_at","filters","filters.action","filters.fields","filters.resource_subtype","last_failure_at","last_failure_content","last_success_at","resource","resource.name","target"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a webhook - api_response = api_instance.update_webhook(body, webhook_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling WebhooksApi->update_webhook: %s\n" % e) diff --git a/docs/WebhooksBody.md b/docs/WebhooksBody.md deleted file mode 100644 index f15f48e6..00000000 --- a/docs/WebhooksBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# WebhooksBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**WebhookRequest**](WebhookRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WebhooksWebhookGidBody.md b/docs/WebhooksWebhookGidBody.md deleted file mode 100644 index f2470fe5..00000000 --- a/docs/WebhooksWebhookGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# WebhooksWebhookGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**WebhookUpdateRequest**](WebhookUpdateRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceAddUserRequest.md b/docs/WorkspaceAddUserRequest.md deleted file mode 100644 index 60f374e5..00000000 --- a/docs/WorkspaceAddUserRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# WorkspaceAddUserRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**user** | **str** | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceBase.md b/docs/WorkspaceBase.md deleted file mode 100644 index 9f36e658..00000000 --- a/docs/WorkspaceBase.md +++ /dev/null @@ -1,11 +0,0 @@ -# WorkspaceBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the workspace. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceCompact.md b/docs/WorkspaceCompact.md deleted file mode 100644 index 6cc63236..00000000 --- a/docs/WorkspaceCompact.md +++ /dev/null @@ -1,11 +0,0 @@ -# WorkspaceCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the workspace. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceGidAddUserBody.md b/docs/WorkspaceGidAddUserBody.md deleted file mode 100644 index b12f8ef3..00000000 --- a/docs/WorkspaceGidAddUserBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# WorkspaceGidAddUserBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**WorkspaceAddUserRequest**](WorkspaceAddUserRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceGidProjectsBody.md b/docs/WorkspaceGidProjectsBody.md deleted file mode 100644 index 1cf3ff69..00000000 --- a/docs/WorkspaceGidProjectsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# WorkspaceGidProjectsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**ProjectRequest**](ProjectRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceGidRemoveUserBody.md b/docs/WorkspaceGidRemoveUserBody.md deleted file mode 100644 index a3e5e918..00000000 --- a/docs/WorkspaceGidRemoveUserBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# WorkspaceGidRemoveUserBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**WorkspaceRemoveUserRequest**](WorkspaceRemoveUserRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceGidTagsBody.md b/docs/WorkspaceGidTagsBody.md deleted file mode 100644 index 128951eb..00000000 --- a/docs/WorkspaceGidTagsBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# WorkspaceGidTagsBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**TagCreateTagForWorkspaceRequest**](TagCreateTagForWorkspaceRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceMembershipBase.md b/docs/WorkspaceMembershipBase.md deleted file mode 100644 index cb4f356f..00000000 --- a/docs/WorkspaceMembershipBase.md +++ /dev/null @@ -1,12 +0,0 @@ -# WorkspaceMembershipBase - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**workspace** | [**GoalResponseWorkspace**](GoalResponseWorkspace.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceMembershipCompact.md b/docs/WorkspaceMembershipCompact.md deleted file mode 100644 index a16178ce..00000000 --- a/docs/WorkspaceMembershipCompact.md +++ /dev/null @@ -1,12 +0,0 @@ -# WorkspaceMembershipCompact - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**workspace** | [**GoalResponseWorkspace**](GoalResponseWorkspace.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceMembershipRequest.md b/docs/WorkspaceMembershipRequest.md deleted file mode 100644 index a64f3cf5..00000000 --- a/docs/WorkspaceMembershipRequest.md +++ /dev/null @@ -1,12 +0,0 @@ -# WorkspaceMembershipRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**workspace** | [**GoalResponseWorkspace**](GoalResponseWorkspace.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceMembershipResponse.md b/docs/WorkspaceMembershipResponse.md deleted file mode 100644 index 22e0241d..00000000 --- a/docs/WorkspaceMembershipResponse.md +++ /dev/null @@ -1,18 +0,0 @@ -# WorkspaceMembershipResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**user** | [**CustomFieldResponsePeopleValue**](CustomFieldResponsePeopleValue.md) | | [optional] -**workspace** | [**GoalResponseWorkspace**](GoalResponseWorkspace.md) | | [optional] -**user_task_list** | [**WorkspaceMembershipResponseUserTaskList**](WorkspaceMembershipResponseUserTaskList.md) | | [optional] -**is_active** | **bool** | Reflects if this user still a member of the workspace. | [optional] -**is_admin** | **bool** | Reflects if this user is an admin of the workspace. | [optional] -**is_guest** | **bool** | Reflects if this user is a guest of the workspace. | [optional] -**vacation_dates** | [**WorkspaceMembershipResponseVacationDates**](WorkspaceMembershipResponseVacationDates.md) | | [optional] -**created_at** | **datetime** | The time at which this resource was created. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceMembershipResponseArray.md b/docs/WorkspaceMembershipResponseArray.md deleted file mode 100644 index 64fd54b4..00000000 --- a/docs/WorkspaceMembershipResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# WorkspaceMembershipResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[WorkspaceMembershipResponse]**](WorkspaceMembershipResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceMembershipResponseData.md b/docs/WorkspaceMembershipResponseData.md deleted file mode 100644 index 37781d1d..00000000 --- a/docs/WorkspaceMembershipResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# WorkspaceMembershipResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**WorkspaceMembershipResponse**](WorkspaceMembershipResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceMembershipResponseUserTaskList.md b/docs/WorkspaceMembershipResponseUserTaskList.md deleted file mode 100644 index e4908e8d..00000000 --- a/docs/WorkspaceMembershipResponseUserTaskList.md +++ /dev/null @@ -1,13 +0,0 @@ -# WorkspaceMembershipResponseUserTaskList - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the user task list. | [optional] -**owner** | **AllOfWorkspaceMembershipResponseUserTaskListOwner** | The owner of the user task list, i.e. the person whose My Tasks is represented by this resource. | [optional] -**workspace** | **AllOfWorkspaceMembershipResponseUserTaskListWorkspace** | The workspace in which the user task list is located. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceMembershipResponseVacationDates.md b/docs/WorkspaceMembershipResponseVacationDates.md deleted file mode 100644 index 054708cc..00000000 --- a/docs/WorkspaceMembershipResponseVacationDates.md +++ /dev/null @@ -1,10 +0,0 @@ -# WorkspaceMembershipResponseVacationDates - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**start_on** | **str** | The day on which the user's vacation in this workspace starts. This is a date with `YYYY-MM-DD` format. | [optional] -**end_on** | **str** | The day on which the user's vacation in this workspace ends, or null if there is no end date. This is a date with `YYYY-MM-DD` format. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceMembershipsApi.md b/docs/WorkspaceMembershipsApi.md deleted file mode 100644 index 5c198601..00000000 --- a/docs/WorkspaceMembershipsApi.md +++ /dev/null @@ -1,179 +0,0 @@ -# asana.WorkspaceMembershipsApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**get_workspace_membership**](WorkspaceMembershipsApi.md#get_workspace_membership) | **GET** /workspace_memberships/{workspace_membership_gid} | Get a workspace membership -[**get_workspace_memberships_for_user**](WorkspaceMembershipsApi.md#get_workspace_memberships_for_user) | **GET** /users/{user_gid}/workspace_memberships | Get workspace memberships for a user -[**get_workspace_memberships_for_workspace**](WorkspaceMembershipsApi.md#get_workspace_memberships_for_workspace) | **GET** /workspaces/{workspace_gid}/workspace_memberships | Get the workspace memberships for a workspace - -# **get_workspace_membership** -> WorkspaceMembershipResponseData get_workspace_membership(workspace_membership_gid, opt_fields=opt_fields) - -Get a workspace membership - -Returns the complete workspace record for a single workspace membership. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.WorkspaceMembershipsApi(api_client) -workspace_membership_gid = '12345' # str | -opt_fields = ["created_at","is_active","is_admin","is_guest","user","user.name","user_task_list","user_task_list.name","user_task_list.owner","user_task_list.workspace","vacation_dates","vacation_dates.end_on","vacation_dates.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a workspace membership - api_response = api_instance.get_workspace_membership(workspace_membership_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling WorkspaceMembershipsApi->get_workspace_membership: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace_membership_gid** | **str**| | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**WorkspaceMembershipResponseData**](WorkspaceMembershipResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_workspace_memberships_for_user** -> WorkspaceMembershipResponseArray get_workspace_memberships_for_user(user_gid, limit=limit, offset=offset, opt_fields=opt_fields) - -Get workspace memberships for a user - -Returns the compact workspace membership records for the user. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.WorkspaceMembershipsApi(api_client) -user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["created_at","is_active","is_admin","is_guest","offset","path","uri","user","user.name","user_task_list","user_task_list.name","user_task_list.owner","user_task_list.workspace","vacation_dates","vacation_dates.end_on","vacation_dates.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get workspace memberships for a user - api_response = api_instance.get_workspace_memberships_for_user(user_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling WorkspaceMembershipsApi->get_workspace_memberships_for_user: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user_gid** | **str**| A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**WorkspaceMembershipResponseArray**](WorkspaceMembershipResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_workspace_memberships_for_workspace** -> WorkspaceMembershipResponseArray get_workspace_memberships_for_workspace(workspace_gid, user=user, limit=limit, offset=offset, opt_fields=opt_fields) - -Get the workspace memberships for a workspace - -Returns the compact workspace membership records for the workspace. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.WorkspaceMembershipsApi(api_client) -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -user = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (optional) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["created_at","is_active","is_admin","is_guest","offset","path","uri","user","user.name","user_task_list","user_task_list.name","user_task_list.owner","user_task_list.workspace","vacation_dates","vacation_dates.end_on","vacation_dates.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get the workspace memberships for a workspace - api_response = api_instance.get_workspace_memberships_for_workspace(workspace_gid, user=user, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling WorkspaceMembershipsApi->get_workspace_memberships_for_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **user** | **str**| A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | [optional] - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**WorkspaceMembershipResponseArray**](WorkspaceMembershipResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceMembershipsApi.yaml b/docs/WorkspaceMembershipsApi.yaml deleted file mode 100644 index 22ac165b..00000000 --- a/docs/WorkspaceMembershipsApi.yaml +++ /dev/null @@ -1,69 +0,0 @@ -WorkspaceMembershipsApi: - get_workspace_membership: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.WorkspaceMembershipsApi(api_client) - workspace_membership_gid = '12345' # str | - opt_fields = ["created_at","is_active","is_admin","is_guest","user","user.name","user_task_list","user_task_list.name","user_task_list.owner","user_task_list.workspace","vacation_dates","vacation_dates.end_on","vacation_dates.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a workspace membership - api_response = api_instance.get_workspace_membership(workspace_membership_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling WorkspaceMembershipsApi->get_workspace_membership: %s\n" % e) - get_workspace_memberships_for_user: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.WorkspaceMembershipsApi(api_client) - user_gid = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["created_at","is_active","is_admin","is_guest","offset","path","uri","user","user.name","user_task_list","user_task_list.name","user_task_list.owner","user_task_list.workspace","vacation_dates","vacation_dates.end_on","vacation_dates.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get workspace memberships for a user - api_response = api_instance.get_workspace_memberships_for_user(user_gid, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling WorkspaceMembershipsApi->get_workspace_memberships_for_user: %s\n" % e) - get_workspace_memberships_for_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.WorkspaceMembershipsApi(api_client) - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - user = 'me' # str | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. (optional) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["created_at","is_active","is_admin","is_guest","offset","path","uri","user","user.name","user_task_list","user_task_list.name","user_task_list.owner","user_task_list.workspace","vacation_dates","vacation_dates.end_on","vacation_dates.start_on","workspace","workspace.name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get the workspace memberships for a workspace - api_response = api_instance.get_workspace_memberships_for_workspace(workspace_gid, user=user, limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling WorkspaceMembershipsApi->get_workspace_memberships_for_workspace: %s\n" % e) diff --git a/docs/WorkspaceRemoveUserRequest.md b/docs/WorkspaceRemoveUserRequest.md deleted file mode 100644 index 9ca6aaeb..00000000 --- a/docs/WorkspaceRemoveUserRequest.md +++ /dev/null @@ -1,9 +0,0 @@ -# WorkspaceRemoveUserRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**user** | **str** | A string identifying a user. This can either be the string \"me\", an email, or the gid of a user. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceRequest.md b/docs/WorkspaceRequest.md deleted file mode 100644 index 046dccde..00000000 --- a/docs/WorkspaceRequest.md +++ /dev/null @@ -1,11 +0,0 @@ -# WorkspaceRequest - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the workspace. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceResponse.md b/docs/WorkspaceResponse.md deleted file mode 100644 index 874ac346..00000000 --- a/docs/WorkspaceResponse.md +++ /dev/null @@ -1,13 +0,0 @@ -# WorkspaceResponse - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**gid** | **str** | Globally unique identifier of the resource, as a string. | [optional] -**resource_type** | **str** | The base type of this resource. | [optional] -**name** | **str** | The name of the workspace. | [optional] -**email_domains** | **list[str]** | The email domains that are associated with this workspace. | [optional] -**is_organization** | **bool** | Whether the workspace is an *organization*. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceResponseArray.md b/docs/WorkspaceResponseArray.md deleted file mode 100644 index d58f27f9..00000000 --- a/docs/WorkspaceResponseArray.md +++ /dev/null @@ -1,10 +0,0 @@ -# WorkspaceResponseArray - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**list[WorkspaceResponse]**](WorkspaceResponse.md) | | -**next_page** | [**NextPage**](NextPage.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspaceResponseData.md b/docs/WorkspaceResponseData.md deleted file mode 100644 index fae0c4c0..00000000 --- a/docs/WorkspaceResponseData.md +++ /dev/null @@ -1,9 +0,0 @@ -# WorkspaceResponseData - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**WorkspaceResponse**](WorkspaceResponse.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/docs/WorkspacesApi.md b/docs/WorkspacesApi.md deleted file mode 100644 index 7eaf913d..00000000 --- a/docs/WorkspacesApi.md +++ /dev/null @@ -1,283 +0,0 @@ -# asana.WorkspacesApi - -All URIs are relative to *https://app.asana.com/api/1.0* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**add_user_for_workspace**](WorkspacesApi.md#add_user_for_workspace) | **POST** /workspaces/{workspace_gid}/addUser | Add a user to a workspace or organization -[**get_workspace**](WorkspacesApi.md#get_workspace) | **GET** /workspaces/{workspace_gid} | Get a workspace -[**get_workspaces**](WorkspacesApi.md#get_workspaces) | **GET** /workspaces | Get multiple workspaces -[**remove_user_for_workspace**](WorkspacesApi.md#remove_user_for_workspace) | **POST** /workspaces/{workspace_gid}/removeUser | Remove a user from a workspace or organization -[**update_workspace**](WorkspacesApi.md#update_workspace) | **PUT** /workspaces/{workspace_gid} | Update a workspace - -# **add_user_for_workspace** -> UserBaseResponseData add_user_for_workspace(body, workspace_gid, opt_fields=opt_fields) - -Add a user to a workspace or organization - -Add a user to a workspace or organization. The user can be referenced by their globally unique user ID or their email address. Returns the full user record for the invited user. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.WorkspacesApi(api_client) -body = asana.WorkspaceGidAddUserBody({"param1": "value1", "param2": "value2",}) # WorkspaceGidAddUserBody | The user to add to the workspace. -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -opt_fields = ["email","name","photo","photo.image_1024x1024","photo.image_128x128","photo.image_21x21","photo.image_27x27","photo.image_36x36","photo.image_60x60"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Add a user to a workspace or organization - api_response = api_instance.add_user_for_workspace(body, workspace_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling WorkspacesApi->add_user_for_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**WorkspaceGidAddUserBody**](WorkspaceGidAddUserBody.md)| The user to add to the workspace. | - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**UserBaseResponseData**](UserBaseResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_workspace** -> WorkspaceResponseData get_workspace(workspace_gid, opt_fields=opt_fields) - -Get a workspace - -Returns the full workspace record for a single workspace. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.WorkspacesApi(api_client) -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -opt_fields = ["email_domains","is_organization","name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get a workspace - api_response = api_instance.get_workspace(workspace_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling WorkspacesApi->get_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**WorkspaceResponseData**](WorkspaceResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **get_workspaces** -> WorkspaceResponseArray get_workspaces(limit=limit, offset=offset, opt_fields=opt_fields) - -Get multiple workspaces - -Returns the compact records for all workspaces visible to the authorized user. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.WorkspacesApi(api_client) -limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) -offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) -opt_fields = ["email_domains","is_organization","name","offset","path","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Get multiple workspaces - api_response = api_instance.get_workspaces(limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling WorkspacesApi->get_workspaces: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **limit** | **int**| Results per page. The number of objects to return per page. The value must be between 1 and 100. | [optional] - **offset** | **str**| Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' | [optional] - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**WorkspaceResponseArray**](WorkspaceResponseArray.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **remove_user_for_workspace** -> EmptyResponseData remove_user_for_workspace(body, workspace_gid) - -Remove a user from a workspace or organization - -Remove a user from a workspace or organization. The user making this call must be an admin in the workspace. The user can be referenced by their globally unique user ID or their email address. Returns an empty data record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.WorkspacesApi(api_client) -body = asana.WorkspaceGidRemoveUserBody({"param1": "value1", "param2": "value2",}) # WorkspaceGidRemoveUserBody | The user to remove from the workspace. -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - -try: - # Remove a user from a workspace or organization - api_response = api_instance.remove_user_for_workspace(body, workspace_gid) - pprint(api_response) -except ApiException as e: - print("Exception when calling WorkspacesApi->remove_user_for_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**WorkspaceGidRemoveUserBody**](WorkspaceGidRemoveUserBody.md)| The user to remove from the workspace. | - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - -### Return type - -[**EmptyResponseData**](EmptyResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **update_workspace** -> WorkspaceResponseData update_workspace(body, workspace_gid, opt_fields=opt_fields) - -Update a workspace - -A specific, existing workspace can be updated by making a PUT request on the URL for that workspace. Only the fields provided in the data block will be updated; any unspecified fields will remain unchanged. Currently the only field that can be modified for a workspace is its name. Returns the complete, updated workspace record. - -### Example -```python -import asana -from asana.rest import ApiException -from pprint import pprint - -# Configure OAuth2 access token for authorization: oauth2 -configuration = asana.Configuration() -configuration.access_token = '' -api_client = asana.ApiClient(configuration) - -# create an instance of the API class -api_instance = asana.WorkspacesApi(api_client) -body = asana.WorkspacesWorkspaceGidBody({"param1": "value1", "param2": "value2",}) # WorkspacesWorkspaceGidBody | The workspace object with all updated properties. -workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. -opt_fields = ["email_domains","is_organization","name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - -try: - # Update a workspace - api_response = api_instance.update_workspace(body, workspace_gid, opt_fields=opt_fields) - pprint(api_response) -except ApiException as e: - print("Exception when calling WorkspacesApi->update_workspace: %s\n" % e) -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | [**WorkspacesWorkspaceGidBody**](WorkspacesWorkspaceGidBody.md)| The workspace object with all updated properties. | - **workspace_gid** | **str**| Globally unique identifier for the workspace or organization. | - **opt_fields** | [**list[str]**](str.md)| This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. | [optional] - -### Return type - -[**WorkspaceResponseData**](WorkspaceResponseData.md) - -### Authorization - -[oauth2](../README.md#oauth2) - -### HTTP request headers - - - **Content-Type**: application/json; charset=UTF-8 - - **Accept**: application/json; charset=UTF-8 - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/docs/WorkspacesApi.yaml b/docs/WorkspacesApi.yaml deleted file mode 100644 index 458a7a5f..00000000 --- a/docs/WorkspacesApi.yaml +++ /dev/null @@ -1,109 +0,0 @@ -WorkspacesApi: - add_user_for_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.WorkspacesApi(api_client) - body = asana.WorkspaceGidAddUserBody({"param1": "value1", "param2": "value2",}) # WorkspaceGidAddUserBody | The user to add to the workspace. - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - opt_fields = ["email","name","photo","photo.image_1024x1024","photo.image_128x128","photo.image_21x21","photo.image_27x27","photo.image_36x36","photo.image_60x60"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Add a user to a workspace or organization - api_response = api_instance.add_user_for_workspace(body, workspace_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling WorkspacesApi->add_user_for_workspace: %s\n" % e) - get_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.WorkspacesApi(api_client) - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - opt_fields = ["email_domains","is_organization","name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get a workspace - api_response = api_instance.get_workspace(workspace_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling WorkspacesApi->get_workspace: %s\n" % e) - get_workspaces: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.WorkspacesApi(api_client) - limit = 50 # int | Results per page. The number of objects to return per page. The value must be between 1 and 100. (optional) - offset = 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9' # str | Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.' (optional) - opt_fields = ["email_domains","is_organization","name","offset","path","uri"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Get multiple workspaces - api_response = api_instance.get_workspaces(limit=limit, offset=offset, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling WorkspacesApi->get_workspaces: %s\n" % e) - remove_user_for_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.WorkspacesApi(api_client) - body = asana.WorkspaceGidRemoveUserBody({"param1": "value1", "param2": "value2",}) # WorkspaceGidRemoveUserBody | The user to remove from the workspace. - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - - try: - # Remove a user from a workspace or organization - api_response = api_instance.remove_user_for_workspace(body, workspace_gid) - pprint(api_response) - except ApiException as e: - print("Exception when calling WorkspacesApi->remove_user_for_workspace: %s\n" % e) - update_workspace: |- - import asana - from asana.rest import ApiException - from pprint import pprint - - # Configure OAuth2 access token for authorization: oauth2 - configuration = asana.Configuration() - configuration.access_token = '' - api_client = asana.ApiClient(configuration) - - # create an instance of the API class - api_instance = asana.WorkspacesApi(api_client) - body = asana.WorkspacesWorkspaceGidBody({"param1": "value1", "param2": "value2",}) # WorkspacesWorkspaceGidBody | The workspace object with all updated properties. - workspace_gid = '12345' # str | Globally unique identifier for the workspace or organization. - opt_fields = ["email_domains","is_organization","name"] # list[str] | This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include. (optional) - - try: - # Update a workspace - api_response = api_instance.update_workspace(body, workspace_gid, opt_fields=opt_fields) - pprint(api_response) - except ApiException as e: - print("Exception when calling WorkspacesApi->update_workspace: %s\n" % e) diff --git a/docs/WorkspacesWorkspaceGidBody.md b/docs/WorkspacesWorkspaceGidBody.md deleted file mode 100644 index 118e9e48..00000000 --- a/docs/WorkspacesWorkspaceGidBody.md +++ /dev/null @@ -1,9 +0,0 @@ -# WorkspacesWorkspaceGidBody - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**data** | [**WorkspaceRequest**](WorkspaceRequest.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - diff --git a/examples/example-create-task.py b/examples/example-create-task.py new file mode 100644 index 00000000..29312344 --- /dev/null +++ b/examples/example-create-task.py @@ -0,0 +1,46 @@ +import sys +import os +import json + +sys.path.append(os.path.dirname(os.path.dirname(__file__))) + +import asana + +# Instructions +# +# 1. Set your ASANA_ACCESS_TOKEN environment variable to a Personal Access Token obtained in your Asana Account Settings +# +# This simple script asks the user to choose from their available Workspaces and then the first page (if more than a +# single page exists) of available projects in order to create a task in that project. +# + +def user_select_option(message, options): + option_lst = list(options) + print_(message) + for i, val in enumerate(option_lst): + print_(i, ': ' + val['name']) + index = int(input("Enter choice (default 0): ") or 0) + return option_lst[index] + + +if 'ASANA_ACCESS_TOKEN' in os.environ: + # create a client with a Personal Access Token + client = asana.Client.access_token(os.environ['ASANA_ACCESS_TOKEN']) + workspaces = client.workspaces.get_workspaces() + + workspace = user_select_option("Please choose a workspace", workspaces) + + projects = client.projects.get_projects({'workspace': workspace['gid']}) + + project = user_select_option("Please choose a project", projects) + + result = client.tasks.create_task( + workspace['gid'], + { + 'name': 'Learn to use Nunchucks', + 'notes': 'Note: This is a test task created with the python-asana client.', + 'projects': [project['gid']] + } + ) + + print(json.dumps(result, indent=4)) diff --git a/examples/example-script.py b/examples/example-script.py new file mode 100644 index 00000000..72e23e45 --- /dev/null +++ b/examples/example-script.py @@ -0,0 +1,85 @@ +import sys, os +sys.path.append(os.path.dirname(os.path.dirname(__file__))) + +import asana +import json + +# OAuth Instructions: +# +# 1. create a new application in your Asana Account Settings ("App" panel) +# 2. set the redirect URL to "urn:ietf:wg:oauth:2.0:oob" +# 3. set your ASANA_CLIENT_ID and ASANA_CLIENT_SECRET environment variables +# +# Personal Access Token Instructions: +# +# 1. set your ASANA_ACCESS_TOKEN environment variable to a Personal Access Token obtained in your Asana Account Settings +# + +if 'ASANA_CLIENT_ID' in os.environ: + # create a client with the OAuth credentials: + client = asana.Client.oauth( + client_id=os.environ['ASANA_CLIENT_ID'], + client_secret=os.environ['ASANA_CLIENT_SECRET'], + # this special redirect URI will prompt the user to copy/paste the code. + # useful for command line scripts and other non-web apps + redirect_uri='urn:ietf:wg:oauth:2.0:oob' + ) + print("authorized=", client.session.authorized) + + # get an authorization URL: + (url, state) = client.session.authorization_url() + try: + # in a web app you'd redirect the user to this URL when they take action to + # login with Asana or connect their account to Asana + import webbrowser + webbrowser.open(url) + except Exception as e: + print("Open the following URL in a browser to authorize:") + print(url) + + print("Copy and paste the returned code from the browser and press enter:") + + code = sys.stdin.readline().strip() + # exchange the code for a bearer token + token = client.session.fetch_token(code=code) + + print("token=", json.dumps(token)) + print("authorized=", client.session.authorized) + print("me=", client.users.get_user('me')) + + # normally you'd persist this token somewhere + os.environ['ASANA_TOKEN'] = json.dumps(token) # (see below) + +if 'ASANA_TOKEN' in os.environ: + # create a client with your OAuth client ID and a previously obtained bearer token + client = asana.Client.oauth( + client_id=os.environ['ASANA_CLIENT_ID'], + token=json.loads(os.environ['ASANA_TOKEN']) + ) + print("authorized=", client.session.authorized) + print("me=", client.users.get_user('me')) + +if 'ASANA_ACCESS_TOKEN' in os.environ: + # create a client with a Personal Access Token + client = asana.Client.access_token(os.environ['ASANA_ACCESS_TOKEN']) + me = client.users.get_user('me') + print("me=" + json.dumps(me, indent=2)) + + # find your "Personal Projects" workspace + personal_projects = next(workspace for workspace in me['workspaces'] if workspace['name'] == 'Personal Projects') + projects = client.projects.get_projects(personal_projects['id'], iterator_type=None) + print("personal projects=" + json.dumps(projects, indent=2)) + + # create a "demo project" if it doesn't exist + try: + project = next(project for project in projects if project['name'] == 'demo project') + except: + print("creating 'demo project'") + project = client.projects.create_in_workspace(personal_projects['id'], { 'name': 'demo project' }) + print("project=", project) + + # start streaming modifications to the demo project. + # make some changes in Asana to see this working + print("starting streaming events for " + project['name']) + for event in client.events.get_iterator({ 'resource': project['id'] }): + print("event", event) diff --git a/examples/example-server.py b/examples/example-server.py new file mode 100644 index 00000000..b9ce8385 --- /dev/null +++ b/examples/example-server.py @@ -0,0 +1,77 @@ +import sys, os +sys.path.append(os.path.dirname(os.path.dirname(__file__))) + +from flask import Flask, request, session, redirect, render_template_string +import asana +import json + +# OAuth Instructions: +# +# 1. create a new application in your Asana Account Settings ("App" panel) +# 2. set the redirect URL to "http://localhost:5000/auth/asana/callback" (or whichever port you choose) +# 3. set your ASANA_CLIENT_ID and ASANA_CLIENT_SECRET environment variables + +# convience method to create a client with your credentials, and optionally a 'token' +def Client(**kwargs): + return asana.Client.oauth( + client_id=os.environ['ASANA_CLIENT_ID'], + client_secret=os.environ['ASANA_CLIENT_SECRET'], + redirect_uri='http://localhost:5000/auth/asana/callback', + **kwargs + ) + +app = Flask(__name__) + +# main page (http://localhost:5000/) +@app.route("/") +def main(): + token = session.get('token', False) + # if the user has a token they're logged in + if token: + # example request gets information about logged in user + me = Client(token=token).users.get_user('me') + return render_template_string(''' + +

Hello {{ name }}.

+

{{ dump }}

+

Logout

''', + name=me['name'], + dump=json.dumps(me, indent=2) + ) + # if we don't have a token show a "Sign in with Asana" button + else: + # get an authorization URL and anti-forgery "state" token + (auth_url, state) = Client().session.authorization_url() + # persist the state token in the user's session + session['state'] = state + # link the button to the authorization URL + return render_template_string(''' +

''', + auth_url=auth_url + ) + +# logout endpoint +@app.route("/logout") +def logout(): + # delete the session token and redirect back to the main page + del session['token'] + return redirect('/') + +# OAuth callback endpoint +@app.route("/auth/asana/callback") +def auth_callback(): + # verify the state token matches to prevent CSRF attacks + if request.args.get('state') == session['state']: + del session['state'] + # exchange the code for a bearer token and persist it in the user's session or database + session['token'] = Client().session.fetch_token(code=request.args.get('code')) + return redirect('/') + else: + return "state doesn't match!" + +app.secret_key = 'set this to something secret' + +if __name__ == "__main__": + app.run(debug=True) diff --git a/examples/example-summary-task.py b/examples/example-summary-task.py new file mode 100755 index 00000000..66cb860e --- /dev/null +++ b/examples/example-summary-task.py @@ -0,0 +1,106 @@ +import asana +import json +from datetime import date +import argparse +import sys, os +sys.path.append(os.path.dirname(os.path.dirname(__file__))) + +def summarize(client, project_id, post_project): + """ + Collect data from project_id, and create a summary task in the post_project. + """ + # Get info on the project + project = client.projects.get_project(project_id) + + # Loop through the tasks, collecting data + all_tasks = 0 + tasks_completed = 0 + tasks = client.tasks.get_tasks_for_project(project_id, opt_fields=['completed']) + for task in tasks: + all_tasks += 1 + if task['completed']: + tasks_completed += 1 + + # Make the summary task + summary_task_fields = { + 'projects': [post_project], + 'name': "{} Summary of \"{}\"".format( + date.today().isoformat(), project['name']), + 'notes': "{} tasks\n{} ({:.0%}) tasks completed".format( + all_tasks, tasks_completed, tasks_completed / all_tasks) + } + client.tasks.create_task(**summary_task_fields) + +def main(): + """ + Parse arguments, authorize user, and summarize each given project. + """ + parser = argparse.ArgumentParser() + parser.add_argument("project_to_summarize", + help="project id of project to summarize") + parser.add_argument("summary_project", + help="project id of summary project to post to") + args = parser.parse_args() + + # Use OAuth + # check if the user has an existing token stored. + authorized = False + client = None + if 'ASANA_CLIENT_ID' in os.environ and 'ASANA_TOKEN' in os.environ: + # create a client with your OAuth client ID and a previously obtained + # bearer token + client = asana.Client.oauth( + client_id=os.environ['ASANA_CLIENT_ID'], + token=json.loads(os.environ['ASANA_TOKEN']) + ) + print("authorized=", client.session.authorized) + + # try to get something to see if token has not expired. + try: + client.users.get_user('me') + authorized = True + except: + print("token expired. please update ASANA_TOKEN") + + # check if the user has the secret + if not authorized and 'ASANA_CLIENT_ID' in os.environ and 'ASANA_CLIENT_SECRET' in os.environ: + # create a client with the OAuth credentials: + client = asana.Client.oauth( + client_id=os.environ['ASANA_CLIENT_ID'], + client_secret=os.environ['ASANA_CLIENT_SECRET'], + # this special redirect URI will prompt the user to copy/paste the code + # useful for command line scripts and other non-web apps + redirect_uri='urn:ietf:wg:oauth:2.0:oob' + ) + + # get an authorization URL: + (url, state) = client.session.authorization_url() + try: + # in a web app you'd redirect the user to this URL when they take + # action to login with Asana or connect their account to Asana + import webbrowser + webbrowser.open(url) + except Exception as e: + print("Open the following URL in a browser to authorize:") + print(url) + + print("Copy and paste the returned code from the browser and press enter:") + + code = sys.stdin.readline().strip() + # exchange the code for a bearer token will fail on incorrect code + token = client.session.fetch_token(code=code) + + print("token=", json.dumps(token)) + + # normally you'd persist this token somewhere + os.environ['ASANA_TOKEN'] = json.dumps(token) # (see below) + + if not client or not client.session.authorized: + print("COULD NOT AUTHORIZE") + exit(1) + + # Summarize the project. + summarize(client, args.project_to_summarize, args.summary_project) + +if __name__ == '__main__': + main() diff --git a/git_push.sh b/git_push.sh deleted file mode 100644 index ae01b182..00000000 --- a/git_push.sh +++ /dev/null @@ -1,52 +0,0 @@ -#!/bin/sh -# ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/ -# -# Usage example: /bin/sh ./git_push.sh wing328 swagger-petstore-perl "minor update" - -git_user_id=$1 -git_repo_id=$2 -release_note=$3 - -if [ "$git_user_id" = "" ]; then - git_user_id="GIT_USER_ID" - echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id" -fi - -if [ "$git_repo_id" = "" ]; then - git_repo_id="GIT_REPO_ID" - echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id" -fi - -if [ "$release_note" = "" ]; then - release_note="Minor update" - echo "[INFO] No command line input provided. Set \$release_note to $release_note" -fi - -# Initialize the local directory as a Git repository -git init - -# Adds the files in the local repository and stages them for commit. -git add . - -# Commits the tracked changes and prepares them to be pushed to a remote repository. -git commit -m "$release_note" - -# Sets the new remote -git_remote=`git remote` -if [ "$git_remote" = "" ]; then # git remote not defined - - if [ "$GIT_TOKEN" = "" ]; then - echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment." - git remote add origin https://github.com/${git_user_id}/${git_repo_id}.git - else - git remote add origin https://${git_user_id}:${GIT_TOKEN}@github.com/${git_user_id}/${git_repo_id}.git - fi - -fi - -git pull origin master - -# Pushes (Forces) the changes in the local repository up to the remote repository -echo "Git pushing to https://github.com/${git_user_id}/${git_repo_id}.git" -git push origin master 2>&1 | grep -v 'To https' - diff --git a/requirements.txt b/requirements.txt index bafdc075..fd138620 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,5 +1,4 @@ -certifi >= 14.05.14 -six >= 1.10 -python_dateutil >= 2.5.3 -setuptools >= 21.0.0 -urllib3 >= 1.15.1 +pytest~=7.2 +requests_oauthlib~=1.3 +requests~=2.28 +responses~=0.22 diff --git a/samples/attachments_sample.yaml b/samples/attachments_sample.yaml new file mode 100644 index 00000000..06d430e2 --- /dev/null +++ b/samples/attachments_sample.yaml @@ -0,0 +1,33 @@ +attachments: + create_attachment_for_object: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.attachments.create_attachment_for_object({'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_attachment: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.attachments.delete_attachment(attachment_gid, opt_pretty=True) + get_attachment: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.attachments.get_attachment(attachment_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_attachments_for_object: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.attachments.get_attachments_for_object({'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/audit_log_api_sample.yaml b/samples/audit_log_api_sample.yaml new file mode 100644 index 00000000..8dbcccf5 --- /dev/null +++ b/samples/audit_log_api_sample.yaml @@ -0,0 +1,9 @@ +auditlogapi: + get_audit_log_events: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.audit_log_api.get_audit_log_events(workspace_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/batch_api_sample.yaml b/samples/batch_api_sample.yaml new file mode 100644 index 00000000..a4a1b1b3 --- /dev/null +++ b/samples/batch_api_sample.yaml @@ -0,0 +1,9 @@ +batchapi: + create_batch_request: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.batch_api.create_batch_request({'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/custom_field_settings_sample.yaml b/samples/custom_field_settings_sample.yaml new file mode 100644 index 00000000..ded3bf82 --- /dev/null +++ b/samples/custom_field_settings_sample.yaml @@ -0,0 +1,17 @@ +customfieldsettings: + get_custom_field_settings_for_portfolio: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.custom_field_settings.get_custom_field_settings_for_portfolio(portfolio_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_custom_field_settings_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.custom_field_settings.get_custom_field_settings_for_project(project_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/custom_fields_sample.yaml b/samples/custom_fields_sample.yaml new file mode 100644 index 00000000..e3b48a1b --- /dev/null +++ b/samples/custom_fields_sample.yaml @@ -0,0 +1,65 @@ +customfields: + create_custom_field: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.custom_fields.create_custom_field({'field': 'value', 'field': 'value'}, opt_pretty=True) + create_enum_option_for_custom_field: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.custom_fields.create_enum_option_for_custom_field(custom_field_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_custom_field: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.custom_fields.delete_custom_field(custom_field_gid, opt_pretty=True) + get_custom_field: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.custom_fields.get_custom_field(custom_field_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_custom_fields_for_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.custom_fields.get_custom_fields_for_workspace(workspace_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + insert_enum_option_for_custom_field: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.custom_fields.insert_enum_option_for_custom_field(custom_field_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + update_custom_field: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.custom_fields.update_custom_field(custom_field_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + update_enum_option: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.custom_fields.update_enum_option(enum_option_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/events_sample.yaml b/samples/events_sample.yaml new file mode 100644 index 00000000..951bede8 --- /dev/null +++ b/samples/events_sample.yaml @@ -0,0 +1,9 @@ +events: + get_events: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.events.get_events({'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/goal_relationships_sample.yaml b/samples/goal_relationships_sample.yaml new file mode 100644 index 00000000..74384947 --- /dev/null +++ b/samples/goal_relationships_sample.yaml @@ -0,0 +1,41 @@ +goalrelationships: + add_supporting_relationship: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goal_relationships.add_supporting_relationship(goal_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + get_goal_relationship: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goal_relationships.get_goal_relationship(goal_relationship_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_goal_relationships: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goal_relationships.get_goal_relationships({'param': 'value', 'param': 'value'}, opt_pretty=True) + remove_supporting_relationship: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goal_relationships.remove_supporting_relationship(goal_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + update_goal_relationship: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goal_relationships.update_goal_relationship(goal_relationship_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/goals_sample.yaml b/samples/goals_sample.yaml new file mode 100644 index 00000000..100819cc --- /dev/null +++ b/samples/goals_sample.yaml @@ -0,0 +1,81 @@ +goals: + add_followers: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goals.add_followers(goal_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + create_goal: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goals.create_goal({'field': 'value', 'field': 'value'}, opt_pretty=True) + create_goal_metric: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goals.create_goal_metric(goal_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_goal: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goals.delete_goal(goal_gid, opt_pretty=True) + get_goal: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goals.get_goal(goal_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_goals: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goals.get_goals({'param': 'value', 'param': 'value'}, opt_pretty=True) + get_parent_goals_for_goal: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goals.get_parent_goals_for_goal(goal_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + remove_followers: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goals.remove_followers(goal_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + update_goal: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goals.update_goal(goal_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + update_goal_metric: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.goals.update_goal_metric(goal_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/jobs_sample.yaml b/samples/jobs_sample.yaml new file mode 100644 index 00000000..1d97b5ea --- /dev/null +++ b/samples/jobs_sample.yaml @@ -0,0 +1,9 @@ +jobs: + get_job: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.jobs.get_job(job_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/memberships_sample.yaml b/samples/memberships_sample.yaml new file mode 100644 index 00000000..c60224b7 --- /dev/null +++ b/samples/memberships_sample.yaml @@ -0,0 +1,33 @@ +memberships: + create_membership: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.memberships.create_membership({'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_membership: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.memberships.delete_membership(membership_gid, opt_pretty=True) + get_memberships: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.memberships.get_memberships({'param': 'value', 'param': 'value'}, opt_pretty=True) + update_membership: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.memberships.update_membership(membership_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/message_sample.yaml b/samples/message_sample.yaml new file mode 100644 index 00000000..89e5df77 --- /dev/null +++ b/samples/message_sample.yaml @@ -0,0 +1,9 @@ +message: + get_message: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.message.get_message(message_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/organization_exports_sample.yaml b/samples/organization_exports_sample.yaml new file mode 100644 index 00000000..1e1414c6 --- /dev/null +++ b/samples/organization_exports_sample.yaml @@ -0,0 +1,17 @@ +organizationexports: + create_organization_export: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.organization_exports.create_organization_export({'field': 'value', 'field': 'value'}, opt_pretty=True) + get_organization_export: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.organization_exports.get_organization_export(organization_export_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/portfolio_memberships_sample.yaml b/samples/portfolio_memberships_sample.yaml new file mode 100644 index 00000000..ca32a779 --- /dev/null +++ b/samples/portfolio_memberships_sample.yaml @@ -0,0 +1,25 @@ +portfoliomemberships: + get_portfolio_membership: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolio_memberships.get_portfolio_membership(portfolio_membership_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_portfolio_memberships: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolio_memberships.get_portfolio_memberships({'param': 'value', 'param': 'value'}, opt_pretty=True) + get_portfolio_memberships_for_portfolio: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolio_memberships.get_portfolio_memberships_for_portfolio(portfolio_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/portfolios_sample.yaml b/samples/portfolios_sample.yaml new file mode 100644 index 00000000..4bbc0f6a --- /dev/null +++ b/samples/portfolios_sample.yaml @@ -0,0 +1,97 @@ +portfolios: + add_custom_field_setting_for_portfolio: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolios.add_custom_field_setting_for_portfolio(portfolio_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + add_item_for_portfolio: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolios.add_item_for_portfolio(portfolio_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + add_members_for_portfolio: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolios.add_members_for_portfolio(portfolio_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + create_portfolio: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolios.create_portfolio({'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_portfolio: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolios.delete_portfolio(portfolio_gid, opt_pretty=True) + get_items_for_portfolio: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolios.get_items_for_portfolio(portfolio_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_portfolio: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolios.get_portfolio(portfolio_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_portfolios: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolios.get_portfolios({'param': 'value', 'param': 'value'}, opt_pretty=True) + remove_custom_field_setting_for_portfolio: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolios.remove_custom_field_setting_for_portfolio(portfolio_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + remove_item_for_portfolio: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolios.remove_item_for_portfolio(portfolio_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + remove_members_for_portfolio: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolios.remove_members_for_portfolio(portfolio_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + update_portfolio: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.portfolios.update_portfolio(portfolio_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/project_briefs_sample.yaml b/samples/project_briefs_sample.yaml new file mode 100644 index 00000000..af64d5a7 --- /dev/null +++ b/samples/project_briefs_sample.yaml @@ -0,0 +1,33 @@ +projectbriefs: + create_project_brief: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_briefs.create_project_brief(project_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_project_brief: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_briefs.delete_project_brief(project_brief_gid, opt_pretty=True) + get_project_brief: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_briefs.get_project_brief(project_brief_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + update_project_brief: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_briefs.update_project_brief(project_brief_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/project_memberships_sample.yaml b/samples/project_memberships_sample.yaml new file mode 100644 index 00000000..32539a28 --- /dev/null +++ b/samples/project_memberships_sample.yaml @@ -0,0 +1,17 @@ +projectmemberships: + get_project_membership: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_memberships.get_project_membership(project_membership_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_project_memberships_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_memberships.get_project_memberships_for_project(project_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/project_statuses_sample.yaml b/samples/project_statuses_sample.yaml new file mode 100644 index 00000000..4b9703d6 --- /dev/null +++ b/samples/project_statuses_sample.yaml @@ -0,0 +1,33 @@ +projectstatuses: + create_project_status_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_statuses.create_project_status_for_project(project_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_project_status: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_statuses.delete_project_status(project_status_gid, opt_pretty=True) + get_project_status: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_statuses.get_project_status(project_status_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_project_statuses_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_statuses.get_project_statuses_for_project(project_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/project_templates_sample.yaml b/samples/project_templates_sample.yaml new file mode 100644 index 00000000..ae4b37d5 --- /dev/null +++ b/samples/project_templates_sample.yaml @@ -0,0 +1,33 @@ +projecttemplates: + get_project_template: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_templates.get_project_template(project_template_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_project_templates: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_templates.get_project_templates({'param': 'value', 'param': 'value'}, opt_pretty=True) + get_project_templates_for_team: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_templates.get_project_templates_for_team(team_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + instantiate_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.project_templates.instantiate_project(project_template_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/projects_sample.yaml b/samples/projects_sample.yaml new file mode 100644 index 00000000..30fd7d09 --- /dev/null +++ b/samples/projects_sample.yaml @@ -0,0 +1,153 @@ +projects: + add_custom_field_setting_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.add_custom_field_setting_for_project(project_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + add_followers_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.add_followers_for_project(project_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + add_members_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.add_members_for_project(project_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + create_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.create_project({'field': 'value', 'field': 'value'}, opt_pretty=True) + create_project_for_team: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.create_project_for_team(team_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + create_project_for_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.create_project_for_workspace(workspace_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.delete_project(project_gid, opt_pretty=True) + duplicate_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.duplicate_project(project_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + get_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.get_project(project_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_projects: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.get_projects({'param': 'value', 'param': 'value'}, opt_pretty=True) + get_projects_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.get_projects_for_task(task_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_projects_for_team: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.get_projects_for_team(team_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_projects_for_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.get_projects_for_workspace(workspace_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_task_counts_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.get_task_counts_for_project(project_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + project_save_as_template: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.project_save_as_template(project_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + remove_custom_field_setting_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.remove_custom_field_setting_for_project(project_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + remove_followers_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.remove_followers_for_project(project_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + remove_members_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.remove_members_for_project(project_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + update_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.projects.update_project(project_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/sections_sample.yaml b/samples/sections_sample.yaml new file mode 100644 index 00000000..c6e7eeca --- /dev/null +++ b/samples/sections_sample.yaml @@ -0,0 +1,57 @@ +sections: + add_task_for_section: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.sections.add_task_for_section(section_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + create_section_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.sections.create_section_for_project(project_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_section: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.sections.delete_section(section_gid, opt_pretty=True) + get_section: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.sections.get_section(section_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_sections_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.sections.get_sections_for_project(project_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + insert_section_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.sections.insert_section_for_project(project_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + update_section: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.sections.update_section(section_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/status_updates_sample.yaml b/samples/status_updates_sample.yaml new file mode 100644 index 00000000..9da2ba90 --- /dev/null +++ b/samples/status_updates_sample.yaml @@ -0,0 +1,33 @@ +statusupdates: + create_status_for_object: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.status_updates.create_status_for_object({'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_status: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.status_updates.delete_status(status_gid, opt_pretty=True) + get_status: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.status_updates.get_status(status_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_statuses_for_object: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.status_updates.get_statuses_for_object({'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/stories_sample.yaml b/samples/stories_sample.yaml new file mode 100644 index 00000000..c6d858fb --- /dev/null +++ b/samples/stories_sample.yaml @@ -0,0 +1,41 @@ +stories: + create_story_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.stories.create_story_for_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_story: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.stories.delete_story(story_gid, opt_pretty=True) + get_stories_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.stories.get_stories_for_task(task_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_story: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.stories.get_story(story_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + update_story: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.stories.update_story(story_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/tags_sample.yaml b/samples/tags_sample.yaml new file mode 100644 index 00000000..fdf954cb --- /dev/null +++ b/samples/tags_sample.yaml @@ -0,0 +1,65 @@ +tags: + create_tag: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tags.create_tag({'field': 'value', 'field': 'value'}, opt_pretty=True) + create_tag_for_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tags.create_tag_for_workspace(workspace_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_tag: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tags.delete_tag(tag_gid, opt_pretty=True) + get_tag: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tags.get_tag(tag_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_tags: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tags.get_tags({'param': 'value', 'param': 'value'}, opt_pretty=True) + get_tags_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tags.get_tags_for_task(task_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_tags_for_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tags.get_tags_for_workspace(workspace_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + update_tag: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tags.update_tag(tag_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/tasks_sample.yaml b/samples/tasks_sample.yaml new file mode 100644 index 00000000..b551a3dc --- /dev/null +++ b/samples/tasks_sample.yaml @@ -0,0 +1,209 @@ +tasks: + add_dependencies_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.add_dependencies_for_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + add_dependents_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.add_dependents_for_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + add_followers_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.add_followers_for_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + add_project_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.add_project_for_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + add_tag_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.add_tag_for_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + create_subtask_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.create_subtask_for_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + create_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.create_task({'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.delete_task(task_gid, opt_pretty=True) + duplicate_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.duplicate_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + get_dependencies_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.get_dependencies_for_task(task_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_dependents_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.get_dependents_for_task(task_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_subtasks_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.get_subtasks_for_task(task_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.get_task(task_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_tasks: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.get_tasks({'param': 'value', 'param': 'value'}, opt_pretty=True) + get_tasks_for_project: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.get_tasks_for_project(project_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_tasks_for_section: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.get_tasks_for_section(section_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_tasks_for_tag: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.get_tasks_for_tag(tag_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_tasks_for_user_task_list: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.get_tasks_for_user_task_list(user_task_list_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + remove_dependencies_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.remove_dependencies_for_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + remove_dependents_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.remove_dependents_for_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + remove_follower_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.remove_follower_for_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + remove_project_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.remove_project_for_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + remove_tag_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.remove_tag_for_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + search_tasks_for_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.search_tasks_for_workspace(workspace_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + set_parent_for_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.set_parent_for_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + update_task: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.tasks.update_task(task_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/team_memberships_sample.yaml b/samples/team_memberships_sample.yaml new file mode 100644 index 00000000..2b30cfb1 --- /dev/null +++ b/samples/team_memberships_sample.yaml @@ -0,0 +1,33 @@ +teammemberships: + get_team_membership: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.team_memberships.get_team_membership(team_membership_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_team_memberships: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.team_memberships.get_team_memberships({'param': 'value', 'param': 'value'}, opt_pretty=True) + get_team_memberships_for_team: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.team_memberships.get_team_memberships_for_team(team_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_team_memberships_for_user: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.team_memberships.get_team_memberships_for_user(user_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/teams_sample.yaml b/samples/teams_sample.yaml new file mode 100644 index 00000000..d2e09aca --- /dev/null +++ b/samples/teams_sample.yaml @@ -0,0 +1,57 @@ +teams: + add_user_for_team: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.teams.add_user_for_team(team_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + create_team: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.teams.create_team({'field': 'value', 'field': 'value'}, opt_pretty=True) + get_team: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.teams.get_team(team_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_teams_for_user: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.teams.get_teams_for_user(user_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_teams_for_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.teams.get_teams_for_workspace(workspace_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + remove_user_for_team: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.teams.remove_user_for_team(team_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + update_team: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.teams.update_team({'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/time_periods_sample.yaml b/samples/time_periods_sample.yaml new file mode 100644 index 00000000..e9c7e415 --- /dev/null +++ b/samples/time_periods_sample.yaml @@ -0,0 +1,17 @@ +timeperiods: + get_time_period: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.time_periods.get_time_period(time_period_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_time_periods: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.time_periods.get_time_periods({'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/typeahead_sample.yaml b/samples/typeahead_sample.yaml new file mode 100644 index 00000000..37b55e19 --- /dev/null +++ b/samples/typeahead_sample.yaml @@ -0,0 +1,9 @@ +typeahead: + typeahead_for_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.typeahead.typeahead_for_workspace(workspace_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/user_task_lists_sample.yaml b/samples/user_task_lists_sample.yaml new file mode 100644 index 00000000..8c73f216 --- /dev/null +++ b/samples/user_task_lists_sample.yaml @@ -0,0 +1,17 @@ +usertasklists: + get_user_task_list: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.user_task_lists.get_user_task_list(user_task_list_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_user_task_list_for_user: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.user_task_lists.get_user_task_list_for_user(user_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/users_sample.yaml b/samples/users_sample.yaml new file mode 100644 index 00000000..dfbae326 --- /dev/null +++ b/samples/users_sample.yaml @@ -0,0 +1,41 @@ +users: + get_favorites_for_user: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.users.get_favorites_for_user(user_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_user: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.users.get_user(user_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_users: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.users.get_users({'param': 'value', 'param': 'value'}, opt_pretty=True) + get_users_for_team: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.users.get_users_for_team(team_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_users_for_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.users.get_users_for_workspace(workspace_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/webhooks_sample.yaml b/samples/webhooks_sample.yaml new file mode 100644 index 00000000..7cd66242 --- /dev/null +++ b/samples/webhooks_sample.yaml @@ -0,0 +1,41 @@ +webhooks: + create_webhook: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.webhooks.create_webhook({'field': 'value', 'field': 'value'}, opt_pretty=True) + delete_webhook: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.webhooks.delete_webhook(webhook_gid, opt_pretty=True) + get_webhook: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.webhooks.get_webhook(webhook_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_webhooks: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.webhooks.get_webhooks({'param': 'value', 'param': 'value'}, opt_pretty=True) + update_webhook: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.webhooks.update_webhook(webhook_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/samples/workspace_memberships_sample.yaml b/samples/workspace_memberships_sample.yaml new file mode 100644 index 00000000..0901c48f --- /dev/null +++ b/samples/workspace_memberships_sample.yaml @@ -0,0 +1,25 @@ +workspacememberships: + get_workspace_membership: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.workspace_memberships.get_workspace_membership(workspace_membership_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_workspace_memberships_for_user: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.workspace_memberships.get_workspace_memberships_for_user(user_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_workspace_memberships_for_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.workspace_memberships.get_workspace_memberships_for_workspace(workspace_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) diff --git a/samples/workspaces_sample.yaml b/samples/workspaces_sample.yaml new file mode 100644 index 00000000..cff9a078 --- /dev/null +++ b/samples/workspaces_sample.yaml @@ -0,0 +1,41 @@ +workspaces: + add_user_for_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.workspaces.add_user_for_workspace(workspace_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + get_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.workspaces.get_workspace(workspace_gid, {'param': 'value', 'param': 'value'}, opt_pretty=True) + get_workspaces: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.workspaces.get_workspaces({'param': 'value', 'param': 'value'}, opt_pretty=True) + remove_user_for_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.workspaces.remove_user_for_workspace(workspace_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) + update_workspace: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.workspaces.update_workspace(workspace_gid, {'field': 'value', 'field': 'value'}, opt_pretty=True) diff --git a/setup.cfg b/setup.cfg new file mode 100644 index 00000000..ed8a958e --- /dev/null +++ b/setup.cfg @@ -0,0 +1,5 @@ +[bdist_wheel] +universal = 1 + +[metadata] +license_file = LICENSE diff --git a/setup.py b/setup.py old mode 100644 new mode 100755 index e58ab734..b695d5d9 --- a/setup.py +++ b/setup.py @@ -1,48 +1,44 @@ -# coding: utf-8 +#!/usr/bin/env python -""" - Asana +import sys +import os +from setuptools import setup, find_packages - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 +assert sys.version_info >= (3, 7), 'We only support Python 3.7+' - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" +sys.path.insert(0, os.path.join(os.path.dirname(__file__), 'asana')) -import os -from setuptools import setup, find_packages # noqa: H301 +# Safely read the version number from the version.py file +version = {} +with open('asana/version.py') as fp: + exec(fp.read(), version) -NAME = "asana" -VERSION = "4.0.11" with open(os.path.join(os.path.dirname(__file__), 'README.md')) as readme: - LONG_DESCRIPTION = readme.read() -# To install the library, run the following -# -# python setup.py install -# -# prerequisite: setuptools -# http://pypi.python.org/pypi/setuptools - -REQUIRES = [ - "certifi>=2017.4.17", - "python-dateutil>=2.1", - "six>=1.10", - "urllib3>=1.23" -] - + long_description = readme.read() setup( - name=NAME, - version=VERSION, - description="Asana", - long_description=LONG_DESCRIPTION, + name='asana', + version=version['__version__'], + description='Asana API client', + long_description=long_description, long_description_content_type='text/markdown', - author='Asana, Inc', - url="http://github.com/asana/python-asana", - keywords=["asana", "Asana"], - install_requires=REQUIRES, - packages=find_packages(), - include_package_data=True, license='MIT', -) + classifiers=[ + 'Development Status :: 5 - Production/Stable', + 'Intended Audience :: Developers', + 'License :: OSI Approved :: MIT License', + 'Natural Language :: English', + 'Programming Language :: Python :: 3', + 'Programming Language :: Python :: 3.7' + ], + install_requires=[ + 'requests >= 2.20.0, == 2.*', + 'requests_oauthlib >= 0.8.0, <2.0', + ], + author='Asana, Inc', + # author_email='', + url='http://github.com/asana/python-asana', + packages=find_packages(exclude=('tests', 'examples')), + keywords='asana', + zip_safe=True, + test_suite='tests') diff --git a/swagger_templates/api.mustache b/swagger_templates/api.mustache new file mode 100644 index 00000000..52d17b33 --- /dev/null +++ b/swagger_templates/api.mustache @@ -0,0 +1,27 @@ +# coding=utf-8 +{{#operations}} +class _{{classname}}: + + def __init__(self, client=None): + self.client = client +{{#operation}}{{^formParams}} +{{#contents}} + + def {{operationId}}(self, {{#pathParams}}{{paramName}}, {{/pathParams}}params=None, **options): + """{{#summary}}{{{.}}}{{/summary}}{{^summary}}{{operationId}}{{/summary}} + {{#pathParams}} + :param {{dataType}} {{paramName}}:{{#required}} (required){{/required}}{{#optional}}(optional){{/optional}}{{#description}} {{{description}}}{{/description}} + {{/pathParams}} + :param Object params: Parameters for the request{{#queryParams}}{{#neq baseName 'opt_pretty' 'opt_fields' 'offset' 'limit'}} + - {{paramName}} { {{~dataType~}} }: {{#required}} (required){{/required}}{{#optional}}(optional){{/optional}}{{#description}} {{{description}}}{{/description}}{{/neq}}{{/queryParams}} + :param **options{{#queryParams}}{{#eq baseName 'opt_pretty' 'opt_fields' 'offset' 'limit'}} + - {{paramName}} { {{~dataType~}} }: {{#required}} (required){{/required}}{{#optional}}(optional){{/optional}}{{#description}} {{{description}}}{{/description}}{{/eq}}{{/queryParams}} + :return: Object + """ + if params is None: + params = {} + path = "{{path}}"{{#pathParams}}.replace("{ {{~baseName~}} }", {{paramName}}){{/pathParams}} + return self.client.{{#neq "GET" httpMethod}}{{toLowerCase httpMethod}}{{/neq}}{{#eq "GET" httpMethod}}{{returnContainer}}{{/eq}}(path, params, **options) +{{/contents}} +{{/formParams}}{{/operation}} +{{/operations}} diff --git a/swagger_templates/api_doc.mustache b/swagger_templates/api_doc.mustache new file mode 100644 index 00000000..46e46411 --- /dev/null +++ b/swagger_templates/api_doc.mustache @@ -0,0 +1,10 @@ +{{#operations}}{{toLowerCase classname}}: {{#operation}}{{#contents}} + {{operationId}}: >- + import asana + + + client = asana.Client.access_token('PERSONAL_ACCESS_TOKEN') + + + result = client.{{toLowerCase baseName}}.{{operationId}}({{#pathParams}}{{paramName}}, {{/pathParams}}{{#neq "GET" httpMethod}}{{#neq "DELETE" httpMethod}}{'field': 'value', 'field': 'value'}, {{/neq}}{{/neq}}{{#eq "GET" httpMethod}}{'param': 'value', 'param': 'value'}, {{/eq}}opt_pretty=True){{/contents}}{{/operation}} +{{/operations}} diff --git a/swagger_templates/python-config.json b/swagger_templates/python-config.json new file mode 100644 index 00000000..af0ec379 --- /dev/null +++ b/swagger_templates/python-config.json @@ -0,0 +1,6 @@ +{ + "packageName" : "asana", + "templateDir": "swagger_templates", + "hideGenerationTimestamp": true, + "apiTests": false +} diff --git a/test-requirements.txt b/test-requirements.txt deleted file mode 100644 index 2702246c..00000000 --- a/test-requirements.txt +++ /dev/null @@ -1,5 +0,0 @@ -coverage>=4.0.3 -nose>=1.3.7 -pluggy>=0.3.1 -py>=1.4.31 -randomize>=0.13 diff --git a/test/__init__.py b/test/__init__.py deleted file mode 100644 index 576f56f8..00000000 --- a/test/__init__.py +++ /dev/null @@ -1 +0,0 @@ -# coding: utf-8 \ No newline at end of file diff --git a/test/test_add_custom_field_setting_request.py b/test/test_add_custom_field_setting_request.py deleted file mode 100644 index 4dc7726e..00000000 --- a/test/test_add_custom_field_setting_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.add_custom_field_setting_request import AddCustomFieldSettingRequest # noqa: E501 -from asana.rest import ApiException - - -class TestAddCustomFieldSettingRequest(unittest.TestCase): - """AddCustomFieldSettingRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAddCustomFieldSettingRequest(self): - """Test AddCustomFieldSettingRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.add_custom_field_setting_request.AddCustomFieldSettingRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_add_followers_request.py b/test/test_add_followers_request.py deleted file mode 100644 index a4b8a21f..00000000 --- a/test/test_add_followers_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.add_followers_request import AddFollowersRequest # noqa: E501 -from asana.rest import ApiException - - -class TestAddFollowersRequest(unittest.TestCase): - """AddFollowersRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAddFollowersRequest(self): - """Test AddFollowersRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.add_followers_request.AddFollowersRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_add_members_request.py b/test/test_add_members_request.py deleted file mode 100644 index 389cd81c..00000000 --- a/test/test_add_members_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.add_members_request import AddMembersRequest # noqa: E501 -from asana.rest import ApiException - - -class TestAddMembersRequest(unittest.TestCase): - """AddMembersRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAddMembersRequest(self): - """Test AddMembersRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.add_members_request.AddMembersRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_project_response_owner.py b/test/test_all_of_project_response_owner.py deleted file mode 100644 index 630b3a77..00000000 --- a/test/test_all_of_project_response_owner.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_project_response_owner import AllOfProjectResponseOwner # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfProjectResponseOwner(unittest.TestCase): - """AllOfProjectResponseOwner unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfProjectResponseOwner(self): - """Test AllOfProjectResponseOwner""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_project_response_owner.AllOfProjectResponseOwner() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_project_template_base_owner.py b/test/test_all_of_project_template_base_owner.py deleted file mode 100644 index 10f699c0..00000000 --- a/test/test_all_of_project_template_base_owner.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_project_template_base_owner import AllOfProjectTemplateBaseOwner # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfProjectTemplateBaseOwner(unittest.TestCase): - """AllOfProjectTemplateBaseOwner unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfProjectTemplateBaseOwner(self): - """Test AllOfProjectTemplateBaseOwner""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_project_template_base_owner.AllOfProjectTemplateBaseOwner() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_project_template_response_owner.py b/test/test_all_of_project_template_response_owner.py deleted file mode 100644 index 98c35ff6..00000000 --- a/test/test_all_of_project_template_response_owner.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_project_template_response_owner import AllOfProjectTemplateResponseOwner # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfProjectTemplateResponseOwner(unittest.TestCase): - """AllOfProjectTemplateResponseOwner unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfProjectTemplateResponseOwner(self): - """Test AllOfProjectTemplateResponseOwner""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_project_template_response_owner.AllOfProjectTemplateResponseOwner() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_story_response_new_date_value.py b/test/test_all_of_story_response_new_date_value.py deleted file mode 100644 index 7e035e2f..00000000 --- a/test/test_all_of_story_response_new_date_value.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_story_response_new_date_value import AllOfStoryResponseNewDateValue # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfStoryResponseNewDateValue(unittest.TestCase): - """AllOfStoryResponseNewDateValue unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfStoryResponseNewDateValue(self): - """Test AllOfStoryResponseNewDateValue""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_story_response_new_date_value.AllOfStoryResponseNewDateValue() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_story_response_old_date_value.py b/test/test_all_of_story_response_old_date_value.py deleted file mode 100644 index f98b549f..00000000 --- a/test/test_all_of_story_response_old_date_value.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_story_response_old_date_value import AllOfStoryResponseOldDateValue # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfStoryResponseOldDateValue(unittest.TestCase): - """AllOfStoryResponseOldDateValue unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfStoryResponseOldDateValue(self): - """Test AllOfStoryResponseOldDateValue""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_story_response_old_date_value.AllOfStoryResponseOldDateValue() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_task_template_response_created_by.py b/test/test_all_of_task_template_response_created_by.py deleted file mode 100644 index c7d4d584..00000000 --- a/test/test_all_of_task_template_response_created_by.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_task_template_response_created_by import AllOfTaskTemplateResponseCreatedBy # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfTaskTemplateResponseCreatedBy(unittest.TestCase): - """AllOfTaskTemplateResponseCreatedBy unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfTaskTemplateResponseCreatedBy(self): - """Test AllOfTaskTemplateResponseCreatedBy""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_task_template_response_created_by.AllOfTaskTemplateResponseCreatedBy() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_task_template_response_project.py b/test/test_all_of_task_template_response_project.py deleted file mode 100644 index 3bc47644..00000000 --- a/test/test_all_of_task_template_response_project.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_task_template_response_project import AllOfTaskTemplateResponseProject # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfTaskTemplateResponseProject(unittest.TestCase): - """AllOfTaskTemplateResponseProject unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfTaskTemplateResponseProject(self): - """Test AllOfTaskTemplateResponseProject""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_task_template_response_project.AllOfTaskTemplateResponseProject() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_task_template_response_template.py b/test/test_all_of_task_template_response_template.py deleted file mode 100644 index 0588f8ef..00000000 --- a/test/test_all_of_task_template_response_template.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_task_template_response_template import AllOfTaskTemplateResponseTemplate # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfTaskTemplateResponseTemplate(unittest.TestCase): - """AllOfTaskTemplateResponseTemplate unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfTaskTemplateResponseTemplate(self): - """Test AllOfTaskTemplateResponseTemplate""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_task_template_response_template.AllOfTaskTemplateResponseTemplate() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_user_task_list_base_owner.py b/test/test_all_of_user_task_list_base_owner.py deleted file mode 100644 index 667afcdc..00000000 --- a/test/test_all_of_user_task_list_base_owner.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_user_task_list_base_owner import AllOfUserTaskListBaseOwner # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfUserTaskListBaseOwner(unittest.TestCase): - """AllOfUserTaskListBaseOwner unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfUserTaskListBaseOwner(self): - """Test AllOfUserTaskListBaseOwner""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_user_task_list_base_owner.AllOfUserTaskListBaseOwner() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_user_task_list_base_workspace.py b/test/test_all_of_user_task_list_base_workspace.py deleted file mode 100644 index 574d4799..00000000 --- a/test/test_all_of_user_task_list_base_workspace.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_user_task_list_base_workspace import AllOfUserTaskListBaseWorkspace # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfUserTaskListBaseWorkspace(unittest.TestCase): - """AllOfUserTaskListBaseWorkspace unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfUserTaskListBaseWorkspace(self): - """Test AllOfUserTaskListBaseWorkspace""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_user_task_list_base_workspace.AllOfUserTaskListBaseWorkspace() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_user_task_list_compact_owner.py b/test/test_all_of_user_task_list_compact_owner.py deleted file mode 100644 index 0ac65a25..00000000 --- a/test/test_all_of_user_task_list_compact_owner.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_user_task_list_compact_owner import AllOfUserTaskListCompactOwner # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfUserTaskListCompactOwner(unittest.TestCase): - """AllOfUserTaskListCompactOwner unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfUserTaskListCompactOwner(self): - """Test AllOfUserTaskListCompactOwner""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_user_task_list_compact_owner.AllOfUserTaskListCompactOwner() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_user_task_list_compact_workspace.py b/test/test_all_of_user_task_list_compact_workspace.py deleted file mode 100644 index 50379cde..00000000 --- a/test/test_all_of_user_task_list_compact_workspace.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_user_task_list_compact_workspace import AllOfUserTaskListCompactWorkspace # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfUserTaskListCompactWorkspace(unittest.TestCase): - """AllOfUserTaskListCompactWorkspace unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfUserTaskListCompactWorkspace(self): - """Test AllOfUserTaskListCompactWorkspace""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_user_task_list_compact_workspace.AllOfUserTaskListCompactWorkspace() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_user_task_list_request_owner.py b/test/test_all_of_user_task_list_request_owner.py deleted file mode 100644 index 067db865..00000000 --- a/test/test_all_of_user_task_list_request_owner.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_user_task_list_request_owner import AllOfUserTaskListRequestOwner # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfUserTaskListRequestOwner(unittest.TestCase): - """AllOfUserTaskListRequestOwner unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfUserTaskListRequestOwner(self): - """Test AllOfUserTaskListRequestOwner""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_user_task_list_request_owner.AllOfUserTaskListRequestOwner() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_user_task_list_request_workspace.py b/test/test_all_of_user_task_list_request_workspace.py deleted file mode 100644 index 9be112a5..00000000 --- a/test/test_all_of_user_task_list_request_workspace.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_user_task_list_request_workspace import AllOfUserTaskListRequestWorkspace # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfUserTaskListRequestWorkspace(unittest.TestCase): - """AllOfUserTaskListRequestWorkspace unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfUserTaskListRequestWorkspace(self): - """Test AllOfUserTaskListRequestWorkspace""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_user_task_list_request_workspace.AllOfUserTaskListRequestWorkspace() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_user_task_list_response_owner.py b/test/test_all_of_user_task_list_response_owner.py deleted file mode 100644 index a40aeb1b..00000000 --- a/test/test_all_of_user_task_list_response_owner.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_user_task_list_response_owner import AllOfUserTaskListResponseOwner # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfUserTaskListResponseOwner(unittest.TestCase): - """AllOfUserTaskListResponseOwner unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfUserTaskListResponseOwner(self): - """Test AllOfUserTaskListResponseOwner""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_user_task_list_response_owner.AllOfUserTaskListResponseOwner() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_user_task_list_response_workspace.py b/test/test_all_of_user_task_list_response_workspace.py deleted file mode 100644 index 416b68df..00000000 --- a/test/test_all_of_user_task_list_response_workspace.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_user_task_list_response_workspace import AllOfUserTaskListResponseWorkspace # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfUserTaskListResponseWorkspace(unittest.TestCase): - """AllOfUserTaskListResponseWorkspace unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfUserTaskListResponseWorkspace(self): - """Test AllOfUserTaskListResponseWorkspace""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_user_task_list_response_workspace.AllOfUserTaskListResponseWorkspace() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_workspace_membership_response_user_task_list_owner.py b/test/test_all_of_workspace_membership_response_user_task_list_owner.py deleted file mode 100644 index 91a9c4a2..00000000 --- a/test/test_all_of_workspace_membership_response_user_task_list_owner.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_workspace_membership_response_user_task_list_owner import AllOfWorkspaceMembershipResponseUserTaskListOwner # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfWorkspaceMembershipResponseUserTaskListOwner(unittest.TestCase): - """AllOfWorkspaceMembershipResponseUserTaskListOwner unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfWorkspaceMembershipResponseUserTaskListOwner(self): - """Test AllOfWorkspaceMembershipResponseUserTaskListOwner""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_workspace_membership_response_user_task_list_owner.AllOfWorkspaceMembershipResponseUserTaskListOwner() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_all_of_workspace_membership_response_user_task_list_workspace.py b/test/test_all_of_workspace_membership_response_user_task_list_workspace.py deleted file mode 100644 index 9ecd22b9..00000000 --- a/test/test_all_of_workspace_membership_response_user_task_list_workspace.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.all_of_workspace_membership_response_user_task_list_workspace import AllOfWorkspaceMembershipResponseUserTaskListWorkspace # noqa: E501 -from asana.rest import ApiException - - -class TestAllOfWorkspaceMembershipResponseUserTaskListWorkspace(unittest.TestCase): - """AllOfWorkspaceMembershipResponseUserTaskListWorkspace unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAllOfWorkspaceMembershipResponseUserTaskListWorkspace(self): - """Test AllOfWorkspaceMembershipResponseUserTaskListWorkspace""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.all_of_workspace_membership_response_user_task_list_workspace.AllOfWorkspaceMembershipResponseUserTaskListWorkspace() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_asana_named_resource.py b/test/test_asana_named_resource.py deleted file mode 100644 index 99003356..00000000 --- a/test/test_asana_named_resource.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.asana_named_resource import AsanaNamedResource # noqa: E501 -from asana.rest import ApiException - - -class TestAsanaNamedResource(unittest.TestCase): - """AsanaNamedResource unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAsanaNamedResource(self): - """Test AsanaNamedResource""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.asana_named_resource.AsanaNamedResource() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_asana_named_resource_array.py b/test/test_asana_named_resource_array.py deleted file mode 100644 index e825a407..00000000 --- a/test/test_asana_named_resource_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.asana_named_resource_array import AsanaNamedResourceArray # noqa: E501 -from asana.rest import ApiException - - -class TestAsanaNamedResourceArray(unittest.TestCase): - """AsanaNamedResourceArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAsanaNamedResourceArray(self): - """Test AsanaNamedResourceArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.asana_named_resource_array.AsanaNamedResourceArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_asana_resource.py b/test/test_asana_resource.py deleted file mode 100644 index bebd91f2..00000000 --- a/test/test_asana_resource.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.asana_resource import AsanaResource # noqa: E501 -from asana.rest import ApiException - - -class TestAsanaResource(unittest.TestCase): - """AsanaResource unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAsanaResource(self): - """Test AsanaResource""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.asana_resource.AsanaResource() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_attachment_base.py b/test/test_attachment_base.py deleted file mode 100644 index 3b0a9177..00000000 --- a/test/test_attachment_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.attachment_base import AttachmentBase # noqa: E501 -from asana.rest import ApiException - - -class TestAttachmentBase(unittest.TestCase): - """AttachmentBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAttachmentBase(self): - """Test AttachmentBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.attachment_base.AttachmentBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_attachment_compact.py b/test/test_attachment_compact.py deleted file mode 100644 index 4d986f02..00000000 --- a/test/test_attachment_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.attachment_compact import AttachmentCompact # noqa: E501 -from asana.rest import ApiException - - -class TestAttachmentCompact(unittest.TestCase): - """AttachmentCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAttachmentCompact(self): - """Test AttachmentCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.attachment_compact.AttachmentCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_attachment_request.py b/test/test_attachment_request.py deleted file mode 100644 index 9a70117d..00000000 --- a/test/test_attachment_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.attachment_request import AttachmentRequest # noqa: E501 -from asana.rest import ApiException - - -class TestAttachmentRequest(unittest.TestCase): - """AttachmentRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAttachmentRequest(self): - """Test AttachmentRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.attachment_request.AttachmentRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_attachment_response.py b/test/test_attachment_response.py deleted file mode 100644 index a7ac5f26..00000000 --- a/test/test_attachment_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.attachment_response import AttachmentResponse # noqa: E501 -from asana.rest import ApiException - - -class TestAttachmentResponse(unittest.TestCase): - """AttachmentResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAttachmentResponse(self): - """Test AttachmentResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.attachment_response.AttachmentResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_attachment_response_array.py b/test/test_attachment_response_array.py deleted file mode 100644 index 5628e6fd..00000000 --- a/test/test_attachment_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.attachment_response_array import AttachmentResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestAttachmentResponseArray(unittest.TestCase): - """AttachmentResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAttachmentResponseArray(self): - """Test AttachmentResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.attachment_response_array.AttachmentResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_attachment_response_data.py b/test/test_attachment_response_data.py deleted file mode 100644 index 6bdb9d6b..00000000 --- a/test/test_attachment_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.attachment_response_data import AttachmentResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestAttachmentResponseData(unittest.TestCase): - """AttachmentResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAttachmentResponseData(self): - """Test AttachmentResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.attachment_response_data.AttachmentResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_attachment_response_parent.py b/test/test_attachment_response_parent.py deleted file mode 100644 index 1a144851..00000000 --- a/test/test_attachment_response_parent.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.attachment_response_parent import AttachmentResponseParent # noqa: E501 -from asana.rest import ApiException - - -class TestAttachmentResponseParent(unittest.TestCase): - """AttachmentResponseParent unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAttachmentResponseParent(self): - """Test AttachmentResponseParent""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.attachment_response_parent.AttachmentResponseParent() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_attachment_response_parent_created_by.py b/test/test_attachment_response_parent_created_by.py deleted file mode 100644 index 29fb0dc3..00000000 --- a/test/test_attachment_response_parent_created_by.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.attachment_response_parent_created_by import AttachmentResponseParentCreatedBy # noqa: E501 -from asana.rest import ApiException - - -class TestAttachmentResponseParentCreatedBy(unittest.TestCase): - """AttachmentResponseParentCreatedBy unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAttachmentResponseParentCreatedBy(self): - """Test AttachmentResponseParentCreatedBy""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.attachment_response_parent_created_by.AttachmentResponseParentCreatedBy() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_attachments_api.py b/test/test_attachments_api.py deleted file mode 100644 index 1d8c7899..00000000 --- a/test/test_attachments_api.py +++ /dev/null @@ -1,61 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.attachments_api import AttachmentsApi # noqa: E501 -from asana.rest import ApiException - - -class TestAttachmentsApi(unittest.TestCase): - """AttachmentsApi unit test stubs""" - - def setUp(self): - self.api = AttachmentsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_create_attachment_for_object(self): - """Test case for create_attachment_for_object - - Upload an attachment # noqa: E501 - """ - pass - - def test_delete_attachment(self): - """Test case for delete_attachment - - Delete an attachment # noqa: E501 - """ - pass - - def test_get_attachment(self): - """Test case for get_attachment - - Get an attachment # noqa: E501 - """ - pass - - def test_get_attachments_for_object(self): - """Test case for get_attachments_for_object - - Get attachments from an object # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_audit_log_api_api.py b/test/test_audit_log_api_api.py deleted file mode 100644 index 5c0fe1d5..00000000 --- a/test/test_audit_log_api_api.py +++ /dev/null @@ -1,40 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.audit_log_api_api import AuditLogAPIApi # noqa: E501 -from asana.rest import ApiException - - -class TestAuditLogAPIApi(unittest.TestCase): - """AuditLogAPIApi unit test stubs""" - - def setUp(self): - self.api = AuditLogAPIApi() # noqa: E501 - - def tearDown(self): - pass - - def test_get_audit_log_events(self): - """Test case for get_audit_log_events - - Get audit log events # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_audit_log_event.py b/test/test_audit_log_event.py deleted file mode 100644 index 13d7eab5..00000000 --- a/test/test_audit_log_event.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.audit_log_event import AuditLogEvent # noqa: E501 -from asana.rest import ApiException - - -class TestAuditLogEvent(unittest.TestCase): - """AuditLogEvent unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAuditLogEvent(self): - """Test AuditLogEvent""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.audit_log_event.AuditLogEvent() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_audit_log_event_actor.py b/test/test_audit_log_event_actor.py deleted file mode 100644 index f1294d75..00000000 --- a/test/test_audit_log_event_actor.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.audit_log_event_actor import AuditLogEventActor # noqa: E501 -from asana.rest import ApiException - - -class TestAuditLogEventActor(unittest.TestCase): - """AuditLogEventActor unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAuditLogEventActor(self): - """Test AuditLogEventActor""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.audit_log_event_actor.AuditLogEventActor() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_audit_log_event_array.py b/test/test_audit_log_event_array.py deleted file mode 100644 index 3a56d851..00000000 --- a/test/test_audit_log_event_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.audit_log_event_array import AuditLogEventArray # noqa: E501 -from asana.rest import ApiException - - -class TestAuditLogEventArray(unittest.TestCase): - """AuditLogEventArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAuditLogEventArray(self): - """Test AuditLogEventArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.audit_log_event_array.AuditLogEventArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_audit_log_event_context.py b/test/test_audit_log_event_context.py deleted file mode 100644 index c196488b..00000000 --- a/test/test_audit_log_event_context.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.audit_log_event_context import AuditLogEventContext # noqa: E501 -from asana.rest import ApiException - - -class TestAuditLogEventContext(unittest.TestCase): - """AuditLogEventContext unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAuditLogEventContext(self): - """Test AuditLogEventContext""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.audit_log_event_context.AuditLogEventContext() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_audit_log_event_details.py b/test/test_audit_log_event_details.py deleted file mode 100644 index 7331ca1e..00000000 --- a/test/test_audit_log_event_details.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.audit_log_event_details import AuditLogEventDetails # noqa: E501 -from asana.rest import ApiException - - -class TestAuditLogEventDetails(unittest.TestCase): - """AuditLogEventDetails unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAuditLogEventDetails(self): - """Test AuditLogEventDetails""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.audit_log_event_details.AuditLogEventDetails() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_audit_log_event_resource.py b/test/test_audit_log_event_resource.py deleted file mode 100644 index ccde8d23..00000000 --- a/test/test_audit_log_event_resource.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.audit_log_event_resource import AuditLogEventResource # noqa: E501 -from asana.rest import ApiException - - -class TestAuditLogEventResource(unittest.TestCase): - """AuditLogEventResource unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testAuditLogEventResource(self): - """Test AuditLogEventResource""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.audit_log_event_resource.AuditLogEventResource() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_batch_api_api.py b/test/test_batch_api_api.py deleted file mode 100644 index bffbc5a3..00000000 --- a/test/test_batch_api_api.py +++ /dev/null @@ -1,40 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.batch_api_api import BatchAPIApi # noqa: E501 -from asana.rest import ApiException - - -class TestBatchAPIApi(unittest.TestCase): - """BatchAPIApi unit test stubs""" - - def setUp(self): - self.api = BatchAPIApi() # noqa: E501 - - def tearDown(self): - pass - - def test_create_batch_request(self): - """Test case for create_batch_request - - Submit parallel requests # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_batch_body.py b/test/test_batch_body.py deleted file mode 100644 index 7f4bf771..00000000 --- a/test/test_batch_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.batch_body import BatchBody # noqa: E501 -from asana.rest import ApiException - - -class TestBatchBody(unittest.TestCase): - """BatchBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testBatchBody(self): - """Test BatchBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.batch_body.BatchBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_batch_request.py b/test/test_batch_request.py deleted file mode 100644 index 05c8f141..00000000 --- a/test/test_batch_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.batch_request import BatchRequest # noqa: E501 -from asana.rest import ApiException - - -class TestBatchRequest(unittest.TestCase): - """BatchRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testBatchRequest(self): - """Test BatchRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.batch_request.BatchRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_batch_request_action.py b/test/test_batch_request_action.py deleted file mode 100644 index 40925160..00000000 --- a/test/test_batch_request_action.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.batch_request_action import BatchRequestAction # noqa: E501 -from asana.rest import ApiException - - -class TestBatchRequestAction(unittest.TestCase): - """BatchRequestAction unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testBatchRequestAction(self): - """Test BatchRequestAction""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.batch_request_action.BatchRequestAction() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_batch_request_actions.py b/test/test_batch_request_actions.py deleted file mode 100644 index 829223c9..00000000 --- a/test/test_batch_request_actions.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.batch_request_actions import BatchRequestActions # noqa: E501 -from asana.rest import ApiException - - -class TestBatchRequestActions(unittest.TestCase): - """BatchRequestActions unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testBatchRequestActions(self): - """Test BatchRequestActions""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.batch_request_actions.BatchRequestActions() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_batch_request_options.py b/test/test_batch_request_options.py deleted file mode 100644 index ab9ba6fb..00000000 --- a/test/test_batch_request_options.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.batch_request_options import BatchRequestOptions # noqa: E501 -from asana.rest import ApiException - - -class TestBatchRequestOptions(unittest.TestCase): - """BatchRequestOptions unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testBatchRequestOptions(self): - """Test BatchRequestOptions""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.batch_request_options.BatchRequestOptions() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_batch_response.py b/test/test_batch_response.py deleted file mode 100644 index 535720cd..00000000 --- a/test/test_batch_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.batch_response import BatchResponse # noqa: E501 -from asana.rest import ApiException - - -class TestBatchResponse(unittest.TestCase): - """BatchResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testBatchResponse(self): - """Test BatchResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.batch_response.BatchResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_batch_response_array.py b/test/test_batch_response_array.py deleted file mode 100644 index 65d8b6de..00000000 --- a/test/test_batch_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.batch_response_array import BatchResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestBatchResponseArray(unittest.TestCase): - """BatchResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testBatchResponseArray(self): - """Test BatchResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.batch_response_array.BatchResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_create_membership_request.py b/test/test_create_membership_request.py deleted file mode 100644 index cfd8c495..00000000 --- a/test/test_create_membership_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.create_membership_request import CreateMembershipRequest # noqa: E501 -from asana.rest import ApiException - - -class TestCreateMembershipRequest(unittest.TestCase): - """CreateMembershipRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCreateMembershipRequest(self): - """Test CreateMembershipRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.create_membership_request.CreateMembershipRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_create_time_tracking_entry_request.py b/test/test_create_time_tracking_entry_request.py deleted file mode 100644 index 8bd9aa85..00000000 --- a/test/test_create_time_tracking_entry_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.create_time_tracking_entry_request import CreateTimeTrackingEntryRequest # noqa: E501 -from asana.rest import ApiException - - -class TestCreateTimeTrackingEntryRequest(unittest.TestCase): - """CreateTimeTrackingEntryRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCreateTimeTrackingEntryRequest(self): - """Test CreateTimeTrackingEntryRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.create_time_tracking_entry_request.CreateTimeTrackingEntryRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_base.py b/test/test_custom_field_base.py deleted file mode 100644 index 5235cc2d..00000000 --- a/test/test_custom_field_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_base import CustomFieldBase # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldBase(unittest.TestCase): - """CustomFieldBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldBase(self): - """Test CustomFieldBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_base.CustomFieldBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_base_date_value.py b/test/test_custom_field_base_date_value.py deleted file mode 100644 index c8d93dff..00000000 --- a/test/test_custom_field_base_date_value.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_base_date_value import CustomFieldBaseDateValue # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldBaseDateValue(unittest.TestCase): - """CustomFieldBaseDateValue unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldBaseDateValue(self): - """Test CustomFieldBaseDateValue""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_base_date_value.CustomFieldBaseDateValue() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_base_enum_options.py b/test/test_custom_field_base_enum_options.py deleted file mode 100644 index fccf10c4..00000000 --- a/test/test_custom_field_base_enum_options.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_base_enum_options import CustomFieldBaseEnumOptions # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldBaseEnumOptions(unittest.TestCase): - """CustomFieldBaseEnumOptions unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldBaseEnumOptions(self): - """Test CustomFieldBaseEnumOptions""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_base_enum_options.CustomFieldBaseEnumOptions() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_base_enum_value.py b/test/test_custom_field_base_enum_value.py deleted file mode 100644 index ca21c28d..00000000 --- a/test/test_custom_field_base_enum_value.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_base_enum_value import CustomFieldBaseEnumValue # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldBaseEnumValue(unittest.TestCase): - """CustomFieldBaseEnumValue unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldBaseEnumValue(self): - """Test CustomFieldBaseEnumValue""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_base_enum_value.CustomFieldBaseEnumValue() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_compact.py b/test/test_custom_field_compact.py deleted file mode 100644 index 6d49c0d3..00000000 --- a/test/test_custom_field_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_compact import CustomFieldCompact # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldCompact(unittest.TestCase): - """CustomFieldCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldCompact(self): - """Test CustomFieldCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_compact.CustomFieldCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_gid_enum_options_body.py b/test/test_custom_field_gid_enum_options_body.py deleted file mode 100644 index 09e431b8..00000000 --- a/test/test_custom_field_gid_enum_options_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_gid_enum_options_body import CustomFieldGidEnumOptionsBody # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldGidEnumOptionsBody(unittest.TestCase): - """CustomFieldGidEnumOptionsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldGidEnumOptionsBody(self): - """Test CustomFieldGidEnumOptionsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_gid_enum_options_body.CustomFieldGidEnumOptionsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_request.py b/test/test_custom_field_request.py deleted file mode 100644 index 90e5d8ee..00000000 --- a/test/test_custom_field_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_request import CustomFieldRequest # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldRequest(unittest.TestCase): - """CustomFieldRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldRequest(self): - """Test CustomFieldRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_request.CustomFieldRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_response.py b/test/test_custom_field_response.py deleted file mode 100644 index ae544e4f..00000000 --- a/test/test_custom_field_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_response import CustomFieldResponse # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldResponse(unittest.TestCase): - """CustomFieldResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldResponse(self): - """Test CustomFieldResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_response.CustomFieldResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_response_array.py b/test/test_custom_field_response_array.py deleted file mode 100644 index 1a57720d..00000000 --- a/test/test_custom_field_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_response_array import CustomFieldResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldResponseArray(unittest.TestCase): - """CustomFieldResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldResponseArray(self): - """Test CustomFieldResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_response_array.CustomFieldResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_response_created_by.py b/test/test_custom_field_response_created_by.py deleted file mode 100644 index 8e5d849a..00000000 --- a/test/test_custom_field_response_created_by.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_response_created_by import CustomFieldResponseCreatedBy # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldResponseCreatedBy(unittest.TestCase): - """CustomFieldResponseCreatedBy unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldResponseCreatedBy(self): - """Test CustomFieldResponseCreatedBy""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_response_created_by.CustomFieldResponseCreatedBy() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_response_data.py b/test/test_custom_field_response_data.py deleted file mode 100644 index b6cbc3fe..00000000 --- a/test/test_custom_field_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_response_data import CustomFieldResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldResponseData(unittest.TestCase): - """CustomFieldResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldResponseData(self): - """Test CustomFieldResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_response_data.CustomFieldResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_response_people_value.py b/test/test_custom_field_response_people_value.py deleted file mode 100644 index 15f06e63..00000000 --- a/test/test_custom_field_response_people_value.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_response_people_value import CustomFieldResponsePeopleValue # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldResponsePeopleValue(unittest.TestCase): - """CustomFieldResponsePeopleValue unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldResponsePeopleValue(self): - """Test CustomFieldResponsePeopleValue""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_response_people_value.CustomFieldResponsePeopleValue() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_setting_base.py b/test/test_custom_field_setting_base.py deleted file mode 100644 index 0c17c342..00000000 --- a/test/test_custom_field_setting_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_setting_base import CustomFieldSettingBase # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldSettingBase(unittest.TestCase): - """CustomFieldSettingBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldSettingBase(self): - """Test CustomFieldSettingBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_setting_base.CustomFieldSettingBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_setting_compact.py b/test/test_custom_field_setting_compact.py deleted file mode 100644 index e2b262c1..00000000 --- a/test/test_custom_field_setting_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_setting_compact import CustomFieldSettingCompact # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldSettingCompact(unittest.TestCase): - """CustomFieldSettingCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldSettingCompact(self): - """Test CustomFieldSettingCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_setting_compact.CustomFieldSettingCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_setting_response.py b/test/test_custom_field_setting_response.py deleted file mode 100644 index cf7f04bb..00000000 --- a/test/test_custom_field_setting_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_setting_response import CustomFieldSettingResponse # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldSettingResponse(unittest.TestCase): - """CustomFieldSettingResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldSettingResponse(self): - """Test CustomFieldSettingResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_setting_response.CustomFieldSettingResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_setting_response_array.py b/test/test_custom_field_setting_response_array.py deleted file mode 100644 index 4ab232db..00000000 --- a/test/test_custom_field_setting_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_setting_response_array import CustomFieldSettingResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldSettingResponseArray(unittest.TestCase): - """CustomFieldSettingResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldSettingResponseArray(self): - """Test CustomFieldSettingResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_setting_response_array.CustomFieldSettingResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_setting_response_custom_field.py b/test/test_custom_field_setting_response_custom_field.py deleted file mode 100644 index a3afaa30..00000000 --- a/test/test_custom_field_setting_response_custom_field.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_setting_response_custom_field import CustomFieldSettingResponseCustomField # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldSettingResponseCustomField(unittest.TestCase): - """CustomFieldSettingResponseCustomField unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldSettingResponseCustomField(self): - """Test CustomFieldSettingResponseCustomField""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_setting_response_custom_field.CustomFieldSettingResponseCustomField() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_setting_response_data.py b/test/test_custom_field_setting_response_data.py deleted file mode 100644 index 3eae96d2..00000000 --- a/test/test_custom_field_setting_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_setting_response_data import CustomFieldSettingResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldSettingResponseData(unittest.TestCase): - """CustomFieldSettingResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldSettingResponseData(self): - """Test CustomFieldSettingResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_setting_response_data.CustomFieldSettingResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_setting_response_parent.py b/test/test_custom_field_setting_response_parent.py deleted file mode 100644 index 84eabddd..00000000 --- a/test/test_custom_field_setting_response_parent.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_setting_response_parent import CustomFieldSettingResponseParent # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldSettingResponseParent(unittest.TestCase): - """CustomFieldSettingResponseParent unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldSettingResponseParent(self): - """Test CustomFieldSettingResponseParent""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_setting_response_parent.CustomFieldSettingResponseParent() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_setting_response_project.py b/test/test_custom_field_setting_response_project.py deleted file mode 100644 index f5a60bbc..00000000 --- a/test/test_custom_field_setting_response_project.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_field_setting_response_project import CustomFieldSettingResponseProject # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldSettingResponseProject(unittest.TestCase): - """CustomFieldSettingResponseProject unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldSettingResponseProject(self): - """Test CustomFieldSettingResponseProject""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_field_setting_response_project.CustomFieldSettingResponseProject() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_field_settings_api.py b/test/test_custom_field_settings_api.py deleted file mode 100644 index c82c55fc..00000000 --- a/test/test_custom_field_settings_api.py +++ /dev/null @@ -1,47 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.custom_field_settings_api import CustomFieldSettingsApi # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldSettingsApi(unittest.TestCase): - """CustomFieldSettingsApi unit test stubs""" - - def setUp(self): - self.api = CustomFieldSettingsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_get_custom_field_settings_for_portfolio(self): - """Test case for get_custom_field_settings_for_portfolio - - Get a portfolio's custom fields # noqa: E501 - """ - pass - - def test_get_custom_field_settings_for_project(self): - """Test case for get_custom_field_settings_for_project - - Get a project's custom fields # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_fields_api.py b/test/test_custom_fields_api.py deleted file mode 100644 index 473420bc..00000000 --- a/test/test_custom_fields_api.py +++ /dev/null @@ -1,89 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.custom_fields_api import CustomFieldsApi # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldsApi(unittest.TestCase): - """CustomFieldsApi unit test stubs""" - - def setUp(self): - self.api = CustomFieldsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_create_custom_field(self): - """Test case for create_custom_field - - Create a custom field # noqa: E501 - """ - pass - - def test_create_enum_option_for_custom_field(self): - """Test case for create_enum_option_for_custom_field - - Create an enum option # noqa: E501 - """ - pass - - def test_delete_custom_field(self): - """Test case for delete_custom_field - - Delete a custom field # noqa: E501 - """ - pass - - def test_get_custom_field(self): - """Test case for get_custom_field - - Get a custom field # noqa: E501 - """ - pass - - def test_get_custom_fields_for_workspace(self): - """Test case for get_custom_fields_for_workspace - - Get a workspace's custom fields # noqa: E501 - """ - pass - - def test_insert_enum_option_for_custom_field(self): - """Test case for insert_enum_option_for_custom_field - - Reorder a custom field's enum # noqa: E501 - """ - pass - - def test_update_custom_field(self): - """Test case for update_custom_field - - Update a custom field # noqa: E501 - """ - pass - - def test_update_enum_option(self): - """Test case for update_enum_option - - Update an enum option # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_fields_body.py b/test/test_custom_fields_body.py deleted file mode 100644 index a0beaed6..00000000 --- a/test/test_custom_fields_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_fields_body import CustomFieldsBody # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldsBody(unittest.TestCase): - """CustomFieldsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldsBody(self): - """Test CustomFieldsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_fields_body.CustomFieldsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_custom_fields_custom_field_gid_body.py b/test/test_custom_fields_custom_field_gid_body.py deleted file mode 100644 index 3d5a0532..00000000 --- a/test/test_custom_fields_custom_field_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.custom_fields_custom_field_gid_body import CustomFieldsCustomFieldGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestCustomFieldsCustomFieldGidBody(unittest.TestCase): - """CustomFieldsCustomFieldGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testCustomFieldsCustomFieldGidBody(self): - """Test CustomFieldsCustomFieldGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.custom_fields_custom_field_gid_body.CustomFieldsCustomFieldGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_date_variable_compact.py b/test/test_date_variable_compact.py deleted file mode 100644 index 76485903..00000000 --- a/test/test_date_variable_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.date_variable_compact import DateVariableCompact # noqa: E501 -from asana.rest import ApiException - - -class TestDateVariableCompact(unittest.TestCase): - """DateVariableCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testDateVariableCompact(self): - """Test DateVariableCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.date_variable_compact.DateVariableCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_date_variable_request.py b/test/test_date_variable_request.py deleted file mode 100644 index 168dbdef..00000000 --- a/test/test_date_variable_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.date_variable_request import DateVariableRequest # noqa: E501 -from asana.rest import ApiException - - -class TestDateVariableRequest(unittest.TestCase): - """DateVariableRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testDateVariableRequest(self): - """Test DateVariableRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.date_variable_request.DateVariableRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_empty_response.py b/test/test_empty_response.py deleted file mode 100644 index 0c6f0c0c..00000000 --- a/test/test_empty_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.empty_response import EmptyResponse # noqa: E501 -from asana.rest import ApiException - - -class TestEmptyResponse(unittest.TestCase): - """EmptyResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEmptyResponse(self): - """Test EmptyResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.empty_response.EmptyResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_empty_response_data.py b/test/test_empty_response_data.py deleted file mode 100644 index de0be856..00000000 --- a/test/test_empty_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.empty_response_data import EmptyResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestEmptyResponseData(unittest.TestCase): - """EmptyResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEmptyResponseData(self): - """Test EmptyResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.empty_response_data.EmptyResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_enum_option.py b/test/test_enum_option.py deleted file mode 100644 index 81d5e5b4..00000000 --- a/test/test_enum_option.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.enum_option import EnumOption # noqa: E501 -from asana.rest import ApiException - - -class TestEnumOption(unittest.TestCase): - """EnumOption unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEnumOption(self): - """Test EnumOption""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.enum_option.EnumOption() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_enum_option_base.py b/test/test_enum_option_base.py deleted file mode 100644 index dc635e7b..00000000 --- a/test/test_enum_option_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.enum_option_base import EnumOptionBase # noqa: E501 -from asana.rest import ApiException - - -class TestEnumOptionBase(unittest.TestCase): - """EnumOptionBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEnumOptionBase(self): - """Test EnumOptionBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.enum_option_base.EnumOptionBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_enum_option_data.py b/test/test_enum_option_data.py deleted file mode 100644 index d901cfd0..00000000 --- a/test/test_enum_option_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.enum_option_data import EnumOptionData # noqa: E501 -from asana.rest import ApiException - - -class TestEnumOptionData(unittest.TestCase): - """EnumOptionData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEnumOptionData(self): - """Test EnumOptionData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.enum_option_data.EnumOptionData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_enum_option_insert_request.py b/test/test_enum_option_insert_request.py deleted file mode 100644 index d5a7e569..00000000 --- a/test/test_enum_option_insert_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.enum_option_insert_request import EnumOptionInsertRequest # noqa: E501 -from asana.rest import ApiException - - -class TestEnumOptionInsertRequest(unittest.TestCase): - """EnumOptionInsertRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEnumOptionInsertRequest(self): - """Test EnumOptionInsertRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.enum_option_insert_request.EnumOptionInsertRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_enum_option_request.py b/test/test_enum_option_request.py deleted file mode 100644 index 5768085d..00000000 --- a/test/test_enum_option_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.enum_option_request import EnumOptionRequest # noqa: E501 -from asana.rest import ApiException - - -class TestEnumOptionRequest(unittest.TestCase): - """EnumOptionRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEnumOptionRequest(self): - """Test EnumOptionRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.enum_option_request.EnumOptionRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_enum_options_enum_option_gid_body.py b/test/test_enum_options_enum_option_gid_body.py deleted file mode 100644 index ce5b9a15..00000000 --- a/test/test_enum_options_enum_option_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.enum_options_enum_option_gid_body import EnumOptionsEnumOptionGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestEnumOptionsEnumOptionGidBody(unittest.TestCase): - """EnumOptionsEnumOptionGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEnumOptionsEnumOptionGidBody(self): - """Test EnumOptionsEnumOptionGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.enum_options_enum_option_gid_body.EnumOptionsEnumOptionGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_enum_options_insert_body.py b/test/test_enum_options_insert_body.py deleted file mode 100644 index 235d4074..00000000 --- a/test/test_enum_options_insert_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.enum_options_insert_body import EnumOptionsInsertBody # noqa: E501 -from asana.rest import ApiException - - -class TestEnumOptionsInsertBody(unittest.TestCase): - """EnumOptionsInsertBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEnumOptionsInsertBody(self): - """Test EnumOptionsInsertBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.enum_options_insert_body.EnumOptionsInsertBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_error.py b/test/test_error.py deleted file mode 100644 index cc55b99a..00000000 --- a/test/test_error.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.error import Error # noqa: E501 -from asana.rest import ApiException - - -class TestError(unittest.TestCase): - """Error unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testError(self): - """Test Error""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.error.Error() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_error_response.py b/test/test_error_response.py deleted file mode 100644 index 23a7ea04..00000000 --- a/test/test_error_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.error_response import ErrorResponse # noqa: E501 -from asana.rest import ApiException - - -class TestErrorResponse(unittest.TestCase): - """ErrorResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testErrorResponse(self): - """Test ErrorResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.error_response.ErrorResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_error_response_errors.py b/test/test_error_response_errors.py deleted file mode 100644 index 44b4e6bd..00000000 --- a/test/test_error_response_errors.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.error_response_errors import ErrorResponseErrors # noqa: E501 -from asana.rest import ApiException - - -class TestErrorResponseErrors(unittest.TestCase): - """ErrorResponseErrors unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testErrorResponseErrors(self): - """Test ErrorResponseErrors""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.error_response_errors.ErrorResponseErrors() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_event_response.py b/test/test_event_response.py deleted file mode 100644 index 2b45bfa9..00000000 --- a/test/test_event_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.event_response import EventResponse # noqa: E501 -from asana.rest import ApiException - - -class TestEventResponse(unittest.TestCase): - """EventResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEventResponse(self): - """Test EventResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.event_response.EventResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_event_response_array.py b/test/test_event_response_array.py deleted file mode 100644 index fe94818a..00000000 --- a/test/test_event_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.event_response_array import EventResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestEventResponseArray(unittest.TestCase): - """EventResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEventResponseArray(self): - """Test EventResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.event_response_array.EventResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_event_response_change.py b/test/test_event_response_change.py deleted file mode 100644 index 61a12a24..00000000 --- a/test/test_event_response_change.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.event_response_change import EventResponseChange # noqa: E501 -from asana.rest import ApiException - - -class TestEventResponseChange(unittest.TestCase): - """EventResponseChange unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEventResponseChange(self): - """Test EventResponseChange""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.event_response_change.EventResponseChange() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_event_response_parent.py b/test/test_event_response_parent.py deleted file mode 100644 index f162d148..00000000 --- a/test/test_event_response_parent.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.event_response_parent import EventResponseParent # noqa: E501 -from asana.rest import ApiException - - -class TestEventResponseParent(unittest.TestCase): - """EventResponseParent unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEventResponseParent(self): - """Test EventResponseParent""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.event_response_parent.EventResponseParent() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_event_response_resource.py b/test/test_event_response_resource.py deleted file mode 100644 index 6d7b43a0..00000000 --- a/test/test_event_response_resource.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.event_response_resource import EventResponseResource # noqa: E501 -from asana.rest import ApiException - - -class TestEventResponseResource(unittest.TestCase): - """EventResponseResource unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEventResponseResource(self): - """Test EventResponseResource""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.event_response_resource.EventResponseResource() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_event_response_user.py b/test/test_event_response_user.py deleted file mode 100644 index 9a47eb47..00000000 --- a/test/test_event_response_user.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.event_response_user import EventResponseUser # noqa: E501 -from asana.rest import ApiException - - -class TestEventResponseUser(unittest.TestCase): - """EventResponseUser unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testEventResponseUser(self): - """Test EventResponseUser""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.event_response_user.EventResponseUser() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_events_api.py b/test/test_events_api.py deleted file mode 100644 index 5fbad0e8..00000000 --- a/test/test_events_api.py +++ /dev/null @@ -1,40 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.events_api import EventsApi # noqa: E501 -from asana.rest import ApiException - - -class TestEventsApi(unittest.TestCase): - """EventsApi unit test stubs""" - - def setUp(self): - self.api = EventsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_get_events(self): - """Test case for get_events - - Get events on a resource # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_add_subgoal_request.py b/test/test_goal_add_subgoal_request.py deleted file mode 100644 index bc62cf22..00000000 --- a/test/test_goal_add_subgoal_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_add_subgoal_request import GoalAddSubgoalRequest # noqa: E501 -from asana.rest import ApiException - - -class TestGoalAddSubgoalRequest(unittest.TestCase): - """GoalAddSubgoalRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalAddSubgoalRequest(self): - """Test GoalAddSubgoalRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_add_subgoal_request.GoalAddSubgoalRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_add_supporting_relationship_request.py b/test/test_goal_add_supporting_relationship_request.py deleted file mode 100644 index ad8abb93..00000000 --- a/test/test_goal_add_supporting_relationship_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_add_supporting_relationship_request import GoalAddSupportingRelationshipRequest # noqa: E501 -from asana.rest import ApiException - - -class TestGoalAddSupportingRelationshipRequest(unittest.TestCase): - """GoalAddSupportingRelationshipRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalAddSupportingRelationshipRequest(self): - """Test GoalAddSupportingRelationshipRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_add_supporting_relationship_request.GoalAddSupportingRelationshipRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_add_supporting_work_request.py b/test/test_goal_add_supporting_work_request.py deleted file mode 100644 index e79f886f..00000000 --- a/test/test_goal_add_supporting_work_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_add_supporting_work_request import GoalAddSupportingWorkRequest # noqa: E501 -from asana.rest import ApiException - - -class TestGoalAddSupportingWorkRequest(unittest.TestCase): - """GoalAddSupportingWorkRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalAddSupportingWorkRequest(self): - """Test GoalAddSupportingWorkRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_add_supporting_work_request.GoalAddSupportingWorkRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_base.py b/test/test_goal_base.py deleted file mode 100644 index 5f7b1930..00000000 --- a/test/test_goal_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_base import GoalBase # noqa: E501 -from asana.rest import ApiException - - -class TestGoalBase(unittest.TestCase): - """GoalBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalBase(self): - """Test GoalBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_base.GoalBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_compact.py b/test/test_goal_compact.py deleted file mode 100644 index 56aa41c9..00000000 --- a/test/test_goal_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_compact import GoalCompact # noqa: E501 -from asana.rest import ApiException - - -class TestGoalCompact(unittest.TestCase): - """GoalCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalCompact(self): - """Test GoalCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_compact.GoalCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_gid_add_followers_body.py b/test/test_goal_gid_add_followers_body.py deleted file mode 100644 index 40e089da..00000000 --- a/test/test_goal_gid_add_followers_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_gid_add_followers_body import GoalGidAddFollowersBody # noqa: E501 -from asana.rest import ApiException - - -class TestGoalGidAddFollowersBody(unittest.TestCase): - """GoalGidAddFollowersBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalGidAddFollowersBody(self): - """Test GoalGidAddFollowersBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_gid_add_followers_body.GoalGidAddFollowersBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_gid_add_supporting_relationship_body.py b/test/test_goal_gid_add_supporting_relationship_body.py deleted file mode 100644 index 879f7f00..00000000 --- a/test/test_goal_gid_add_supporting_relationship_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_gid_add_supporting_relationship_body import GoalGidAddSupportingRelationshipBody # noqa: E501 -from asana.rest import ApiException - - -class TestGoalGidAddSupportingRelationshipBody(unittest.TestCase): - """GoalGidAddSupportingRelationshipBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalGidAddSupportingRelationshipBody(self): - """Test GoalGidAddSupportingRelationshipBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_gid_add_supporting_relationship_body.GoalGidAddSupportingRelationshipBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_gid_remove_followers_body.py b/test/test_goal_gid_remove_followers_body.py deleted file mode 100644 index c0a3688f..00000000 --- a/test/test_goal_gid_remove_followers_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_gid_remove_followers_body import GoalGidRemoveFollowersBody # noqa: E501 -from asana.rest import ApiException - - -class TestGoalGidRemoveFollowersBody(unittest.TestCase): - """GoalGidRemoveFollowersBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalGidRemoveFollowersBody(self): - """Test GoalGidRemoveFollowersBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_gid_remove_followers_body.GoalGidRemoveFollowersBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_gid_remove_supporting_relationship_body.py b/test/test_goal_gid_remove_supporting_relationship_body.py deleted file mode 100644 index 4b948cc8..00000000 --- a/test/test_goal_gid_remove_supporting_relationship_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_gid_remove_supporting_relationship_body import GoalGidRemoveSupportingRelationshipBody # noqa: E501 -from asana.rest import ApiException - - -class TestGoalGidRemoveSupportingRelationshipBody(unittest.TestCase): - """GoalGidRemoveSupportingRelationshipBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalGidRemoveSupportingRelationshipBody(self): - """Test GoalGidRemoveSupportingRelationshipBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_gid_remove_supporting_relationship_body.GoalGidRemoveSupportingRelationshipBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_gid_set_metric_body.py b/test/test_goal_gid_set_metric_body.py deleted file mode 100644 index 31d1c431..00000000 --- a/test/test_goal_gid_set_metric_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_gid_set_metric_body import GoalGidSetMetricBody # noqa: E501 -from asana.rest import ApiException - - -class TestGoalGidSetMetricBody(unittest.TestCase): - """GoalGidSetMetricBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalGidSetMetricBody(self): - """Test GoalGidSetMetricBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_gid_set_metric_body.GoalGidSetMetricBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_gid_set_metric_current_value_body.py b/test/test_goal_gid_set_metric_current_value_body.py deleted file mode 100644 index c48df1de..00000000 --- a/test/test_goal_gid_set_metric_current_value_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_gid_set_metric_current_value_body import GoalGidSetMetricCurrentValueBody # noqa: E501 -from asana.rest import ApiException - - -class TestGoalGidSetMetricCurrentValueBody(unittest.TestCase): - """GoalGidSetMetricCurrentValueBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalGidSetMetricCurrentValueBody(self): - """Test GoalGidSetMetricCurrentValueBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_gid_set_metric_current_value_body.GoalGidSetMetricCurrentValueBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_membership_base.py b/test/test_goal_membership_base.py deleted file mode 100644 index 7917012b..00000000 --- a/test/test_goal_membership_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_membership_base import GoalMembershipBase # noqa: E501 -from asana.rest import ApiException - - -class TestGoalMembershipBase(unittest.TestCase): - """GoalMembershipBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalMembershipBase(self): - """Test GoalMembershipBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_membership_base.GoalMembershipBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_membership_base_goal.py b/test/test_goal_membership_base_goal.py deleted file mode 100644 index d932f111..00000000 --- a/test/test_goal_membership_base_goal.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_membership_base_goal import GoalMembershipBaseGoal # noqa: E501 -from asana.rest import ApiException - - -class TestGoalMembershipBaseGoal(unittest.TestCase): - """GoalMembershipBaseGoal unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalMembershipBaseGoal(self): - """Test GoalMembershipBaseGoal""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_membership_base_goal.GoalMembershipBaseGoal() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_membership_compact.py b/test/test_goal_membership_compact.py deleted file mode 100644 index 175b7679..00000000 --- a/test/test_goal_membership_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_membership_compact import GoalMembershipCompact # noqa: E501 -from asana.rest import ApiException - - -class TestGoalMembershipCompact(unittest.TestCase): - """GoalMembershipCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalMembershipCompact(self): - """Test GoalMembershipCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_membership_compact.GoalMembershipCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_membership_response.py b/test/test_goal_membership_response.py deleted file mode 100644 index 8b1771b4..00000000 --- a/test/test_goal_membership_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_membership_response import GoalMembershipResponse # noqa: E501 -from asana.rest import ApiException - - -class TestGoalMembershipResponse(unittest.TestCase): - """GoalMembershipResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalMembershipResponse(self): - """Test GoalMembershipResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_membership_response.GoalMembershipResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_membership_response_user.py b/test/test_goal_membership_response_user.py deleted file mode 100644 index 1372e083..00000000 --- a/test/test_goal_membership_response_user.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_membership_response_user import GoalMembershipResponseUser # noqa: E501 -from asana.rest import ApiException - - -class TestGoalMembershipResponseUser(unittest.TestCase): - """GoalMembershipResponseUser unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalMembershipResponseUser(self): - """Test GoalMembershipResponseUser""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_membership_response_user.GoalMembershipResponseUser() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_membership_response_workspace.py b/test/test_goal_membership_response_workspace.py deleted file mode 100644 index 1ea4384a..00000000 --- a/test/test_goal_membership_response_workspace.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_membership_response_workspace import GoalMembershipResponseWorkspace # noqa: E501 -from asana.rest import ApiException - - -class TestGoalMembershipResponseWorkspace(unittest.TestCase): - """GoalMembershipResponseWorkspace unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalMembershipResponseWorkspace(self): - """Test GoalMembershipResponseWorkspace""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_membership_response_workspace.GoalMembershipResponseWorkspace() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_metric_base.py b/test/test_goal_metric_base.py deleted file mode 100644 index edf50370..00000000 --- a/test/test_goal_metric_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_metric_base import GoalMetricBase # noqa: E501 -from asana.rest import ApiException - - -class TestGoalMetricBase(unittest.TestCase): - """GoalMetricBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalMetricBase(self): - """Test GoalMetricBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_metric_base.GoalMetricBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_metric_current_value_request.py b/test/test_goal_metric_current_value_request.py deleted file mode 100644 index 37ae3062..00000000 --- a/test/test_goal_metric_current_value_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_metric_current_value_request import GoalMetricCurrentValueRequest # noqa: E501 -from asana.rest import ApiException - - -class TestGoalMetricCurrentValueRequest(unittest.TestCase): - """GoalMetricCurrentValueRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalMetricCurrentValueRequest(self): - """Test GoalMetricCurrentValueRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_metric_current_value_request.GoalMetricCurrentValueRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_metric_request.py b/test/test_goal_metric_request.py deleted file mode 100644 index 68503a84..00000000 --- a/test/test_goal_metric_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_metric_request import GoalMetricRequest # noqa: E501 -from asana.rest import ApiException - - -class TestGoalMetricRequest(unittest.TestCase): - """GoalMetricRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalMetricRequest(self): - """Test GoalMetricRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_metric_request.GoalMetricRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_relationship_base.py b/test/test_goal_relationship_base.py deleted file mode 100644 index 296fa39d..00000000 --- a/test/test_goal_relationship_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_relationship_base import GoalRelationshipBase # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRelationshipBase(unittest.TestCase): - """GoalRelationshipBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalRelationshipBase(self): - """Test GoalRelationshipBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_relationship_base.GoalRelationshipBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_relationship_base_supported_goal.py b/test/test_goal_relationship_base_supported_goal.py deleted file mode 100644 index 13745f10..00000000 --- a/test/test_goal_relationship_base_supported_goal.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_relationship_base_supported_goal import GoalRelationshipBaseSupportedGoal # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRelationshipBaseSupportedGoal(unittest.TestCase): - """GoalRelationshipBaseSupportedGoal unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalRelationshipBaseSupportedGoal(self): - """Test GoalRelationshipBaseSupportedGoal""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_relationship_base_supported_goal.GoalRelationshipBaseSupportedGoal() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_relationship_base_supporting_resource.py b/test/test_goal_relationship_base_supporting_resource.py deleted file mode 100644 index 00b7c2cf..00000000 --- a/test/test_goal_relationship_base_supporting_resource.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_relationship_base_supporting_resource import GoalRelationshipBaseSupportingResource # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRelationshipBaseSupportingResource(unittest.TestCase): - """GoalRelationshipBaseSupportingResource unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalRelationshipBaseSupportingResource(self): - """Test GoalRelationshipBaseSupportingResource""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_relationship_base_supporting_resource.GoalRelationshipBaseSupportingResource() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_relationship_compact.py b/test/test_goal_relationship_compact.py deleted file mode 100644 index d2b3b960..00000000 --- a/test/test_goal_relationship_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_relationship_compact import GoalRelationshipCompact # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRelationshipCompact(unittest.TestCase): - """GoalRelationshipCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalRelationshipCompact(self): - """Test GoalRelationshipCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_relationship_compact.GoalRelationshipCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_relationship_request.py b/test/test_goal_relationship_request.py deleted file mode 100644 index dd7250f7..00000000 --- a/test/test_goal_relationship_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_relationship_request import GoalRelationshipRequest # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRelationshipRequest(unittest.TestCase): - """GoalRelationshipRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalRelationshipRequest(self): - """Test GoalRelationshipRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_relationship_request.GoalRelationshipRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_relationship_response.py b/test/test_goal_relationship_response.py deleted file mode 100644 index 123eed2f..00000000 --- a/test/test_goal_relationship_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_relationship_response import GoalRelationshipResponse # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRelationshipResponse(unittest.TestCase): - """GoalRelationshipResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalRelationshipResponse(self): - """Test GoalRelationshipResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_relationship_response.GoalRelationshipResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_relationship_response_array.py b/test/test_goal_relationship_response_array.py deleted file mode 100644 index cddbdd90..00000000 --- a/test/test_goal_relationship_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_relationship_response_array import GoalRelationshipResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRelationshipResponseArray(unittest.TestCase): - """GoalRelationshipResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalRelationshipResponseArray(self): - """Test GoalRelationshipResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_relationship_response_array.GoalRelationshipResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_relationship_response_data.py b/test/test_goal_relationship_response_data.py deleted file mode 100644 index c462f1ae..00000000 --- a/test/test_goal_relationship_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_relationship_response_data import GoalRelationshipResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRelationshipResponseData(unittest.TestCase): - """GoalRelationshipResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalRelationshipResponseData(self): - """Test GoalRelationshipResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_relationship_response_data.GoalRelationshipResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_relationships_api.py b/test/test_goal_relationships_api.py deleted file mode 100644 index 456e02f1..00000000 --- a/test/test_goal_relationships_api.py +++ /dev/null @@ -1,68 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.goal_relationships_api import GoalRelationshipsApi # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRelationshipsApi(unittest.TestCase): - """GoalRelationshipsApi unit test stubs""" - - def setUp(self): - self.api = GoalRelationshipsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_add_supporting_relationship(self): - """Test case for add_supporting_relationship - - Add a supporting goal relationship # noqa: E501 - """ - pass - - def test_get_goal_relationship(self): - """Test case for get_goal_relationship - - Get a goal relationship # noqa: E501 - """ - pass - - def test_get_goal_relationships(self): - """Test case for get_goal_relationships - - Get goal relationships # noqa: E501 - """ - pass - - def test_remove_supporting_relationship(self): - """Test case for remove_supporting_relationship - - Removes a supporting goal relationship # noqa: E501 - """ - pass - - def test_update_goal_relationship(self): - """Test case for update_goal_relationship - - Update a goal relationship # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_relationships_goal_relationship_gid_body.py b/test/test_goal_relationships_goal_relationship_gid_body.py deleted file mode 100644 index 1634cbf1..00000000 --- a/test/test_goal_relationships_goal_relationship_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_relationships_goal_relationship_gid_body import GoalRelationshipsGoalRelationshipGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRelationshipsGoalRelationshipGidBody(unittest.TestCase): - """GoalRelationshipsGoalRelationshipGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalRelationshipsGoalRelationshipGidBody(self): - """Test GoalRelationshipsGoalRelationshipGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_relationships_goal_relationship_gid_body.GoalRelationshipsGoalRelationshipGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_remove_subgoal_request.py b/test/test_goal_remove_subgoal_request.py deleted file mode 100644 index 5a4c6d25..00000000 --- a/test/test_goal_remove_subgoal_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_remove_subgoal_request import GoalRemoveSubgoalRequest # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRemoveSubgoalRequest(unittest.TestCase): - """GoalRemoveSubgoalRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalRemoveSubgoalRequest(self): - """Test GoalRemoveSubgoalRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_remove_subgoal_request.GoalRemoveSubgoalRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_remove_supporting_relationship_request.py b/test/test_goal_remove_supporting_relationship_request.py deleted file mode 100644 index 87deca55..00000000 --- a/test/test_goal_remove_supporting_relationship_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_remove_supporting_relationship_request import GoalRemoveSupportingRelationshipRequest # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRemoveSupportingRelationshipRequest(unittest.TestCase): - """GoalRemoveSupportingRelationshipRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalRemoveSupportingRelationshipRequest(self): - """Test GoalRemoveSupportingRelationshipRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_remove_supporting_relationship_request.GoalRemoveSupportingRelationshipRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_request.py b/test/test_goal_request.py deleted file mode 100644 index b245f026..00000000 --- a/test/test_goal_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_request import GoalRequest # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRequest(unittest.TestCase): - """GoalRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalRequest(self): - """Test GoalRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_request.GoalRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_request_base.py b/test/test_goal_request_base.py deleted file mode 100644 index 65e88963..00000000 --- a/test/test_goal_request_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_request_base import GoalRequestBase # noqa: E501 -from asana.rest import ApiException - - -class TestGoalRequestBase(unittest.TestCase): - """GoalRequestBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalRequestBase(self): - """Test GoalRequestBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_request_base.GoalRequestBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_response.py b/test/test_goal_response.py deleted file mode 100644 index f653ee40..00000000 --- a/test/test_goal_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_response import GoalResponse # noqa: E501 -from asana.rest import ApiException - - -class TestGoalResponse(unittest.TestCase): - """GoalResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalResponse(self): - """Test GoalResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_response.GoalResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_response_array.py b/test/test_goal_response_array.py deleted file mode 100644 index 4447ef34..00000000 --- a/test/test_goal_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_response_array import GoalResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestGoalResponseArray(unittest.TestCase): - """GoalResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalResponseArray(self): - """Test GoalResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_response_array.GoalResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_response_current_status_update.py b/test/test_goal_response_current_status_update.py deleted file mode 100644 index 4c96fced..00000000 --- a/test/test_goal_response_current_status_update.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_response_current_status_update import GoalResponseCurrentStatusUpdate # noqa: E501 -from asana.rest import ApiException - - -class TestGoalResponseCurrentStatusUpdate(unittest.TestCase): - """GoalResponseCurrentStatusUpdate unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalResponseCurrentStatusUpdate(self): - """Test GoalResponseCurrentStatusUpdate""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_response_current_status_update.GoalResponseCurrentStatusUpdate() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_response_data.py b/test/test_goal_response_data.py deleted file mode 100644 index 026a26e6..00000000 --- a/test/test_goal_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_response_data import GoalResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestGoalResponseData(unittest.TestCase): - """GoalResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalResponseData(self): - """Test GoalResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_response_data.GoalResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_response_likes.py b/test/test_goal_response_likes.py deleted file mode 100644 index ecbf877e..00000000 --- a/test/test_goal_response_likes.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_response_likes import GoalResponseLikes # noqa: E501 -from asana.rest import ApiException - - -class TestGoalResponseLikes(unittest.TestCase): - """GoalResponseLikes unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalResponseLikes(self): - """Test GoalResponseLikes""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_response_likes.GoalResponseLikes() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_response_metric.py b/test/test_goal_response_metric.py deleted file mode 100644 index f8607ef7..00000000 --- a/test/test_goal_response_metric.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_response_metric import GoalResponseMetric # noqa: E501 -from asana.rest import ApiException - - -class TestGoalResponseMetric(unittest.TestCase): - """GoalResponseMetric unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalResponseMetric(self): - """Test GoalResponseMetric""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_response_metric.GoalResponseMetric() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_response_team.py b/test/test_goal_response_team.py deleted file mode 100644 index b568c4d5..00000000 --- a/test/test_goal_response_team.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_response_team import GoalResponseTeam # noqa: E501 -from asana.rest import ApiException - - -class TestGoalResponseTeam(unittest.TestCase): - """GoalResponseTeam unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalResponseTeam(self): - """Test GoalResponseTeam""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_response_team.GoalResponseTeam() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_response_time_period.py b/test/test_goal_response_time_period.py deleted file mode 100644 index 9c7a2aa9..00000000 --- a/test/test_goal_response_time_period.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_response_time_period import GoalResponseTimePeriod # noqa: E501 -from asana.rest import ApiException - - -class TestGoalResponseTimePeriod(unittest.TestCase): - """GoalResponseTimePeriod unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalResponseTimePeriod(self): - """Test GoalResponseTimePeriod""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_response_time_period.GoalResponseTimePeriod() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_response_workspace.py b/test/test_goal_response_workspace.py deleted file mode 100644 index 433e8312..00000000 --- a/test/test_goal_response_workspace.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_response_workspace import GoalResponseWorkspace # noqa: E501 -from asana.rest import ApiException - - -class TestGoalResponseWorkspace(unittest.TestCase): - """GoalResponseWorkspace unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalResponseWorkspace(self): - """Test GoalResponseWorkspace""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_response_workspace.GoalResponseWorkspace() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goal_update_request.py b/test/test_goal_update_request.py deleted file mode 100644 index eb6b3d6d..00000000 --- a/test/test_goal_update_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goal_update_request import GoalUpdateRequest # noqa: E501 -from asana.rest import ApiException - - -class TestGoalUpdateRequest(unittest.TestCase): - """GoalUpdateRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalUpdateRequest(self): - """Test GoalUpdateRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goal_update_request.GoalUpdateRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goals_api.py b/test/test_goals_api.py deleted file mode 100644 index 746e7324..00000000 --- a/test/test_goals_api.py +++ /dev/null @@ -1,103 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.goals_api import GoalsApi # noqa: E501 -from asana.rest import ApiException - - -class TestGoalsApi(unittest.TestCase): - """GoalsApi unit test stubs""" - - def setUp(self): - self.api = GoalsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_add_followers(self): - """Test case for add_followers - - Add a collaborator to a goal # noqa: E501 - """ - pass - - def test_create_goal(self): - """Test case for create_goal - - Create a goal # noqa: E501 - """ - pass - - def test_create_goal_metric(self): - """Test case for create_goal_metric - - Create a goal metric # noqa: E501 - """ - pass - - def test_delete_goal(self): - """Test case for delete_goal - - Delete a goal # noqa: E501 - """ - pass - - def test_get_goal(self): - """Test case for get_goal - - Get a goal # noqa: E501 - """ - pass - - def test_get_goals(self): - """Test case for get_goals - - Get goals # noqa: E501 - """ - pass - - def test_get_parent_goals_for_goal(self): - """Test case for get_parent_goals_for_goal - - Get parent goals from a goal # noqa: E501 - """ - pass - - def test_remove_followers(self): - """Test case for remove_followers - - Remove a collaborator from a goal # noqa: E501 - """ - pass - - def test_update_goal(self): - """Test case for update_goal - - Update a goal # noqa: E501 - """ - pass - - def test_update_goal_metric(self): - """Test case for update_goal_metric - - Update a goal metric # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goals_body.py b/test/test_goals_body.py deleted file mode 100644 index 5c6d5645..00000000 --- a/test/test_goals_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goals_body import GoalsBody # noqa: E501 -from asana.rest import ApiException - - -class TestGoalsBody(unittest.TestCase): - """GoalsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalsBody(self): - """Test GoalsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goals_body.GoalsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_goals_goal_gid_body.py b/test/test_goals_goal_gid_body.py deleted file mode 100644 index aff63fb8..00000000 --- a/test/test_goals_goal_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.goals_goal_gid_body import GoalsGoalGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestGoalsGoalGidBody(unittest.TestCase): - """GoalsGoalGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testGoalsGoalGidBody(self): - """Test GoalsGoalGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.goals_goal_gid_body.GoalsGoalGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_inline_response412.py b/test/test_inline_response412.py deleted file mode 100644 index 55691896..00000000 --- a/test/test_inline_response412.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.inline_response412 import InlineResponse412 # noqa: E501 -from asana.rest import ApiException - - -class TestInlineResponse412(unittest.TestCase): - """InlineResponse412 unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testInlineResponse412(self): - """Test InlineResponse412""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.inline_response412.InlineResponse412() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_inline_response412_errors.py b/test/test_inline_response412_errors.py deleted file mode 100644 index ea5db106..00000000 --- a/test/test_inline_response412_errors.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.inline_response412_errors import InlineResponse412Errors # noqa: E501 -from asana.rest import ApiException - - -class TestInlineResponse412Errors(unittest.TestCase): - """InlineResponse412Errors unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testInlineResponse412Errors(self): - """Test InlineResponse412Errors""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.inline_response412_errors.InlineResponse412Errors() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_job_base.py b/test/test_job_base.py deleted file mode 100644 index 134b88cb..00000000 --- a/test/test_job_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.job_base import JobBase # noqa: E501 -from asana.rest import ApiException - - -class TestJobBase(unittest.TestCase): - """JobBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testJobBase(self): - """Test JobBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.job_base.JobBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_job_base_new_project.py b/test/test_job_base_new_project.py deleted file mode 100644 index dd6fc700..00000000 --- a/test/test_job_base_new_project.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.job_base_new_project import JobBaseNewProject # noqa: E501 -from asana.rest import ApiException - - -class TestJobBaseNewProject(unittest.TestCase): - """JobBaseNewProject unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testJobBaseNewProject(self): - """Test JobBaseNewProject""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.job_base_new_project.JobBaseNewProject() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_job_base_new_project_template.py b/test/test_job_base_new_project_template.py deleted file mode 100644 index 9f1ce499..00000000 --- a/test/test_job_base_new_project_template.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.job_base_new_project_template import JobBaseNewProjectTemplate # noqa: E501 -from asana.rest import ApiException - - -class TestJobBaseNewProjectTemplate(unittest.TestCase): - """JobBaseNewProjectTemplate unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testJobBaseNewProjectTemplate(self): - """Test JobBaseNewProjectTemplate""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.job_base_new_project_template.JobBaseNewProjectTemplate() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_job_base_new_task.py b/test/test_job_base_new_task.py deleted file mode 100644 index 0d46d4a8..00000000 --- a/test/test_job_base_new_task.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.job_base_new_task import JobBaseNewTask # noqa: E501 -from asana.rest import ApiException - - -class TestJobBaseNewTask(unittest.TestCase): - """JobBaseNewTask unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testJobBaseNewTask(self): - """Test JobBaseNewTask""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.job_base_new_task.JobBaseNewTask() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_job_compact.py b/test/test_job_compact.py deleted file mode 100644 index bdf2a16c..00000000 --- a/test/test_job_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.job_compact import JobCompact # noqa: E501 -from asana.rest import ApiException - - -class TestJobCompact(unittest.TestCase): - """JobCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testJobCompact(self): - """Test JobCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.job_compact.JobCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_job_response.py b/test/test_job_response.py deleted file mode 100644 index 8c67406a..00000000 --- a/test/test_job_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.job_response import JobResponse # noqa: E501 -from asana.rest import ApiException - - -class TestJobResponse(unittest.TestCase): - """JobResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testJobResponse(self): - """Test JobResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.job_response.JobResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_job_response_data.py b/test/test_job_response_data.py deleted file mode 100644 index e924cccb..00000000 --- a/test/test_job_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.job_response_data import JobResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestJobResponseData(unittest.TestCase): - """JobResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testJobResponseData(self): - """Test JobResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.job_response_data.JobResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_jobs_api.py b/test/test_jobs_api.py deleted file mode 100644 index 88fe30f7..00000000 --- a/test/test_jobs_api.py +++ /dev/null @@ -1,40 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.jobs_api import JobsApi # noqa: E501 -from asana.rest import ApiException - - -class TestJobsApi(unittest.TestCase): - """JobsApi unit test stubs""" - - def setUp(self): - self.api = JobsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_get_job(self): - """Test case for get_job - - Get a job by id # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_like.py b/test/test_like.py deleted file mode 100644 index d919af59..00000000 --- a/test/test_like.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.like import Like # noqa: E501 -from asana.rest import ApiException - - -class TestLike(unittest.TestCase): - """Like unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testLike(self): - """Test Like""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.like.Like() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_member_compact.py b/test/test_member_compact.py deleted file mode 100644 index bfe68176..00000000 --- a/test/test_member_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.member_compact import MemberCompact # noqa: E501 -from asana.rest import ApiException - - -class TestMemberCompact(unittest.TestCase): - """MemberCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testMemberCompact(self): - """Test MemberCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.member_compact.MemberCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_membership_compact.py b/test/test_membership_compact.py deleted file mode 100644 index 77421fc2..00000000 --- a/test/test_membership_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.membership_compact import MembershipCompact # noqa: E501 -from asana.rest import ApiException - - -class TestMembershipCompact(unittest.TestCase): - """MembershipCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testMembershipCompact(self): - """Test MembershipCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.membership_compact.MembershipCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_membership_compact_goal.py b/test/test_membership_compact_goal.py deleted file mode 100644 index 08c9dc77..00000000 --- a/test/test_membership_compact_goal.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.membership_compact_goal import MembershipCompactGoal # noqa: E501 -from asana.rest import ApiException - - -class TestMembershipCompactGoal(unittest.TestCase): - """MembershipCompactGoal unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testMembershipCompactGoal(self): - """Test MembershipCompactGoal""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.membership_compact_goal.MembershipCompactGoal() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_membership_compact_member.py b/test/test_membership_compact_member.py deleted file mode 100644 index f85ca4fb..00000000 --- a/test/test_membership_compact_member.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.membership_compact_member import MembershipCompactMember # noqa: E501 -from asana.rest import ApiException - - -class TestMembershipCompactMember(unittest.TestCase): - """MembershipCompactMember unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testMembershipCompactMember(self): - """Test MembershipCompactMember""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.membership_compact_member.MembershipCompactMember() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_membership_compact_parent.py b/test/test_membership_compact_parent.py deleted file mode 100644 index 138743d1..00000000 --- a/test/test_membership_compact_parent.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.membership_compact_parent import MembershipCompactParent # noqa: E501 -from asana.rest import ApiException - - -class TestMembershipCompactParent(unittest.TestCase): - """MembershipCompactParent unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testMembershipCompactParent(self): - """Test MembershipCompactParent""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.membership_compact_parent.MembershipCompactParent() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_membership_request.py b/test/test_membership_request.py deleted file mode 100644 index f608d00c..00000000 --- a/test/test_membership_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.membership_request import MembershipRequest # noqa: E501 -from asana.rest import ApiException - - -class TestMembershipRequest(unittest.TestCase): - """MembershipRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testMembershipRequest(self): - """Test MembershipRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.membership_request.MembershipRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_membership_response.py b/test/test_membership_response.py deleted file mode 100644 index 3e3b2b8f..00000000 --- a/test/test_membership_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.membership_response import MembershipResponse # noqa: E501 -from asana.rest import ApiException - - -class TestMembershipResponse(unittest.TestCase): - """MembershipResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testMembershipResponse(self): - """Test MembershipResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.membership_response.MembershipResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_membership_response_array.py b/test/test_membership_response_array.py deleted file mode 100644 index 507e9399..00000000 --- a/test/test_membership_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.membership_response_array import MembershipResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestMembershipResponseArray(unittest.TestCase): - """MembershipResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testMembershipResponseArray(self): - """Test MembershipResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.membership_response_array.MembershipResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_membership_response_data.py b/test/test_membership_response_data.py deleted file mode 100644 index 6f58622e..00000000 --- a/test/test_membership_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.membership_response_data import MembershipResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestMembershipResponseData(unittest.TestCase): - """MembershipResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testMembershipResponseData(self): - """Test MembershipResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.membership_response_data.MembershipResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_memberships_api.py b/test/test_memberships_api.py deleted file mode 100644 index f4de40d3..00000000 --- a/test/test_memberships_api.py +++ /dev/null @@ -1,54 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.memberships_api import MembershipsApi # noqa: E501 -from asana.rest import ApiException - - -class TestMembershipsApi(unittest.TestCase): - """MembershipsApi unit test stubs""" - - def setUp(self): - self.api = MembershipsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_create_membership(self): - """Test case for create_membership - - Create a membership # noqa: E501 - """ - pass - - def test_delete_membership(self): - """Test case for delete_membership - - Delete a membership # noqa: E501 - """ - pass - - def test_get_memberships(self): - """Test case for get_memberships - - Get multiple memberships # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_memberships_body.py b/test/test_memberships_body.py deleted file mode 100644 index fe7d7556..00000000 --- a/test/test_memberships_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.memberships_body import MembershipsBody # noqa: E501 -from asana.rest import ApiException - - -class TestMembershipsBody(unittest.TestCase): - """MembershipsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testMembershipsBody(self): - """Test MembershipsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.memberships_body.MembershipsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_modify_dependencies_request.py b/test/test_modify_dependencies_request.py deleted file mode 100644 index 6ecd04ac..00000000 --- a/test/test_modify_dependencies_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.modify_dependencies_request import ModifyDependenciesRequest # noqa: E501 -from asana.rest import ApiException - - -class TestModifyDependenciesRequest(unittest.TestCase): - """ModifyDependenciesRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testModifyDependenciesRequest(self): - """Test ModifyDependenciesRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.modify_dependencies_request.ModifyDependenciesRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_modify_dependents_request.py b/test/test_modify_dependents_request.py deleted file mode 100644 index f16974bf..00000000 --- a/test/test_modify_dependents_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.modify_dependents_request import ModifyDependentsRequest # noqa: E501 -from asana.rest import ApiException - - -class TestModifyDependentsRequest(unittest.TestCase): - """ModifyDependentsRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testModifyDependentsRequest(self): - """Test ModifyDependentsRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.modify_dependents_request.ModifyDependentsRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_next_page.py b/test/test_next_page.py deleted file mode 100644 index 31350603..00000000 --- a/test/test_next_page.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.next_page import NextPage # noqa: E501 -from asana.rest import ApiException - - -class TestNextPage(unittest.TestCase): - """NextPage unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testNextPage(self): - """Test NextPage""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.next_page.NextPage() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_organization_export_base.py b/test/test_organization_export_base.py deleted file mode 100644 index 4d116777..00000000 --- a/test/test_organization_export_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.organization_export_base import OrganizationExportBase # noqa: E501 -from asana.rest import ApiException - - -class TestOrganizationExportBase(unittest.TestCase): - """OrganizationExportBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testOrganizationExportBase(self): - """Test OrganizationExportBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.organization_export_base.OrganizationExportBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_organization_export_compact.py b/test/test_organization_export_compact.py deleted file mode 100644 index a51592f9..00000000 --- a/test/test_organization_export_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.organization_export_compact import OrganizationExportCompact # noqa: E501 -from asana.rest import ApiException - - -class TestOrganizationExportCompact(unittest.TestCase): - """OrganizationExportCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testOrganizationExportCompact(self): - """Test OrganizationExportCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.organization_export_compact.OrganizationExportCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_organization_export_request.py b/test/test_organization_export_request.py deleted file mode 100644 index ade44c30..00000000 --- a/test/test_organization_export_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.organization_export_request import OrganizationExportRequest # noqa: E501 -from asana.rest import ApiException - - -class TestOrganizationExportRequest(unittest.TestCase): - """OrganizationExportRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testOrganizationExportRequest(self): - """Test OrganizationExportRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.organization_export_request.OrganizationExportRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_organization_export_response.py b/test/test_organization_export_response.py deleted file mode 100644 index bf233776..00000000 --- a/test/test_organization_export_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.organization_export_response import OrganizationExportResponse # noqa: E501 -from asana.rest import ApiException - - -class TestOrganizationExportResponse(unittest.TestCase): - """OrganizationExportResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testOrganizationExportResponse(self): - """Test OrganizationExportResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.organization_export_response.OrganizationExportResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_organization_export_response_data.py b/test/test_organization_export_response_data.py deleted file mode 100644 index ad0dca07..00000000 --- a/test/test_organization_export_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.organization_export_response_data import OrganizationExportResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestOrganizationExportResponseData(unittest.TestCase): - """OrganizationExportResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testOrganizationExportResponseData(self): - """Test OrganizationExportResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.organization_export_response_data.OrganizationExportResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_organization_exports_api.py b/test/test_organization_exports_api.py deleted file mode 100644 index 3450ffbd..00000000 --- a/test/test_organization_exports_api.py +++ /dev/null @@ -1,47 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.organization_exports_api import OrganizationExportsApi # noqa: E501 -from asana.rest import ApiException - - -class TestOrganizationExportsApi(unittest.TestCase): - """OrganizationExportsApi unit test stubs""" - - def setUp(self): - self.api = OrganizationExportsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_create_organization_export(self): - """Test case for create_organization_export - - Create an organization export request # noqa: E501 - """ - pass - - def test_get_organization_export(self): - """Test case for get_organization_export - - Get details on an org export request # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_organization_exports_body.py b/test/test_organization_exports_body.py deleted file mode 100644 index 50c6b9ff..00000000 --- a/test/test_organization_exports_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.organization_exports_body import OrganizationExportsBody # noqa: E501 -from asana.rest import ApiException - - -class TestOrganizationExportsBody(unittest.TestCase): - """OrganizationExportsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testOrganizationExportsBody(self): - """Test OrganizationExportsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.organization_exports_body.OrganizationExportsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_add_item_request.py b/test/test_portfolio_add_item_request.py deleted file mode 100644 index ad7d913a..00000000 --- a/test/test_portfolio_add_item_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_add_item_request import PortfolioAddItemRequest # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioAddItemRequest(unittest.TestCase): - """PortfolioAddItemRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioAddItemRequest(self): - """Test PortfolioAddItemRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_add_item_request.PortfolioAddItemRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_base.py b/test/test_portfolio_base.py deleted file mode 100644 index fba2ad14..00000000 --- a/test/test_portfolio_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_base import PortfolioBase # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioBase(unittest.TestCase): - """PortfolioBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioBase(self): - """Test PortfolioBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_base.PortfolioBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_compact.py b/test/test_portfolio_compact.py deleted file mode 100644 index 3e24ecd0..00000000 --- a/test/test_portfolio_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_compact import PortfolioCompact # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioCompact(unittest.TestCase): - """PortfolioCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioCompact(self): - """Test PortfolioCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_compact.PortfolioCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_gid_add_custom_field_setting_body.py b/test/test_portfolio_gid_add_custom_field_setting_body.py deleted file mode 100644 index d279dca0..00000000 --- a/test/test_portfolio_gid_add_custom_field_setting_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_gid_add_custom_field_setting_body import PortfolioGidAddCustomFieldSettingBody # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioGidAddCustomFieldSettingBody(unittest.TestCase): - """PortfolioGidAddCustomFieldSettingBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioGidAddCustomFieldSettingBody(self): - """Test PortfolioGidAddCustomFieldSettingBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_gid_add_custom_field_setting_body.PortfolioGidAddCustomFieldSettingBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_gid_add_item_body.py b/test/test_portfolio_gid_add_item_body.py deleted file mode 100644 index d3361e9a..00000000 --- a/test/test_portfolio_gid_add_item_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_gid_add_item_body import PortfolioGidAddItemBody # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioGidAddItemBody(unittest.TestCase): - """PortfolioGidAddItemBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioGidAddItemBody(self): - """Test PortfolioGidAddItemBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_gid_add_item_body.PortfolioGidAddItemBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_gid_add_members_body.py b/test/test_portfolio_gid_add_members_body.py deleted file mode 100644 index ff519cea..00000000 --- a/test/test_portfolio_gid_add_members_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_gid_add_members_body import PortfolioGidAddMembersBody # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioGidAddMembersBody(unittest.TestCase): - """PortfolioGidAddMembersBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioGidAddMembersBody(self): - """Test PortfolioGidAddMembersBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_gid_add_members_body.PortfolioGidAddMembersBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_gid_remove_custom_field_setting_body.py b/test/test_portfolio_gid_remove_custom_field_setting_body.py deleted file mode 100644 index cdd892cf..00000000 --- a/test/test_portfolio_gid_remove_custom_field_setting_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_gid_remove_custom_field_setting_body import PortfolioGidRemoveCustomFieldSettingBody # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioGidRemoveCustomFieldSettingBody(unittest.TestCase): - """PortfolioGidRemoveCustomFieldSettingBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioGidRemoveCustomFieldSettingBody(self): - """Test PortfolioGidRemoveCustomFieldSettingBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_gid_remove_custom_field_setting_body.PortfolioGidRemoveCustomFieldSettingBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_gid_remove_item_body.py b/test/test_portfolio_gid_remove_item_body.py deleted file mode 100644 index 7077fce9..00000000 --- a/test/test_portfolio_gid_remove_item_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_gid_remove_item_body import PortfolioGidRemoveItemBody # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioGidRemoveItemBody(unittest.TestCase): - """PortfolioGidRemoveItemBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioGidRemoveItemBody(self): - """Test PortfolioGidRemoveItemBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_gid_remove_item_body.PortfolioGidRemoveItemBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_gid_remove_members_body.py b/test/test_portfolio_gid_remove_members_body.py deleted file mode 100644 index a19871ba..00000000 --- a/test/test_portfolio_gid_remove_members_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_gid_remove_members_body import PortfolioGidRemoveMembersBody # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioGidRemoveMembersBody(unittest.TestCase): - """PortfolioGidRemoveMembersBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioGidRemoveMembersBody(self): - """Test PortfolioGidRemoveMembersBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_gid_remove_members_body.PortfolioGidRemoveMembersBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_membership_base.py b/test/test_portfolio_membership_base.py deleted file mode 100644 index 683e52be..00000000 --- a/test/test_portfolio_membership_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_membership_base import PortfolioMembershipBase # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioMembershipBase(unittest.TestCase): - """PortfolioMembershipBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioMembershipBase(self): - """Test PortfolioMembershipBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_membership_base.PortfolioMembershipBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_membership_base_portfolio.py b/test/test_portfolio_membership_base_portfolio.py deleted file mode 100644 index c161153c..00000000 --- a/test/test_portfolio_membership_base_portfolio.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_membership_base_portfolio import PortfolioMembershipBasePortfolio # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioMembershipBasePortfolio(unittest.TestCase): - """PortfolioMembershipBasePortfolio unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioMembershipBasePortfolio(self): - """Test PortfolioMembershipBasePortfolio""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_membership_base_portfolio.PortfolioMembershipBasePortfolio() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_membership_compact.py b/test/test_portfolio_membership_compact.py deleted file mode 100644 index dbebe85a..00000000 --- a/test/test_portfolio_membership_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_membership_compact import PortfolioMembershipCompact # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioMembershipCompact(unittest.TestCase): - """PortfolioMembershipCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioMembershipCompact(self): - """Test PortfolioMembershipCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_membership_compact.PortfolioMembershipCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_membership_response.py b/test/test_portfolio_membership_response.py deleted file mode 100644 index 16456864..00000000 --- a/test/test_portfolio_membership_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_membership_response import PortfolioMembershipResponse # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioMembershipResponse(unittest.TestCase): - """PortfolioMembershipResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioMembershipResponse(self): - """Test PortfolioMembershipResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_membership_response.PortfolioMembershipResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_membership_response_array.py b/test/test_portfolio_membership_response_array.py deleted file mode 100644 index 0cba1864..00000000 --- a/test/test_portfolio_membership_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_membership_response_array import PortfolioMembershipResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioMembershipResponseArray(unittest.TestCase): - """PortfolioMembershipResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioMembershipResponseArray(self): - """Test PortfolioMembershipResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_membership_response_array.PortfolioMembershipResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_membership_response_data.py b/test/test_portfolio_membership_response_data.py deleted file mode 100644 index eda6cfdb..00000000 --- a/test/test_portfolio_membership_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_membership_response_data import PortfolioMembershipResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioMembershipResponseData(unittest.TestCase): - """PortfolioMembershipResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioMembershipResponseData(self): - """Test PortfolioMembershipResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_membership_response_data.PortfolioMembershipResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_memberships_api.py b/test/test_portfolio_memberships_api.py deleted file mode 100644 index 329b11f0..00000000 --- a/test/test_portfolio_memberships_api.py +++ /dev/null @@ -1,54 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.portfolio_memberships_api import PortfolioMembershipsApi # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioMembershipsApi(unittest.TestCase): - """PortfolioMembershipsApi unit test stubs""" - - def setUp(self): - self.api = PortfolioMembershipsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_get_portfolio_membership(self): - """Test case for get_portfolio_membership - - Get a portfolio membership # noqa: E501 - """ - pass - - def test_get_portfolio_memberships(self): - """Test case for get_portfolio_memberships - - Get multiple portfolio memberships # noqa: E501 - """ - pass - - def test_get_portfolio_memberships_for_portfolio(self): - """Test case for get_portfolio_memberships_for_portfolio - - Get memberships from a portfolio # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_remove_item_request.py b/test/test_portfolio_remove_item_request.py deleted file mode 100644 index 9a1887ca..00000000 --- a/test/test_portfolio_remove_item_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_remove_item_request import PortfolioRemoveItemRequest # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioRemoveItemRequest(unittest.TestCase): - """PortfolioRemoveItemRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioRemoveItemRequest(self): - """Test PortfolioRemoveItemRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_remove_item_request.PortfolioRemoveItemRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_request.py b/test/test_portfolio_request.py deleted file mode 100644 index e7180a1f..00000000 --- a/test/test_portfolio_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_request import PortfolioRequest # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioRequest(unittest.TestCase): - """PortfolioRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioRequest(self): - """Test PortfolioRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_request.PortfolioRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_response.py b/test/test_portfolio_response.py deleted file mode 100644 index 048d8300..00000000 --- a/test/test_portfolio_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_response import PortfolioResponse # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioResponse(unittest.TestCase): - """PortfolioResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioResponse(self): - """Test PortfolioResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_response.PortfolioResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_response_array.py b/test/test_portfolio_response_array.py deleted file mode 100644 index eb9909c7..00000000 --- a/test/test_portfolio_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_response_array import PortfolioResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioResponseArray(unittest.TestCase): - """PortfolioResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioResponseArray(self): - """Test PortfolioResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_response_array.PortfolioResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_response_current_status_update.py b/test/test_portfolio_response_current_status_update.py deleted file mode 100644 index c11a89d6..00000000 --- a/test/test_portfolio_response_current_status_update.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_response_current_status_update import PortfolioResponseCurrentStatusUpdate # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioResponseCurrentStatusUpdate(unittest.TestCase): - """PortfolioResponseCurrentStatusUpdate unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioResponseCurrentStatusUpdate(self): - """Test PortfolioResponseCurrentStatusUpdate""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_response_current_status_update.PortfolioResponseCurrentStatusUpdate() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_response_custom_field_settings.py b/test/test_portfolio_response_custom_field_settings.py deleted file mode 100644 index 0e02ae56..00000000 --- a/test/test_portfolio_response_custom_field_settings.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_response_custom_field_settings import PortfolioResponseCustomFieldSettings # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioResponseCustomFieldSettings(unittest.TestCase): - """PortfolioResponseCustomFieldSettings unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioResponseCustomFieldSettings(self): - """Test PortfolioResponseCustomFieldSettings""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_response_custom_field_settings.PortfolioResponseCustomFieldSettings() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_response_custom_fields.py b/test/test_portfolio_response_custom_fields.py deleted file mode 100644 index 6f9e9c5f..00000000 --- a/test/test_portfolio_response_custom_fields.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_response_custom_fields import PortfolioResponseCustomFields # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioResponseCustomFields(unittest.TestCase): - """PortfolioResponseCustomFields unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioResponseCustomFields(self): - """Test PortfolioResponseCustomFields""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_response_custom_fields.PortfolioResponseCustomFields() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_response_data.py b/test/test_portfolio_response_data.py deleted file mode 100644 index ca556c72..00000000 --- a/test/test_portfolio_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_response_data import PortfolioResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioResponseData(unittest.TestCase): - """PortfolioResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioResponseData(self): - """Test PortfolioResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_response_data.PortfolioResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolio_response_workspace.py b/test/test_portfolio_response_workspace.py deleted file mode 100644 index 657fa75c..00000000 --- a/test/test_portfolio_response_workspace.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolio_response_workspace import PortfolioResponseWorkspace # noqa: E501 -from asana.rest import ApiException - - -class TestPortfolioResponseWorkspace(unittest.TestCase): - """PortfolioResponseWorkspace unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfolioResponseWorkspace(self): - """Test PortfolioResponseWorkspace""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolio_response_workspace.PortfolioResponseWorkspace() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolios_api.py b/test/test_portfolios_api.py deleted file mode 100644 index 36b434f3..00000000 --- a/test/test_portfolios_api.py +++ /dev/null @@ -1,117 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.portfolios_api import PortfoliosApi # noqa: E501 -from asana.rest import ApiException - - -class TestPortfoliosApi(unittest.TestCase): - """PortfoliosApi unit test stubs""" - - def setUp(self): - self.api = PortfoliosApi() # noqa: E501 - - def tearDown(self): - pass - - def test_add_custom_field_setting_for_portfolio(self): - """Test case for add_custom_field_setting_for_portfolio - - Add a custom field to a portfolio # noqa: E501 - """ - pass - - def test_add_item_for_portfolio(self): - """Test case for add_item_for_portfolio - - Add a portfolio item # noqa: E501 - """ - pass - - def test_add_members_for_portfolio(self): - """Test case for add_members_for_portfolio - - Add users to a portfolio # noqa: E501 - """ - pass - - def test_create_portfolio(self): - """Test case for create_portfolio - - Create a portfolio # noqa: E501 - """ - pass - - def test_delete_portfolio(self): - """Test case for delete_portfolio - - Delete a portfolio # noqa: E501 - """ - pass - - def test_get_items_for_portfolio(self): - """Test case for get_items_for_portfolio - - Get portfolio items # noqa: E501 - """ - pass - - def test_get_portfolio(self): - """Test case for get_portfolio - - Get a portfolio # noqa: E501 - """ - pass - - def test_get_portfolios(self): - """Test case for get_portfolios - - Get multiple portfolios # noqa: E501 - """ - pass - - def test_remove_custom_field_setting_for_portfolio(self): - """Test case for remove_custom_field_setting_for_portfolio - - Remove a custom field from a portfolio # noqa: E501 - """ - pass - - def test_remove_item_for_portfolio(self): - """Test case for remove_item_for_portfolio - - Remove a portfolio item # noqa: E501 - """ - pass - - def test_remove_members_for_portfolio(self): - """Test case for remove_members_for_portfolio - - Remove users from a portfolio # noqa: E501 - """ - pass - - def test_update_portfolio(self): - """Test case for update_portfolio - - Update a portfolio # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolios_body.py b/test/test_portfolios_body.py deleted file mode 100644 index 8384da73..00000000 --- a/test/test_portfolios_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolios_body import PortfoliosBody # noqa: E501 -from asana.rest import ApiException - - -class TestPortfoliosBody(unittest.TestCase): - """PortfoliosBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfoliosBody(self): - """Test PortfoliosBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolios_body.PortfoliosBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_portfolios_portfolio_gid_body.py b/test/test_portfolios_portfolio_gid_body.py deleted file mode 100644 index c56df05e..00000000 --- a/test/test_portfolios_portfolio_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.portfolios_portfolio_gid_body import PortfoliosPortfolioGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestPortfoliosPortfolioGidBody(unittest.TestCase): - """PortfoliosPortfolioGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPortfoliosPortfolioGidBody(self): - """Test PortfoliosPortfolioGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.portfolios_portfolio_gid_body.PortfoliosPortfolioGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_preview.py b/test/test_preview.py deleted file mode 100644 index a87a5fca..00000000 --- a/test/test_preview.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.preview import Preview # noqa: E501 -from asana.rest import ApiException - - -class TestPreview(unittest.TestCase): - """Preview unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testPreview(self): - """Test Preview""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.preview.Preview() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_base.py b/test/test_project_base.py deleted file mode 100644 index 40709e11..00000000 --- a/test/test_project_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_base import ProjectBase # noqa: E501 -from asana.rest import ApiException - - -class TestProjectBase(unittest.TestCase): - """ProjectBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectBase(self): - """Test ProjectBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_base.ProjectBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_base_current_status.py b/test/test_project_base_current_status.py deleted file mode 100644 index e3437779..00000000 --- a/test/test_project_base_current_status.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_base_current_status import ProjectBaseCurrentStatus # noqa: E501 -from asana.rest import ApiException - - -class TestProjectBaseCurrentStatus(unittest.TestCase): - """ProjectBaseCurrentStatus unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectBaseCurrentStatus(self): - """Test ProjectBaseCurrentStatus""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_base_current_status.ProjectBaseCurrentStatus() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_base_current_status_update.py b/test/test_project_base_current_status_update.py deleted file mode 100644 index 439e6723..00000000 --- a/test/test_project_base_current_status_update.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_base_current_status_update import ProjectBaseCurrentStatusUpdate # noqa: E501 -from asana.rest import ApiException - - -class TestProjectBaseCurrentStatusUpdate(unittest.TestCase): - """ProjectBaseCurrentStatusUpdate unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectBaseCurrentStatusUpdate(self): - """Test ProjectBaseCurrentStatusUpdate""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_base_current_status_update.ProjectBaseCurrentStatusUpdate() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_base_workspace.py b/test/test_project_base_workspace.py deleted file mode 100644 index 4b9066e5..00000000 --- a/test/test_project_base_workspace.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_base_workspace import ProjectBaseWorkspace # noqa: E501 -from asana.rest import ApiException - - -class TestProjectBaseWorkspace(unittest.TestCase): - """ProjectBaseWorkspace unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectBaseWorkspace(self): - """Test ProjectBaseWorkspace""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_base_workspace.ProjectBaseWorkspace() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_brief_base.py b/test/test_project_brief_base.py deleted file mode 100644 index c9033c10..00000000 --- a/test/test_project_brief_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_brief_base import ProjectBriefBase # noqa: E501 -from asana.rest import ApiException - - -class TestProjectBriefBase(unittest.TestCase): - """ProjectBriefBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectBriefBase(self): - """Test ProjectBriefBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_brief_base.ProjectBriefBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_brief_compact.py b/test/test_project_brief_compact.py deleted file mode 100644 index 6d8e2592..00000000 --- a/test/test_project_brief_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_brief_compact import ProjectBriefCompact # noqa: E501 -from asana.rest import ApiException - - -class TestProjectBriefCompact(unittest.TestCase): - """ProjectBriefCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectBriefCompact(self): - """Test ProjectBriefCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_brief_compact.ProjectBriefCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_brief_request.py b/test/test_project_brief_request.py deleted file mode 100644 index 7ea5ee26..00000000 --- a/test/test_project_brief_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_brief_request import ProjectBriefRequest # noqa: E501 -from asana.rest import ApiException - - -class TestProjectBriefRequest(unittest.TestCase): - """ProjectBriefRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectBriefRequest(self): - """Test ProjectBriefRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_brief_request.ProjectBriefRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_brief_response.py b/test/test_project_brief_response.py deleted file mode 100644 index b6f17705..00000000 --- a/test/test_project_brief_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_brief_response import ProjectBriefResponse # noqa: E501 -from asana.rest import ApiException - - -class TestProjectBriefResponse(unittest.TestCase): - """ProjectBriefResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectBriefResponse(self): - """Test ProjectBriefResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_brief_response.ProjectBriefResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_brief_response_data.py b/test/test_project_brief_response_data.py deleted file mode 100644 index 07e7ebdc..00000000 --- a/test/test_project_brief_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_brief_response_data import ProjectBriefResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestProjectBriefResponseData(unittest.TestCase): - """ProjectBriefResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectBriefResponseData(self): - """Test ProjectBriefResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_brief_response_data.ProjectBriefResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_brief_response_project.py b/test/test_project_brief_response_project.py deleted file mode 100644 index 058cf5b3..00000000 --- a/test/test_project_brief_response_project.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_brief_response_project import ProjectBriefResponseProject # noqa: E501 -from asana.rest import ApiException - - -class TestProjectBriefResponseProject(unittest.TestCase): - """ProjectBriefResponseProject unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectBriefResponseProject(self): - """Test ProjectBriefResponseProject""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_brief_response_project.ProjectBriefResponseProject() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_briefs_api.py b/test/test_project_briefs_api.py deleted file mode 100644 index f2c81108..00000000 --- a/test/test_project_briefs_api.py +++ /dev/null @@ -1,61 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.project_briefs_api import ProjectBriefsApi # noqa: E501 -from asana.rest import ApiException - - -class TestProjectBriefsApi(unittest.TestCase): - """ProjectBriefsApi unit test stubs""" - - def setUp(self): - self.api = ProjectBriefsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_create_project_brief(self): - """Test case for create_project_brief - - Create a project brief # noqa: E501 - """ - pass - - def test_delete_project_brief(self): - """Test case for delete_project_brief - - Delete a project brief # noqa: E501 - """ - pass - - def test_get_project_brief(self): - """Test case for get_project_brief - - Get a project brief # noqa: E501 - """ - pass - - def test_update_project_brief(self): - """Test case for update_project_brief - - Update a project brief # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_briefs_project_brief_gid_body.py b/test/test_project_briefs_project_brief_gid_body.py deleted file mode 100644 index d663ee5b..00000000 --- a/test/test_project_briefs_project_brief_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_briefs_project_brief_gid_body import ProjectBriefsProjectBriefGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectBriefsProjectBriefGidBody(unittest.TestCase): - """ProjectBriefsProjectBriefGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectBriefsProjectBriefGidBody(self): - """Test ProjectBriefsProjectBriefGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_briefs_project_brief_gid_body.ProjectBriefsProjectBriefGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_compact.py b/test/test_project_compact.py deleted file mode 100644 index 9657aa71..00000000 --- a/test/test_project_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_compact import ProjectCompact # noqa: E501 -from asana.rest import ApiException - - -class TestProjectCompact(unittest.TestCase): - """ProjectCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectCompact(self): - """Test ProjectCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_compact.ProjectCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_duplicate_request.py b/test/test_project_duplicate_request.py deleted file mode 100644 index 1d175f59..00000000 --- a/test/test_project_duplicate_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_duplicate_request import ProjectDuplicateRequest # noqa: E501 -from asana.rest import ApiException - - -class TestProjectDuplicateRequest(unittest.TestCase): - """ProjectDuplicateRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectDuplicateRequest(self): - """Test ProjectDuplicateRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_duplicate_request.ProjectDuplicateRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_duplicate_request_schedule_dates.py b/test/test_project_duplicate_request_schedule_dates.py deleted file mode 100644 index 3f293e48..00000000 --- a/test/test_project_duplicate_request_schedule_dates.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_duplicate_request_schedule_dates import ProjectDuplicateRequestScheduleDates # noqa: E501 -from asana.rest import ApiException - - -class TestProjectDuplicateRequestScheduleDates(unittest.TestCase): - """ProjectDuplicateRequestScheduleDates unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectDuplicateRequestScheduleDates(self): - """Test ProjectDuplicateRequestScheduleDates""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_duplicate_request_schedule_dates.ProjectDuplicateRequestScheduleDates() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_gid_add_custom_field_setting_body.py b/test/test_project_gid_add_custom_field_setting_body.py deleted file mode 100644 index 22bc3b6a..00000000 --- a/test/test_project_gid_add_custom_field_setting_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_gid_add_custom_field_setting_body import ProjectGidAddCustomFieldSettingBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectGidAddCustomFieldSettingBody(unittest.TestCase): - """ProjectGidAddCustomFieldSettingBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectGidAddCustomFieldSettingBody(self): - """Test ProjectGidAddCustomFieldSettingBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_gid_add_custom_field_setting_body.ProjectGidAddCustomFieldSettingBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_gid_add_followers_body.py b/test/test_project_gid_add_followers_body.py deleted file mode 100644 index dd52d6e7..00000000 --- a/test/test_project_gid_add_followers_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_gid_add_followers_body import ProjectGidAddFollowersBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectGidAddFollowersBody(unittest.TestCase): - """ProjectGidAddFollowersBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectGidAddFollowersBody(self): - """Test ProjectGidAddFollowersBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_gid_add_followers_body.ProjectGidAddFollowersBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_gid_add_members_body.py b/test/test_project_gid_add_members_body.py deleted file mode 100644 index 8183d005..00000000 --- a/test/test_project_gid_add_members_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_gid_add_members_body import ProjectGidAddMembersBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectGidAddMembersBody(unittest.TestCase): - """ProjectGidAddMembersBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectGidAddMembersBody(self): - """Test ProjectGidAddMembersBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_gid_add_members_body.ProjectGidAddMembersBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_gid_duplicate_body.py b/test/test_project_gid_duplicate_body.py deleted file mode 100644 index 2ee0ddfc..00000000 --- a/test/test_project_gid_duplicate_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_gid_duplicate_body import ProjectGidDuplicateBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectGidDuplicateBody(unittest.TestCase): - """ProjectGidDuplicateBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectGidDuplicateBody(self): - """Test ProjectGidDuplicateBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_gid_duplicate_body.ProjectGidDuplicateBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_gid_project_briefs_body.py b/test/test_project_gid_project_briefs_body.py deleted file mode 100644 index 3a47da35..00000000 --- a/test/test_project_gid_project_briefs_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_gid_project_briefs_body import ProjectGidProjectBriefsBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectGidProjectBriefsBody(unittest.TestCase): - """ProjectGidProjectBriefsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectGidProjectBriefsBody(self): - """Test ProjectGidProjectBriefsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_gid_project_briefs_body.ProjectGidProjectBriefsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_gid_project_statuses_body.py b/test/test_project_gid_project_statuses_body.py deleted file mode 100644 index 3569a317..00000000 --- a/test/test_project_gid_project_statuses_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_gid_project_statuses_body import ProjectGidProjectStatusesBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectGidProjectStatusesBody(unittest.TestCase): - """ProjectGidProjectStatusesBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectGidProjectStatusesBody(self): - """Test ProjectGidProjectStatusesBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_gid_project_statuses_body.ProjectGidProjectStatusesBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_gid_remove_custom_field_setting_body.py b/test/test_project_gid_remove_custom_field_setting_body.py deleted file mode 100644 index 54e040cf..00000000 --- a/test/test_project_gid_remove_custom_field_setting_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_gid_remove_custom_field_setting_body import ProjectGidRemoveCustomFieldSettingBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectGidRemoveCustomFieldSettingBody(unittest.TestCase): - """ProjectGidRemoveCustomFieldSettingBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectGidRemoveCustomFieldSettingBody(self): - """Test ProjectGidRemoveCustomFieldSettingBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_gid_remove_custom_field_setting_body.ProjectGidRemoveCustomFieldSettingBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_gid_remove_followers_body.py b/test/test_project_gid_remove_followers_body.py deleted file mode 100644 index be9d4a96..00000000 --- a/test/test_project_gid_remove_followers_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_gid_remove_followers_body import ProjectGidRemoveFollowersBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectGidRemoveFollowersBody(unittest.TestCase): - """ProjectGidRemoveFollowersBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectGidRemoveFollowersBody(self): - """Test ProjectGidRemoveFollowersBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_gid_remove_followers_body.ProjectGidRemoveFollowersBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_gid_remove_members_body.py b/test/test_project_gid_remove_members_body.py deleted file mode 100644 index 749e0348..00000000 --- a/test/test_project_gid_remove_members_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_gid_remove_members_body import ProjectGidRemoveMembersBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectGidRemoveMembersBody(unittest.TestCase): - """ProjectGidRemoveMembersBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectGidRemoveMembersBody(self): - """Test ProjectGidRemoveMembersBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_gid_remove_members_body.ProjectGidRemoveMembersBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_gid_save_as_template_body.py b/test/test_project_gid_save_as_template_body.py deleted file mode 100644 index 2526ac29..00000000 --- a/test/test_project_gid_save_as_template_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_gid_save_as_template_body import ProjectGidSaveAsTemplateBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectGidSaveAsTemplateBody(unittest.TestCase): - """ProjectGidSaveAsTemplateBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectGidSaveAsTemplateBody(self): - """Test ProjectGidSaveAsTemplateBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_gid_save_as_template_body.ProjectGidSaveAsTemplateBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_gid_sections_body.py b/test/test_project_gid_sections_body.py deleted file mode 100644 index 6b1045de..00000000 --- a/test/test_project_gid_sections_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_gid_sections_body import ProjectGidSectionsBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectGidSectionsBody(unittest.TestCase): - """ProjectGidSectionsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectGidSectionsBody(self): - """Test ProjectGidSectionsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_gid_sections_body.ProjectGidSectionsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_membership_base.py b/test/test_project_membership_base.py deleted file mode 100644 index 9e6822fa..00000000 --- a/test/test_project_membership_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_membership_base import ProjectMembershipBase # noqa: E501 -from asana.rest import ApiException - - -class TestProjectMembershipBase(unittest.TestCase): - """ProjectMembershipBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectMembershipBase(self): - """Test ProjectMembershipBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_membership_base.ProjectMembershipBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_membership_compact.py b/test/test_project_membership_compact.py deleted file mode 100644 index c6d9ed39..00000000 --- a/test/test_project_membership_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_membership_compact import ProjectMembershipCompact # noqa: E501 -from asana.rest import ApiException - - -class TestProjectMembershipCompact(unittest.TestCase): - """ProjectMembershipCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectMembershipCompact(self): - """Test ProjectMembershipCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_membership_compact.ProjectMembershipCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_membership_compact_array.py b/test/test_project_membership_compact_array.py deleted file mode 100644 index db71c560..00000000 --- a/test/test_project_membership_compact_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_membership_compact_array import ProjectMembershipCompactArray # noqa: E501 -from asana.rest import ApiException - - -class TestProjectMembershipCompactArray(unittest.TestCase): - """ProjectMembershipCompactArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectMembershipCompactArray(self): - """Test ProjectMembershipCompactArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_membership_compact_array.ProjectMembershipCompactArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_membership_compact_response.py b/test/test_project_membership_compact_response.py deleted file mode 100644 index 7da799df..00000000 --- a/test/test_project_membership_compact_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_membership_compact_response import ProjectMembershipCompactResponse # noqa: E501 -from asana.rest import ApiException - - -class TestProjectMembershipCompactResponse(unittest.TestCase): - """ProjectMembershipCompactResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectMembershipCompactResponse(self): - """Test ProjectMembershipCompactResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_membership_compact_response.ProjectMembershipCompactResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_membership_compact_response_data.py b/test/test_project_membership_compact_response_data.py deleted file mode 100644 index 2f697dea..00000000 --- a/test/test_project_membership_compact_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_membership_compact_response_data import ProjectMembershipCompactResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestProjectMembershipCompactResponseData(unittest.TestCase): - """ProjectMembershipCompactResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectMembershipCompactResponseData(self): - """Test ProjectMembershipCompactResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_membership_compact_response_data.ProjectMembershipCompactResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_membership_normal_response.py b/test/test_project_membership_normal_response.py deleted file mode 100644 index 40da7e77..00000000 --- a/test/test_project_membership_normal_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_membership_normal_response import ProjectMembershipNormalResponse # noqa: E501 -from asana.rest import ApiException - - -class TestProjectMembershipNormalResponse(unittest.TestCase): - """ProjectMembershipNormalResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectMembershipNormalResponse(self): - """Test ProjectMembershipNormalResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_membership_normal_response.ProjectMembershipNormalResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_membership_normal_response_data.py b/test/test_project_membership_normal_response_data.py deleted file mode 100644 index ef567fdd..00000000 --- a/test/test_project_membership_normal_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_membership_normal_response_data import ProjectMembershipNormalResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestProjectMembershipNormalResponseData(unittest.TestCase): - """ProjectMembershipNormalResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectMembershipNormalResponseData(self): - """Test ProjectMembershipNormalResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_membership_normal_response_data.ProjectMembershipNormalResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_membership_response.py b/test/test_project_membership_response.py deleted file mode 100644 index 0959896b..00000000 --- a/test/test_project_membership_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_membership_response import ProjectMembershipResponse # noqa: E501 -from asana.rest import ApiException - - -class TestProjectMembershipResponse(unittest.TestCase): - """ProjectMembershipResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectMembershipResponse(self): - """Test ProjectMembershipResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_membership_response.ProjectMembershipResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_membership_response_array.py b/test/test_project_membership_response_array.py deleted file mode 100644 index 3d8ec00e..00000000 --- a/test/test_project_membership_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_membership_response_array import ProjectMembershipResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestProjectMembershipResponseArray(unittest.TestCase): - """ProjectMembershipResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectMembershipResponseArray(self): - """Test ProjectMembershipResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_membership_response_array.ProjectMembershipResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_membership_response_data.py b/test/test_project_membership_response_data.py deleted file mode 100644 index d48c8608..00000000 --- a/test/test_project_membership_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_membership_response_data import ProjectMembershipResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestProjectMembershipResponseData(unittest.TestCase): - """ProjectMembershipResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectMembershipResponseData(self): - """Test ProjectMembershipResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_membership_response_data.ProjectMembershipResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_membership_response_member.py b/test/test_project_membership_response_member.py deleted file mode 100644 index 15d86b3d..00000000 --- a/test/test_project_membership_response_member.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_membership_response_member import ProjectMembershipResponseMember # noqa: E501 -from asana.rest import ApiException - - -class TestProjectMembershipResponseMember(unittest.TestCase): - """ProjectMembershipResponseMember unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectMembershipResponseMember(self): - """Test ProjectMembershipResponseMember""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_membership_response_member.ProjectMembershipResponseMember() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_memberships_api.py b/test/test_project_memberships_api.py deleted file mode 100644 index 58da9cea..00000000 --- a/test/test_project_memberships_api.py +++ /dev/null @@ -1,47 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.project_memberships_api import ProjectMembershipsApi # noqa: E501 -from asana.rest import ApiException - - -class TestProjectMembershipsApi(unittest.TestCase): - """ProjectMembershipsApi unit test stubs""" - - def setUp(self): - self.api = ProjectMembershipsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_get_project_membership(self): - """Test case for get_project_membership - - Get a project membership # noqa: E501 - """ - pass - - def test_get_project_memberships_for_project(self): - """Test case for get_project_memberships_for_project - - Get memberships from a project # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_request.py b/test/test_project_request.py deleted file mode 100644 index a8d1d7a7..00000000 --- a/test/test_project_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_request import ProjectRequest # noqa: E501 -from asana.rest import ApiException - - -class TestProjectRequest(unittest.TestCase): - """ProjectRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectRequest(self): - """Test ProjectRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_request.ProjectRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_response.py b/test/test_project_response.py deleted file mode 100644 index 8590c396..00000000 --- a/test/test_project_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_response import ProjectResponse # noqa: E501 -from asana.rest import ApiException - - -class TestProjectResponse(unittest.TestCase): - """ProjectResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectResponse(self): - """Test ProjectResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_response.ProjectResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_response_array.py b/test/test_project_response_array.py deleted file mode 100644 index d9bd50b2..00000000 --- a/test/test_project_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_response_array import ProjectResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestProjectResponseArray(unittest.TestCase): - """ProjectResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectResponseArray(self): - """Test ProjectResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_response_array.ProjectResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_response_completed_by.py b/test/test_project_response_completed_by.py deleted file mode 100644 index a5f9d1c0..00000000 --- a/test/test_project_response_completed_by.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_response_completed_by import ProjectResponseCompletedBy # noqa: E501 -from asana.rest import ApiException - - -class TestProjectResponseCompletedBy(unittest.TestCase): - """ProjectResponseCompletedBy unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectResponseCompletedBy(self): - """Test ProjectResponseCompletedBy""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_response_completed_by.ProjectResponseCompletedBy() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_response_created_from_template.py b/test/test_project_response_created_from_template.py deleted file mode 100644 index 76440a6b..00000000 --- a/test/test_project_response_created_from_template.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_response_created_from_template import ProjectResponseCreatedFromTemplate # noqa: E501 -from asana.rest import ApiException - - -class TestProjectResponseCreatedFromTemplate(unittest.TestCase): - """ProjectResponseCreatedFromTemplate unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectResponseCreatedFromTemplate(self): - """Test ProjectResponseCreatedFromTemplate""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_response_created_from_template.ProjectResponseCreatedFromTemplate() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_response_data.py b/test/test_project_response_data.py deleted file mode 100644 index e67934be..00000000 --- a/test/test_project_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_response_data import ProjectResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestProjectResponseData(unittest.TestCase): - """ProjectResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectResponseData(self): - """Test ProjectResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_response_data.ProjectResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_response_project_brief.py b/test/test_project_response_project_brief.py deleted file mode 100644 index 74ba753e..00000000 --- a/test/test_project_response_project_brief.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_response_project_brief import ProjectResponseProjectBrief # noqa: E501 -from asana.rest import ApiException - - -class TestProjectResponseProjectBrief(unittest.TestCase): - """ProjectResponseProjectBrief unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectResponseProjectBrief(self): - """Test ProjectResponseProjectBrief""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_response_project_brief.ProjectResponseProjectBrief() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_response_team.py b/test/test_project_response_team.py deleted file mode 100644 index f17b183d..00000000 --- a/test/test_project_response_team.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_response_team import ProjectResponseTeam # noqa: E501 -from asana.rest import ApiException - - -class TestProjectResponseTeam(unittest.TestCase): - """ProjectResponseTeam unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectResponseTeam(self): - """Test ProjectResponseTeam""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_response_team.ProjectResponseTeam() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_response_workspace.py b/test/test_project_response_workspace.py deleted file mode 100644 index 895c0382..00000000 --- a/test/test_project_response_workspace.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_response_workspace import ProjectResponseWorkspace # noqa: E501 -from asana.rest import ApiException - - -class TestProjectResponseWorkspace(unittest.TestCase): - """ProjectResponseWorkspace unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectResponseWorkspace(self): - """Test ProjectResponseWorkspace""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_response_workspace.ProjectResponseWorkspace() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_save_as_template_request.py b/test/test_project_save_as_template_request.py deleted file mode 100644 index e1bdf897..00000000 --- a/test/test_project_save_as_template_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_save_as_template_request import ProjectSaveAsTemplateRequest # noqa: E501 -from asana.rest import ApiException - - -class TestProjectSaveAsTemplateRequest(unittest.TestCase): - """ProjectSaveAsTemplateRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectSaveAsTemplateRequest(self): - """Test ProjectSaveAsTemplateRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_save_as_template_request.ProjectSaveAsTemplateRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_section_insert_request.py b/test/test_project_section_insert_request.py deleted file mode 100644 index e32e5635..00000000 --- a/test/test_project_section_insert_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_section_insert_request import ProjectSectionInsertRequest # noqa: E501 -from asana.rest import ApiException - - -class TestProjectSectionInsertRequest(unittest.TestCase): - """ProjectSectionInsertRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectSectionInsertRequest(self): - """Test ProjectSectionInsertRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_section_insert_request.ProjectSectionInsertRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_status_base.py b/test/test_project_status_base.py deleted file mode 100644 index 1625ced5..00000000 --- a/test/test_project_status_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_status_base import ProjectStatusBase # noqa: E501 -from asana.rest import ApiException - - -class TestProjectStatusBase(unittest.TestCase): - """ProjectStatusBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectStatusBase(self): - """Test ProjectStatusBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_status_base.ProjectStatusBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_status_compact.py b/test/test_project_status_compact.py deleted file mode 100644 index bfc527dc..00000000 --- a/test/test_project_status_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_status_compact import ProjectStatusCompact # noqa: E501 -from asana.rest import ApiException - - -class TestProjectStatusCompact(unittest.TestCase): - """ProjectStatusCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectStatusCompact(self): - """Test ProjectStatusCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_status_compact.ProjectStatusCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_status_request.py b/test/test_project_status_request.py deleted file mode 100644 index c340d064..00000000 --- a/test/test_project_status_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_status_request import ProjectStatusRequest # noqa: E501 -from asana.rest import ApiException - - -class TestProjectStatusRequest(unittest.TestCase): - """ProjectStatusRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectStatusRequest(self): - """Test ProjectStatusRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_status_request.ProjectStatusRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_status_response.py b/test/test_project_status_response.py deleted file mode 100644 index 23f87437..00000000 --- a/test/test_project_status_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_status_response import ProjectStatusResponse # noqa: E501 -from asana.rest import ApiException - - -class TestProjectStatusResponse(unittest.TestCase): - """ProjectStatusResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectStatusResponse(self): - """Test ProjectStatusResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_status_response.ProjectStatusResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_status_response_array.py b/test/test_project_status_response_array.py deleted file mode 100644 index 708f5f01..00000000 --- a/test/test_project_status_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_status_response_array import ProjectStatusResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestProjectStatusResponseArray(unittest.TestCase): - """ProjectStatusResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectStatusResponseArray(self): - """Test ProjectStatusResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_status_response_array.ProjectStatusResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_status_response_data.py b/test/test_project_status_response_data.py deleted file mode 100644 index abd02088..00000000 --- a/test/test_project_status_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_status_response_data import ProjectStatusResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestProjectStatusResponseData(unittest.TestCase): - """ProjectStatusResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectStatusResponseData(self): - """Test ProjectStatusResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_status_response_data.ProjectStatusResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_statuses_api.py b/test/test_project_statuses_api.py deleted file mode 100644 index ca1867f9..00000000 --- a/test/test_project_statuses_api.py +++ /dev/null @@ -1,61 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.project_statuses_api import ProjectStatusesApi # noqa: E501 -from asana.rest import ApiException - - -class TestProjectStatusesApi(unittest.TestCase): - """ProjectStatusesApi unit test stubs""" - - def setUp(self): - self.api = ProjectStatusesApi() # noqa: E501 - - def tearDown(self): - pass - - def test_create_project_status_for_project(self): - """Test case for create_project_status_for_project - - Create a project status # noqa: E501 - """ - pass - - def test_delete_project_status(self): - """Test case for delete_project_status - - Delete a project status # noqa: E501 - """ - pass - - def test_get_project_status(self): - """Test case for get_project_status - - Get a project status # noqa: E501 - """ - pass - - def test_get_project_statuses_for_project(self): - """Test case for get_project_statuses_for_project - - Get statuses from a project # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_template_base.py b/test/test_project_template_base.py deleted file mode 100644 index 7a0c19b2..00000000 --- a/test/test_project_template_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_template_base import ProjectTemplateBase # noqa: E501 -from asana.rest import ApiException - - -class TestProjectTemplateBase(unittest.TestCase): - """ProjectTemplateBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectTemplateBase(self): - """Test ProjectTemplateBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_template_base.ProjectTemplateBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_template_base_requested_dates.py b/test/test_project_template_base_requested_dates.py deleted file mode 100644 index cfb40567..00000000 --- a/test/test_project_template_base_requested_dates.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_template_base_requested_dates import ProjectTemplateBaseRequestedDates # noqa: E501 -from asana.rest import ApiException - - -class TestProjectTemplateBaseRequestedDates(unittest.TestCase): - """ProjectTemplateBaseRequestedDates unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectTemplateBaseRequestedDates(self): - """Test ProjectTemplateBaseRequestedDates""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_template_base_requested_dates.ProjectTemplateBaseRequestedDates() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_template_base_requested_roles.py b/test/test_project_template_base_requested_roles.py deleted file mode 100644 index 297cea6a..00000000 --- a/test/test_project_template_base_requested_roles.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_template_base_requested_roles import ProjectTemplateBaseRequestedRoles # noqa: E501 -from asana.rest import ApiException - - -class TestProjectTemplateBaseRequestedRoles(unittest.TestCase): - """ProjectTemplateBaseRequestedRoles unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectTemplateBaseRequestedRoles(self): - """Test ProjectTemplateBaseRequestedRoles""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_template_base_requested_roles.ProjectTemplateBaseRequestedRoles() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_template_base_team.py b/test/test_project_template_base_team.py deleted file mode 100644 index de20a029..00000000 --- a/test/test_project_template_base_team.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_template_base_team import ProjectTemplateBaseTeam # noqa: E501 -from asana.rest import ApiException - - -class TestProjectTemplateBaseTeam(unittest.TestCase): - """ProjectTemplateBaseTeam unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectTemplateBaseTeam(self): - """Test ProjectTemplateBaseTeam""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_template_base_team.ProjectTemplateBaseTeam() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_template_compact.py b/test/test_project_template_compact.py deleted file mode 100644 index 5bf88987..00000000 --- a/test/test_project_template_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_template_compact import ProjectTemplateCompact # noqa: E501 -from asana.rest import ApiException - - -class TestProjectTemplateCompact(unittest.TestCase): - """ProjectTemplateCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectTemplateCompact(self): - """Test ProjectTemplateCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_template_compact.ProjectTemplateCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_template_gid_instantiate_project_body.py b/test/test_project_template_gid_instantiate_project_body.py deleted file mode 100644 index 55841937..00000000 --- a/test/test_project_template_gid_instantiate_project_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_template_gid_instantiate_project_body import ProjectTemplateGidInstantiateProjectBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectTemplateGidInstantiateProjectBody(unittest.TestCase): - """ProjectTemplateGidInstantiateProjectBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectTemplateGidInstantiateProjectBody(self): - """Test ProjectTemplateGidInstantiateProjectBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_template_gid_instantiate_project_body.ProjectTemplateGidInstantiateProjectBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_template_instantiate_project_request.py b/test/test_project_template_instantiate_project_request.py deleted file mode 100644 index a7f45015..00000000 --- a/test/test_project_template_instantiate_project_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_template_instantiate_project_request import ProjectTemplateInstantiateProjectRequest # noqa: E501 -from asana.rest import ApiException - - -class TestProjectTemplateInstantiateProjectRequest(unittest.TestCase): - """ProjectTemplateInstantiateProjectRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectTemplateInstantiateProjectRequest(self): - """Test ProjectTemplateInstantiateProjectRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_template_instantiate_project_request.ProjectTemplateInstantiateProjectRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_template_instantiate_project_request_requested_dates.py b/test/test_project_template_instantiate_project_request_requested_dates.py deleted file mode 100644 index 5310991e..00000000 --- a/test/test_project_template_instantiate_project_request_requested_dates.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_template_instantiate_project_request_requested_dates import ProjectTemplateInstantiateProjectRequestRequestedDates # noqa: E501 -from asana.rest import ApiException - - -class TestProjectTemplateInstantiateProjectRequestRequestedDates(unittest.TestCase): - """ProjectTemplateInstantiateProjectRequestRequestedDates unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectTemplateInstantiateProjectRequestRequestedDates(self): - """Test ProjectTemplateInstantiateProjectRequestRequestedDates""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_template_instantiate_project_request_requested_dates.ProjectTemplateInstantiateProjectRequestRequestedDates() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_template_instantiate_project_request_requested_roles.py b/test/test_project_template_instantiate_project_request_requested_roles.py deleted file mode 100644 index a41da9a8..00000000 --- a/test/test_project_template_instantiate_project_request_requested_roles.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_template_instantiate_project_request_requested_roles import ProjectTemplateInstantiateProjectRequestRequestedRoles # noqa: E501 -from asana.rest import ApiException - - -class TestProjectTemplateInstantiateProjectRequestRequestedRoles(unittest.TestCase): - """ProjectTemplateInstantiateProjectRequestRequestedRoles unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectTemplateInstantiateProjectRequestRequestedRoles(self): - """Test ProjectTemplateInstantiateProjectRequestRequestedRoles""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_template_instantiate_project_request_requested_roles.ProjectTemplateInstantiateProjectRequestRequestedRoles() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_template_response.py b/test/test_project_template_response.py deleted file mode 100644 index e58f046a..00000000 --- a/test/test_project_template_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_template_response import ProjectTemplateResponse # noqa: E501 -from asana.rest import ApiException - - -class TestProjectTemplateResponse(unittest.TestCase): - """ProjectTemplateResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectTemplateResponse(self): - """Test ProjectTemplateResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_template_response.ProjectTemplateResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_template_response_array.py b/test/test_project_template_response_array.py deleted file mode 100644 index acc443a7..00000000 --- a/test/test_project_template_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_template_response_array import ProjectTemplateResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestProjectTemplateResponseArray(unittest.TestCase): - """ProjectTemplateResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectTemplateResponseArray(self): - """Test ProjectTemplateResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_template_response_array.ProjectTemplateResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_template_response_data.py b/test/test_project_template_response_data.py deleted file mode 100644 index 870d29de..00000000 --- a/test/test_project_template_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_template_response_data import ProjectTemplateResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestProjectTemplateResponseData(unittest.TestCase): - """ProjectTemplateResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectTemplateResponseData(self): - """Test ProjectTemplateResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_template_response_data.ProjectTemplateResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_templates_api.py b/test/test_project_templates_api.py deleted file mode 100644 index bcc9bad9..00000000 --- a/test/test_project_templates_api.py +++ /dev/null @@ -1,68 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.project_templates_api import ProjectTemplatesApi # noqa: E501 -from asana.rest import ApiException - - -class TestProjectTemplatesApi(unittest.TestCase): - """ProjectTemplatesApi unit test stubs""" - - def setUp(self): - self.api = ProjectTemplatesApi() # noqa: E501 - - def tearDown(self): - pass - - def test_delete_project_template(self): - """Test case for delete_project_template - - Delete a project template # noqa: E501 - """ - pass - - def test_get_project_template(self): - """Test case for get_project_template - - Get a project template # noqa: E501 - """ - pass - - def test_get_project_templates(self): - """Test case for get_project_templates - - Get multiple project templates # noqa: E501 - """ - pass - - def test_get_project_templates_for_team(self): - """Test case for get_project_templates_for_team - - Get a team's project templates # noqa: E501 - """ - pass - - def test_instantiate_project(self): - """Test case for instantiate_project - - Instantiate a project from a project template # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_project_update_request.py b/test/test_project_update_request.py deleted file mode 100644 index c17bf895..00000000 --- a/test/test_project_update_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.project_update_request import ProjectUpdateRequest # noqa: E501 -from asana.rest import ApiException - - -class TestProjectUpdateRequest(unittest.TestCase): - """ProjectUpdateRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectUpdateRequest(self): - """Test ProjectUpdateRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.project_update_request.ProjectUpdateRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_projects_api.py b/test/test_projects_api.py deleted file mode 100644 index ad6b8ab0..00000000 --- a/test/test_projects_api.py +++ /dev/null @@ -1,166 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.projects_api import ProjectsApi # noqa: E501 -from asana.rest import ApiException - - -class TestProjectsApi(unittest.TestCase): - """ProjectsApi unit test stubs""" - - def setUp(self): - self.api = ProjectsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_add_custom_field_setting_for_project(self): - """Test case for add_custom_field_setting_for_project - - Add a custom field to a project # noqa: E501 - """ - pass - - def test_add_followers_for_project(self): - """Test case for add_followers_for_project - - Add followers to a project # noqa: E501 - """ - pass - - def test_add_members_for_project(self): - """Test case for add_members_for_project - - Add users to a project # noqa: E501 - """ - pass - - def test_create_project(self): - """Test case for create_project - - Create a project # noqa: E501 - """ - pass - - def test_create_project_for_team(self): - """Test case for create_project_for_team - - Create a project in a team # noqa: E501 - """ - pass - - def test_create_project_for_workspace(self): - """Test case for create_project_for_workspace - - Create a project in a workspace # noqa: E501 - """ - pass - - def test_delete_project(self): - """Test case for delete_project - - Delete a project # noqa: E501 - """ - pass - - def test_duplicate_project(self): - """Test case for duplicate_project - - Duplicate a project # noqa: E501 - """ - pass - - def test_get_project(self): - """Test case for get_project - - Get a project # noqa: E501 - """ - pass - - def test_get_projects(self): - """Test case for get_projects - - Get multiple projects # noqa: E501 - """ - pass - - def test_get_projects_for_task(self): - """Test case for get_projects_for_task - - Get projects a task is in # noqa: E501 - """ - pass - - def test_get_projects_for_team(self): - """Test case for get_projects_for_team - - Get a team's projects # noqa: E501 - """ - pass - - def test_get_projects_for_workspace(self): - """Test case for get_projects_for_workspace - - Get all projects in a workspace # noqa: E501 - """ - pass - - def test_get_task_counts_for_project(self): - """Test case for get_task_counts_for_project - - Get task count of a project # noqa: E501 - """ - pass - - def test_project_save_as_template(self): - """Test case for project_save_as_template - - Create a project template from a project # noqa: E501 - """ - pass - - def test_remove_custom_field_setting_for_project(self): - """Test case for remove_custom_field_setting_for_project - - Remove a custom field from a project # noqa: E501 - """ - pass - - def test_remove_followers_for_project(self): - """Test case for remove_followers_for_project - - Remove followers from a project # noqa: E501 - """ - pass - - def test_remove_members_for_project(self): - """Test case for remove_members_for_project - - Remove users from a project # noqa: E501 - """ - pass - - def test_update_project(self): - """Test case for update_project - - Update a project # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_projects_body.py b/test/test_projects_body.py deleted file mode 100644 index d74e2047..00000000 --- a/test/test_projects_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.projects_body import ProjectsBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectsBody(unittest.TestCase): - """ProjectsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectsBody(self): - """Test ProjectsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.projects_body.ProjectsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_projects_project_gid_body.py b/test/test_projects_project_gid_body.py deleted file mode 100644 index 95078216..00000000 --- a/test/test_projects_project_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.projects_project_gid_body import ProjectsProjectGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestProjectsProjectGidBody(unittest.TestCase): - """ProjectsProjectGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testProjectsProjectGidBody(self): - """Test ProjectsProjectGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.projects_project_gid_body.ProjectsProjectGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_remove_custom_field_setting_request.py b/test/test_remove_custom_field_setting_request.py deleted file mode 100644 index 96f42cdd..00000000 --- a/test/test_remove_custom_field_setting_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.remove_custom_field_setting_request import RemoveCustomFieldSettingRequest # noqa: E501 -from asana.rest import ApiException - - -class TestRemoveCustomFieldSettingRequest(unittest.TestCase): - """RemoveCustomFieldSettingRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testRemoveCustomFieldSettingRequest(self): - """Test RemoveCustomFieldSettingRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.remove_custom_field_setting_request.RemoveCustomFieldSettingRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_remove_followers_request.py b/test/test_remove_followers_request.py deleted file mode 100644 index 6466ab0c..00000000 --- a/test/test_remove_followers_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.remove_followers_request import RemoveFollowersRequest # noqa: E501 -from asana.rest import ApiException - - -class TestRemoveFollowersRequest(unittest.TestCase): - """RemoveFollowersRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testRemoveFollowersRequest(self): - """Test RemoveFollowersRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.remove_followers_request.RemoveFollowersRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_remove_members_request.py b/test/test_remove_members_request.py deleted file mode 100644 index 0d8eb46c..00000000 --- a/test/test_remove_members_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.remove_members_request import RemoveMembersRequest # noqa: E501 -from asana.rest import ApiException - - -class TestRemoveMembersRequest(unittest.TestCase): - """RemoveMembersRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testRemoveMembersRequest(self): - """Test RemoveMembersRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.remove_members_request.RemoveMembersRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_requested_role_request.py b/test/test_requested_role_request.py deleted file mode 100644 index b5820806..00000000 --- a/test/test_requested_role_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.requested_role_request import RequestedRoleRequest # noqa: E501 -from asana.rest import ApiException - - -class TestRequestedRoleRequest(unittest.TestCase): - """RequestedRoleRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testRequestedRoleRequest(self): - """Test RequestedRoleRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.requested_role_request.RequestedRoleRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_rule_trigger_gid_run_body.py b/test/test_rule_trigger_gid_run_body.py deleted file mode 100644 index 5e8b231a..00000000 --- a/test/test_rule_trigger_gid_run_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.rule_trigger_gid_run_body import RuleTriggerGidRunBody # noqa: E501 -from asana.rest import ApiException - - -class TestRuleTriggerGidRunBody(unittest.TestCase): - """RuleTriggerGidRunBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testRuleTriggerGidRunBody(self): - """Test RuleTriggerGidRunBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.rule_trigger_gid_run_body.RuleTriggerGidRunBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_rule_trigger_request.py b/test/test_rule_trigger_request.py deleted file mode 100644 index a0802f61..00000000 --- a/test/test_rule_trigger_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.rule_trigger_request import RuleTriggerRequest # noqa: E501 -from asana.rest import ApiException - - -class TestRuleTriggerRequest(unittest.TestCase): - """RuleTriggerRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testRuleTriggerRequest(self): - """Test RuleTriggerRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.rule_trigger_request.RuleTriggerRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_rule_trigger_response.py b/test/test_rule_trigger_response.py deleted file mode 100644 index 6da8bad9..00000000 --- a/test/test_rule_trigger_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.rule_trigger_response import RuleTriggerResponse # noqa: E501 -from asana.rest import ApiException - - -class TestRuleTriggerResponse(unittest.TestCase): - """RuleTriggerResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testRuleTriggerResponse(self): - """Test RuleTriggerResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.rule_trigger_response.RuleTriggerResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_rule_trigger_response_data.py b/test/test_rule_trigger_response_data.py deleted file mode 100644 index 2b381912..00000000 --- a/test/test_rule_trigger_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.rule_trigger_response_data import RuleTriggerResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestRuleTriggerResponseData(unittest.TestCase): - """RuleTriggerResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testRuleTriggerResponseData(self): - """Test RuleTriggerResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.rule_trigger_response_data.RuleTriggerResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_rules_api.py b/test/test_rules_api.py deleted file mode 100644 index d98bb830..00000000 --- a/test/test_rules_api.py +++ /dev/null @@ -1,40 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.rules_api import RulesApi # noqa: E501 -from asana.rest import ApiException - - -class TestRulesApi(unittest.TestCase): - """RulesApi unit test stubs""" - - def setUp(self): - self.api = RulesApi() # noqa: E501 - - def tearDown(self): - pass - - def test_trigger_rule(self): - """Test case for trigger_rule - - Trigger a rule # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_section_base.py b/test/test_section_base.py deleted file mode 100644 index d4afc753..00000000 --- a/test/test_section_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.section_base import SectionBase # noqa: E501 -from asana.rest import ApiException - - -class TestSectionBase(unittest.TestCase): - """SectionBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testSectionBase(self): - """Test SectionBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.section_base.SectionBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_section_compact.py b/test/test_section_compact.py deleted file mode 100644 index 032ba383..00000000 --- a/test/test_section_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.section_compact import SectionCompact # noqa: E501 -from asana.rest import ApiException - - -class TestSectionCompact(unittest.TestCase): - """SectionCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testSectionCompact(self): - """Test SectionCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.section_compact.SectionCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_section_gid_add_task_body.py b/test/test_section_gid_add_task_body.py deleted file mode 100644 index b04c179a..00000000 --- a/test/test_section_gid_add_task_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.section_gid_add_task_body import SectionGidAddTaskBody # noqa: E501 -from asana.rest import ApiException - - -class TestSectionGidAddTaskBody(unittest.TestCase): - """SectionGidAddTaskBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testSectionGidAddTaskBody(self): - """Test SectionGidAddTaskBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.section_gid_add_task_body.SectionGidAddTaskBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_section_request.py b/test/test_section_request.py deleted file mode 100644 index 107b7988..00000000 --- a/test/test_section_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.section_request import SectionRequest # noqa: E501 -from asana.rest import ApiException - - -class TestSectionRequest(unittest.TestCase): - """SectionRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testSectionRequest(self): - """Test SectionRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.section_request.SectionRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_section_response.py b/test/test_section_response.py deleted file mode 100644 index 267ed6dd..00000000 --- a/test/test_section_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.section_response import SectionResponse # noqa: E501 -from asana.rest import ApiException - - -class TestSectionResponse(unittest.TestCase): - """SectionResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testSectionResponse(self): - """Test SectionResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.section_response.SectionResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_section_response_array.py b/test/test_section_response_array.py deleted file mode 100644 index 9933be4c..00000000 --- a/test/test_section_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.section_response_array import SectionResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestSectionResponseArray(unittest.TestCase): - """SectionResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testSectionResponseArray(self): - """Test SectionResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.section_response_array.SectionResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_section_response_data.py b/test/test_section_response_data.py deleted file mode 100644 index 3ad8d8f1..00000000 --- a/test/test_section_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.section_response_data import SectionResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestSectionResponseData(unittest.TestCase): - """SectionResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testSectionResponseData(self): - """Test SectionResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.section_response_data.SectionResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_section_task_insert_request.py b/test/test_section_task_insert_request.py deleted file mode 100644 index 350ea6f7..00000000 --- a/test/test_section_task_insert_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.section_task_insert_request import SectionTaskInsertRequest # noqa: E501 -from asana.rest import ApiException - - -class TestSectionTaskInsertRequest(unittest.TestCase): - """SectionTaskInsertRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testSectionTaskInsertRequest(self): - """Test SectionTaskInsertRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.section_task_insert_request.SectionTaskInsertRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_sections_api.py b/test/test_sections_api.py deleted file mode 100644 index 8fac50ae..00000000 --- a/test/test_sections_api.py +++ /dev/null @@ -1,82 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.sections_api import SectionsApi # noqa: E501 -from asana.rest import ApiException - - -class TestSectionsApi(unittest.TestCase): - """SectionsApi unit test stubs""" - - def setUp(self): - self.api = SectionsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_add_task_for_section(self): - """Test case for add_task_for_section - - Add task to section # noqa: E501 - """ - pass - - def test_create_section_for_project(self): - """Test case for create_section_for_project - - Create a section in a project # noqa: E501 - """ - pass - - def test_delete_section(self): - """Test case for delete_section - - Delete a section # noqa: E501 - """ - pass - - def test_get_section(self): - """Test case for get_section - - Get a section # noqa: E501 - """ - pass - - def test_get_sections_for_project(self): - """Test case for get_sections_for_project - - Get sections in a project # noqa: E501 - """ - pass - - def test_insert_section_for_project(self): - """Test case for insert_section_for_project - - Move or Insert sections # noqa: E501 - """ - pass - - def test_update_section(self): - """Test case for update_section - - Update a section # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_sections_insert_body.py b/test/test_sections_insert_body.py deleted file mode 100644 index dc401d68..00000000 --- a/test/test_sections_insert_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.sections_insert_body import SectionsInsertBody # noqa: E501 -from asana.rest import ApiException - - -class TestSectionsInsertBody(unittest.TestCase): - """SectionsInsertBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testSectionsInsertBody(self): - """Test SectionsInsertBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.sections_insert_body.SectionsInsertBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_sections_section_gid_body.py b/test/test_sections_section_gid_body.py deleted file mode 100644 index 6367a863..00000000 --- a/test/test_sections_section_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.sections_section_gid_body import SectionsSectionGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestSectionsSectionGidBody(unittest.TestCase): - """SectionsSectionGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testSectionsSectionGidBody(self): - """Test SectionsSectionGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.sections_section_gid_body.SectionsSectionGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_status_update_base.py b/test/test_status_update_base.py deleted file mode 100644 index 422cb0cd..00000000 --- a/test/test_status_update_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.status_update_base import StatusUpdateBase # noqa: E501 -from asana.rest import ApiException - - -class TestStatusUpdateBase(unittest.TestCase): - """StatusUpdateBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStatusUpdateBase(self): - """Test StatusUpdateBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.status_update_base.StatusUpdateBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_status_update_compact.py b/test/test_status_update_compact.py deleted file mode 100644 index 77de8ec6..00000000 --- a/test/test_status_update_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.status_update_compact import StatusUpdateCompact # noqa: E501 -from asana.rest import ApiException - - -class TestStatusUpdateCompact(unittest.TestCase): - """StatusUpdateCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStatusUpdateCompact(self): - """Test StatusUpdateCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.status_update_compact.StatusUpdateCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_status_update_request.py b/test/test_status_update_request.py deleted file mode 100644 index ed51b725..00000000 --- a/test/test_status_update_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.status_update_request import StatusUpdateRequest # noqa: E501 -from asana.rest import ApiException - - -class TestStatusUpdateRequest(unittest.TestCase): - """StatusUpdateRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStatusUpdateRequest(self): - """Test StatusUpdateRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.status_update_request.StatusUpdateRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_status_update_response.py b/test/test_status_update_response.py deleted file mode 100644 index 193756ed..00000000 --- a/test/test_status_update_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.status_update_response import StatusUpdateResponse # noqa: E501 -from asana.rest import ApiException - - -class TestStatusUpdateResponse(unittest.TestCase): - """StatusUpdateResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStatusUpdateResponse(self): - """Test StatusUpdateResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.status_update_response.StatusUpdateResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_status_update_response_array.py b/test/test_status_update_response_array.py deleted file mode 100644 index a7985860..00000000 --- a/test/test_status_update_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.status_update_response_array import StatusUpdateResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestStatusUpdateResponseArray(unittest.TestCase): - """StatusUpdateResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStatusUpdateResponseArray(self): - """Test StatusUpdateResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.status_update_response_array.StatusUpdateResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_status_update_response_data.py b/test/test_status_update_response_data.py deleted file mode 100644 index f1f70944..00000000 --- a/test/test_status_update_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.status_update_response_data import StatusUpdateResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestStatusUpdateResponseData(unittest.TestCase): - """StatusUpdateResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStatusUpdateResponseData(self): - """Test StatusUpdateResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.status_update_response_data.StatusUpdateResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_status_update_response_parent.py b/test/test_status_update_response_parent.py deleted file mode 100644 index 28f171d5..00000000 --- a/test/test_status_update_response_parent.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.status_update_response_parent import StatusUpdateResponseParent # noqa: E501 -from asana.rest import ApiException - - -class TestStatusUpdateResponseParent(unittest.TestCase): - """StatusUpdateResponseParent unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStatusUpdateResponseParent(self): - """Test StatusUpdateResponseParent""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.status_update_response_parent.StatusUpdateResponseParent() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_status_updates_api.py b/test/test_status_updates_api.py deleted file mode 100644 index d54b2136..00000000 --- a/test/test_status_updates_api.py +++ /dev/null @@ -1,61 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.status_updates_api import StatusUpdatesApi # noqa: E501 -from asana.rest import ApiException - - -class TestStatusUpdatesApi(unittest.TestCase): - """StatusUpdatesApi unit test stubs""" - - def setUp(self): - self.api = StatusUpdatesApi() # noqa: E501 - - def tearDown(self): - pass - - def test_create_status_for_object(self): - """Test case for create_status_for_object - - Create a status update # noqa: E501 - """ - pass - - def test_delete_status(self): - """Test case for delete_status - - Delete a status update # noqa: E501 - """ - pass - - def test_get_status(self): - """Test case for get_status - - Get a status update # noqa: E501 - """ - pass - - def test_get_statuses_for_object(self): - """Test case for get_statuses_for_object - - Get status updates from an object # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_status_updates_body.py b/test/test_status_updates_body.py deleted file mode 100644 index 1ff77273..00000000 --- a/test/test_status_updates_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.status_updates_body import StatusUpdatesBody # noqa: E501 -from asana.rest import ApiException - - -class TestStatusUpdatesBody(unittest.TestCase): - """StatusUpdatesBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStatusUpdatesBody(self): - """Test StatusUpdatesBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.status_updates_body.StatusUpdatesBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_stories_api.py b/test/test_stories_api.py deleted file mode 100644 index d52d2b67..00000000 --- a/test/test_stories_api.py +++ /dev/null @@ -1,68 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.stories_api import StoriesApi # noqa: E501 -from asana.rest import ApiException - - -class TestStoriesApi(unittest.TestCase): - """StoriesApi unit test stubs""" - - def setUp(self): - self.api = StoriesApi() # noqa: E501 - - def tearDown(self): - pass - - def test_create_story_for_task(self): - """Test case for create_story_for_task - - Create a story on a task # noqa: E501 - """ - pass - - def test_delete_story(self): - """Test case for delete_story - - Delete a story # noqa: E501 - """ - pass - - def test_get_stories_for_task(self): - """Test case for get_stories_for_task - - Get stories from a task # noqa: E501 - """ - pass - - def test_get_story(self): - """Test case for get_story - - Get a story # noqa: E501 - """ - pass - - def test_update_story(self): - """Test case for update_story - - Update a story # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_stories_story_gid_body.py b/test/test_stories_story_gid_body.py deleted file mode 100644 index 4c08b543..00000000 --- a/test/test_stories_story_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.stories_story_gid_body import StoriesStoryGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestStoriesStoryGidBody(unittest.TestCase): - """StoriesStoryGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoriesStoryGidBody(self): - """Test StoriesStoryGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.stories_story_gid_body.StoriesStoryGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_base.py b/test/test_story_base.py deleted file mode 100644 index e2cef184..00000000 --- a/test/test_story_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_base import StoryBase # noqa: E501 -from asana.rest import ApiException - - -class TestStoryBase(unittest.TestCase): - """StoryBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryBase(self): - """Test StoryBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_base.StoryBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_compact.py b/test/test_story_compact.py deleted file mode 100644 index fa4da486..00000000 --- a/test/test_story_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_compact import StoryCompact # noqa: E501 -from asana.rest import ApiException - - -class TestStoryCompact(unittest.TestCase): - """StoryCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryCompact(self): - """Test StoryCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_compact.StoryCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_request.py b/test/test_story_request.py deleted file mode 100644 index c82f2cdb..00000000 --- a/test/test_story_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_request import StoryRequest # noqa: E501 -from asana.rest import ApiException - - -class TestStoryRequest(unittest.TestCase): - """StoryRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryRequest(self): - """Test StoryRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_request.StoryRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response.py b/test/test_story_response.py deleted file mode 100644 index dc3166a3..00000000 --- a/test/test_story_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response import StoryResponse # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponse(unittest.TestCase): - """StoryResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponse(self): - """Test StoryResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response.StoryResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_array.py b/test/test_story_response_array.py deleted file mode 100644 index b6cdb291..00000000 --- a/test/test_story_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_array import StoryResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponseArray(unittest.TestCase): - """StoryResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponseArray(self): - """Test StoryResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_array.StoryResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_assignee.py b/test/test_story_response_assignee.py deleted file mode 100644 index ab441ffb..00000000 --- a/test/test_story_response_assignee.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_assignee import StoryResponseAssignee # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponseAssignee(unittest.TestCase): - """StoryResponseAssignee unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponseAssignee(self): - """Test StoryResponseAssignee""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_assignee.StoryResponseAssignee() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_custom_field.py b/test/test_story_response_custom_field.py deleted file mode 100644 index 5f9fa622..00000000 --- a/test/test_story_response_custom_field.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_custom_field import StoryResponseCustomField # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponseCustomField(unittest.TestCase): - """StoryResponseCustomField unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponseCustomField(self): - """Test StoryResponseCustomField""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_custom_field.StoryResponseCustomField() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_data.py b/test/test_story_response_data.py deleted file mode 100644 index c68b4570..00000000 --- a/test/test_story_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_data import StoryResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponseData(unittest.TestCase): - """StoryResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponseData(self): - """Test StoryResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_data.StoryResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_dates.py b/test/test_story_response_dates.py deleted file mode 100644 index 914ee85a..00000000 --- a/test/test_story_response_dates.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_dates import StoryResponseDates # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponseDates(unittest.TestCase): - """StoryResponseDates unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponseDates(self): - """Test StoryResponseDates""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_dates.StoryResponseDates() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_old_dates.py b/test/test_story_response_old_dates.py deleted file mode 100644 index 199491be..00000000 --- a/test/test_story_response_old_dates.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_old_dates import StoryResponseOldDates # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponseOldDates(unittest.TestCase): - """StoryResponseOldDates unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponseOldDates(self): - """Test StoryResponseOldDates""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_old_dates.StoryResponseOldDates() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_old_enum_value.py b/test/test_story_response_old_enum_value.py deleted file mode 100644 index 44423e11..00000000 --- a/test/test_story_response_old_enum_value.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_old_enum_value import StoryResponseOldEnumValue # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponseOldEnumValue(unittest.TestCase): - """StoryResponseOldEnumValue unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponseOldEnumValue(self): - """Test StoryResponseOldEnumValue""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_old_enum_value.StoryResponseOldEnumValue() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_old_section.py b/test/test_story_response_old_section.py deleted file mode 100644 index 03ee0aa6..00000000 --- a/test/test_story_response_old_section.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_old_section import StoryResponseOldSection # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponseOldSection(unittest.TestCase): - """StoryResponseOldSection unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponseOldSection(self): - """Test StoryResponseOldSection""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_old_section.StoryResponseOldSection() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_previews.py b/test/test_story_response_previews.py deleted file mode 100644 index 0c7ddbf3..00000000 --- a/test/test_story_response_previews.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_previews import StoryResponsePreviews # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponsePreviews(unittest.TestCase): - """StoryResponsePreviews unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponsePreviews(self): - """Test StoryResponsePreviews""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_previews.StoryResponsePreviews() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_project.py b/test/test_story_response_project.py deleted file mode 100644 index 41534553..00000000 --- a/test/test_story_response_project.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_project import StoryResponseProject # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponseProject(unittest.TestCase): - """StoryResponseProject unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponseProject(self): - """Test StoryResponseProject""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_project.StoryResponseProject() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_story.py b/test/test_story_response_story.py deleted file mode 100644 index fb177eb7..00000000 --- a/test/test_story_response_story.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_story import StoryResponseStory # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponseStory(unittest.TestCase): - """StoryResponseStory unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponseStory(self): - """Test StoryResponseStory""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_story.StoryResponseStory() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_tag.py b/test/test_story_response_tag.py deleted file mode 100644 index 562efb29..00000000 --- a/test/test_story_response_tag.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_tag import StoryResponseTag # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponseTag(unittest.TestCase): - """StoryResponseTag unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponseTag(self): - """Test StoryResponseTag""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_tag.StoryResponseTag() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_target.py b/test/test_story_response_target.py deleted file mode 100644 index 7fde4b4b..00000000 --- a/test/test_story_response_target.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_target import StoryResponseTarget # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponseTarget(unittest.TestCase): - """StoryResponseTarget unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponseTarget(self): - """Test StoryResponseTarget""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_target.StoryResponseTarget() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_story_response_task.py b/test/test_story_response_task.py deleted file mode 100644 index 8a8e5eeb..00000000 --- a/test/test_story_response_task.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.story_response_task import StoryResponseTask # noqa: E501 -from asana.rest import ApiException - - -class TestStoryResponseTask(unittest.TestCase): - """StoryResponseTask unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testStoryResponseTask(self): - """Test StoryResponseTask""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.story_response_task.StoryResponseTask() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_tag_base.py b/test/test_tag_base.py deleted file mode 100644 index d5a86522..00000000 --- a/test/test_tag_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.tag_base import TagBase # noqa: E501 -from asana.rest import ApiException - - -class TestTagBase(unittest.TestCase): - """TagBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTagBase(self): - """Test TagBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.tag_base.TagBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_tag_compact.py b/test/test_tag_compact.py deleted file mode 100644 index c12544e8..00000000 --- a/test/test_tag_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.tag_compact import TagCompact # noqa: E501 -from asana.rest import ApiException - - -class TestTagCompact(unittest.TestCase): - """TagCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTagCompact(self): - """Test TagCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.tag_compact.TagCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_tag_create_tag_for_workspace_request.py b/test/test_tag_create_tag_for_workspace_request.py deleted file mode 100644 index 846dec6e..00000000 --- a/test/test_tag_create_tag_for_workspace_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.tag_create_tag_for_workspace_request import TagCreateTagForWorkspaceRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTagCreateTagForWorkspaceRequest(unittest.TestCase): - """TagCreateTagForWorkspaceRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTagCreateTagForWorkspaceRequest(self): - """Test TagCreateTagForWorkspaceRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.tag_create_tag_for_workspace_request.TagCreateTagForWorkspaceRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_tag_request.py b/test/test_tag_request.py deleted file mode 100644 index e2bc3827..00000000 --- a/test/test_tag_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.tag_request import TagRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTagRequest(unittest.TestCase): - """TagRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTagRequest(self): - """Test TagRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.tag_request.TagRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_tag_response.py b/test/test_tag_response.py deleted file mode 100644 index 6feed343..00000000 --- a/test/test_tag_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.tag_response import TagResponse # noqa: E501 -from asana.rest import ApiException - - -class TestTagResponse(unittest.TestCase): - """TagResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTagResponse(self): - """Test TagResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.tag_response.TagResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_tag_response_array.py b/test/test_tag_response_array.py deleted file mode 100644 index 92e9a270..00000000 --- a/test/test_tag_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.tag_response_array import TagResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestTagResponseArray(unittest.TestCase): - """TagResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTagResponseArray(self): - """Test TagResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.tag_response_array.TagResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_tag_response_data.py b/test/test_tag_response_data.py deleted file mode 100644 index 94834740..00000000 --- a/test/test_tag_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.tag_response_data import TagResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestTagResponseData(unittest.TestCase): - """TagResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTagResponseData(self): - """Test TagResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.tag_response_data.TagResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_tags_api.py b/test/test_tags_api.py deleted file mode 100644 index 03235037..00000000 --- a/test/test_tags_api.py +++ /dev/null @@ -1,89 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.tags_api import TagsApi # noqa: E501 -from asana.rest import ApiException - - -class TestTagsApi(unittest.TestCase): - """TagsApi unit test stubs""" - - def setUp(self): - self.api = TagsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_create_tag(self): - """Test case for create_tag - - Create a tag # noqa: E501 - """ - pass - - def test_create_tag_for_workspace(self): - """Test case for create_tag_for_workspace - - Create a tag in a workspace # noqa: E501 - """ - pass - - def test_delete_tag(self): - """Test case for delete_tag - - Delete a tag # noqa: E501 - """ - pass - - def test_get_tag(self): - """Test case for get_tag - - Get a tag # noqa: E501 - """ - pass - - def test_get_tags(self): - """Test case for get_tags - - Get multiple tags # noqa: E501 - """ - pass - - def test_get_tags_for_task(self): - """Test case for get_tags_for_task - - Get a task's tags # noqa: E501 - """ - pass - - def test_get_tags_for_workspace(self): - """Test case for get_tags_for_workspace - - Get tags in a workspace # noqa: E501 - """ - pass - - def test_update_tag(self): - """Test case for update_tag - - Update a tag # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_tags_body.py b/test/test_tags_body.py deleted file mode 100644 index d07adece..00000000 --- a/test/test_tags_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.tags_body import TagsBody # noqa: E501 -from asana.rest import ApiException - - -class TestTagsBody(unittest.TestCase): - """TagsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTagsBody(self): - """Test TagsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.tags_body.TagsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_add_followers_request.py b/test/test_task_add_followers_request.py deleted file mode 100644 index ddf41462..00000000 --- a/test/test_task_add_followers_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_add_followers_request import TaskAddFollowersRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTaskAddFollowersRequest(unittest.TestCase): - """TaskAddFollowersRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskAddFollowersRequest(self): - """Test TaskAddFollowersRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_add_followers_request.TaskAddFollowersRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_add_project_request.py b/test/test_task_add_project_request.py deleted file mode 100644 index b642e6f2..00000000 --- a/test/test_task_add_project_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_add_project_request import TaskAddProjectRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTaskAddProjectRequest(unittest.TestCase): - """TaskAddProjectRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskAddProjectRequest(self): - """Test TaskAddProjectRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_add_project_request.TaskAddProjectRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_add_tag_request.py b/test/test_task_add_tag_request.py deleted file mode 100644 index d9044db9..00000000 --- a/test/test_task_add_tag_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_add_tag_request import TaskAddTagRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTaskAddTagRequest(unittest.TestCase): - """TaskAddTagRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskAddTagRequest(self): - """Test TaskAddTagRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_add_tag_request.TaskAddTagRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_base.py b/test/test_task_base.py deleted file mode 100644 index e0eea619..00000000 --- a/test/test_task_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_base import TaskBase # noqa: E501 -from asana.rest import ApiException - - -class TestTaskBase(unittest.TestCase): - """TaskBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskBase(self): - """Test TaskBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_base.TaskBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_base_completed_by.py b/test/test_task_base_completed_by.py deleted file mode 100644 index 19318c7d..00000000 --- a/test/test_task_base_completed_by.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_base_completed_by import TaskBaseCompletedBy # noqa: E501 -from asana.rest import ApiException - - -class TestTaskBaseCompletedBy(unittest.TestCase): - """TaskBaseCompletedBy unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskBaseCompletedBy(self): - """Test TaskBaseCompletedBy""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_base_completed_by.TaskBaseCompletedBy() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_base_dependencies.py b/test/test_task_base_dependencies.py deleted file mode 100644 index fbb2bf8c..00000000 --- a/test/test_task_base_dependencies.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_base_dependencies import TaskBaseDependencies # noqa: E501 -from asana.rest import ApiException - - -class TestTaskBaseDependencies(unittest.TestCase): - """TaskBaseDependencies unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskBaseDependencies(self): - """Test TaskBaseDependencies""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_base_dependencies.TaskBaseDependencies() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_base_external.py b/test/test_task_base_external.py deleted file mode 100644 index c564f803..00000000 --- a/test/test_task_base_external.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_base_external import TaskBaseExternal # noqa: E501 -from asana.rest import ApiException - - -class TestTaskBaseExternal(unittest.TestCase): - """TaskBaseExternal unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskBaseExternal(self): - """Test TaskBaseExternal""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_base_external.TaskBaseExternal() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_base_memberships.py b/test/test_task_base_memberships.py deleted file mode 100644 index 5642280a..00000000 --- a/test/test_task_base_memberships.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_base_memberships import TaskBaseMemberships # noqa: E501 -from asana.rest import ApiException - - -class TestTaskBaseMemberships(unittest.TestCase): - """TaskBaseMemberships unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskBaseMemberships(self): - """Test TaskBaseMemberships""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_base_memberships.TaskBaseMemberships() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_base_section.py b/test/test_task_base_section.py deleted file mode 100644 index 3d245456..00000000 --- a/test/test_task_base_section.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_base_section import TaskBaseSection # noqa: E501 -from asana.rest import ApiException - - -class TestTaskBaseSection(unittest.TestCase): - """TaskBaseSection unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskBaseSection(self): - """Test TaskBaseSection""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_base_section.TaskBaseSection() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_compact.py b/test/test_task_compact.py deleted file mode 100644 index b9e6cbbd..00000000 --- a/test/test_task_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_compact import TaskCompact # noqa: E501 -from asana.rest import ApiException - - -class TestTaskCompact(unittest.TestCase): - """TaskCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskCompact(self): - """Test TaskCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_compact.TaskCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_count_response.py b/test/test_task_count_response.py deleted file mode 100644 index ea37fd2b..00000000 --- a/test/test_task_count_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_count_response import TaskCountResponse # noqa: E501 -from asana.rest import ApiException - - -class TestTaskCountResponse(unittest.TestCase): - """TaskCountResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskCountResponse(self): - """Test TaskCountResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_count_response.TaskCountResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_count_response_data.py b/test/test_task_count_response_data.py deleted file mode 100644 index 2a39266c..00000000 --- a/test/test_task_count_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_count_response_data import TaskCountResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestTaskCountResponseData(unittest.TestCase): - """TaskCountResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskCountResponseData(self): - """Test TaskCountResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_count_response_data.TaskCountResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_duplicate_request.py b/test/test_task_duplicate_request.py deleted file mode 100644 index 578a1979..00000000 --- a/test/test_task_duplicate_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_duplicate_request import TaskDuplicateRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTaskDuplicateRequest(unittest.TestCase): - """TaskDuplicateRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskDuplicateRequest(self): - """Test TaskDuplicateRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_duplicate_request.TaskDuplicateRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_add_dependencies_body.py b/test/test_task_gid_add_dependencies_body.py deleted file mode 100644 index 3b5dd459..00000000 --- a/test/test_task_gid_add_dependencies_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_add_dependencies_body import TaskGidAddDependenciesBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidAddDependenciesBody(unittest.TestCase): - """TaskGidAddDependenciesBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidAddDependenciesBody(self): - """Test TaskGidAddDependenciesBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_add_dependencies_body.TaskGidAddDependenciesBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_add_dependents_body.py b/test/test_task_gid_add_dependents_body.py deleted file mode 100644 index 01a98362..00000000 --- a/test/test_task_gid_add_dependents_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_add_dependents_body import TaskGidAddDependentsBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidAddDependentsBody(unittest.TestCase): - """TaskGidAddDependentsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidAddDependentsBody(self): - """Test TaskGidAddDependentsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_add_dependents_body.TaskGidAddDependentsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_add_followers_body.py b/test/test_task_gid_add_followers_body.py deleted file mode 100644 index 74dfb46b..00000000 --- a/test/test_task_gid_add_followers_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_add_followers_body import TaskGidAddFollowersBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidAddFollowersBody(unittest.TestCase): - """TaskGidAddFollowersBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidAddFollowersBody(self): - """Test TaskGidAddFollowersBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_add_followers_body.TaskGidAddFollowersBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_add_project_body.py b/test/test_task_gid_add_project_body.py deleted file mode 100644 index c8da6c16..00000000 --- a/test/test_task_gid_add_project_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_add_project_body import TaskGidAddProjectBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidAddProjectBody(unittest.TestCase): - """TaskGidAddProjectBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidAddProjectBody(self): - """Test TaskGidAddProjectBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_add_project_body.TaskGidAddProjectBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_add_tag_body.py b/test/test_task_gid_add_tag_body.py deleted file mode 100644 index e06d64f8..00000000 --- a/test/test_task_gid_add_tag_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_add_tag_body import TaskGidAddTagBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidAddTagBody(unittest.TestCase): - """TaskGidAddTagBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidAddTagBody(self): - """Test TaskGidAddTagBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_add_tag_body.TaskGidAddTagBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_duplicate_body.py b/test/test_task_gid_duplicate_body.py deleted file mode 100644 index 823c2844..00000000 --- a/test/test_task_gid_duplicate_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_duplicate_body import TaskGidDuplicateBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidDuplicateBody(unittest.TestCase): - """TaskGidDuplicateBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidDuplicateBody(self): - """Test TaskGidDuplicateBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_duplicate_body.TaskGidDuplicateBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_remove_dependencies_body.py b/test/test_task_gid_remove_dependencies_body.py deleted file mode 100644 index cfcc4100..00000000 --- a/test/test_task_gid_remove_dependencies_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_remove_dependencies_body import TaskGidRemoveDependenciesBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidRemoveDependenciesBody(unittest.TestCase): - """TaskGidRemoveDependenciesBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidRemoveDependenciesBody(self): - """Test TaskGidRemoveDependenciesBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_remove_dependencies_body.TaskGidRemoveDependenciesBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_remove_dependents_body.py b/test/test_task_gid_remove_dependents_body.py deleted file mode 100644 index 86335ed1..00000000 --- a/test/test_task_gid_remove_dependents_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_remove_dependents_body import TaskGidRemoveDependentsBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidRemoveDependentsBody(unittest.TestCase): - """TaskGidRemoveDependentsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidRemoveDependentsBody(self): - """Test TaskGidRemoveDependentsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_remove_dependents_body.TaskGidRemoveDependentsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_remove_followers_body.py b/test/test_task_gid_remove_followers_body.py deleted file mode 100644 index 5cacc4f4..00000000 --- a/test/test_task_gid_remove_followers_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_remove_followers_body import TaskGidRemoveFollowersBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidRemoveFollowersBody(unittest.TestCase): - """TaskGidRemoveFollowersBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidRemoveFollowersBody(self): - """Test TaskGidRemoveFollowersBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_remove_followers_body.TaskGidRemoveFollowersBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_remove_project_body.py b/test/test_task_gid_remove_project_body.py deleted file mode 100644 index fb08487b..00000000 --- a/test/test_task_gid_remove_project_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_remove_project_body import TaskGidRemoveProjectBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidRemoveProjectBody(unittest.TestCase): - """TaskGidRemoveProjectBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidRemoveProjectBody(self): - """Test TaskGidRemoveProjectBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_remove_project_body.TaskGidRemoveProjectBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_remove_tag_body.py b/test/test_task_gid_remove_tag_body.py deleted file mode 100644 index 712baa0a..00000000 --- a/test/test_task_gid_remove_tag_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_remove_tag_body import TaskGidRemoveTagBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidRemoveTagBody(unittest.TestCase): - """TaskGidRemoveTagBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidRemoveTagBody(self): - """Test TaskGidRemoveTagBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_remove_tag_body.TaskGidRemoveTagBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_set_parent_body.py b/test/test_task_gid_set_parent_body.py deleted file mode 100644 index a90026e8..00000000 --- a/test/test_task_gid_set_parent_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_set_parent_body import TaskGidSetParentBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidSetParentBody(unittest.TestCase): - """TaskGidSetParentBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidSetParentBody(self): - """Test TaskGidSetParentBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_set_parent_body.TaskGidSetParentBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_stories_body.py b/test/test_task_gid_stories_body.py deleted file mode 100644 index e871944b..00000000 --- a/test/test_task_gid_stories_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_stories_body import TaskGidStoriesBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidStoriesBody(unittest.TestCase): - """TaskGidStoriesBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidStoriesBody(self): - """Test TaskGidStoriesBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_stories_body.TaskGidStoriesBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_subtasks_body.py b/test/test_task_gid_subtasks_body.py deleted file mode 100644 index 6f7c202a..00000000 --- a/test/test_task_gid_subtasks_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_subtasks_body import TaskGidSubtasksBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidSubtasksBody(unittest.TestCase): - """TaskGidSubtasksBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidSubtasksBody(self): - """Test TaskGidSubtasksBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_subtasks_body.TaskGidSubtasksBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_gid_time_tracking_entries_body.py b/test/test_task_gid_time_tracking_entries_body.py deleted file mode 100644 index d555a4ac..00000000 --- a/test/test_task_gid_time_tracking_entries_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_gid_time_tracking_entries_body import TaskGidTimeTrackingEntriesBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskGidTimeTrackingEntriesBody(unittest.TestCase): - """TaskGidTimeTrackingEntriesBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskGidTimeTrackingEntriesBody(self): - """Test TaskGidTimeTrackingEntriesBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_gid_time_tracking_entries_body.TaskGidTimeTrackingEntriesBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_remove_followers_request.py b/test/test_task_remove_followers_request.py deleted file mode 100644 index 48c6a589..00000000 --- a/test/test_task_remove_followers_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_remove_followers_request import TaskRemoveFollowersRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTaskRemoveFollowersRequest(unittest.TestCase): - """TaskRemoveFollowersRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskRemoveFollowersRequest(self): - """Test TaskRemoveFollowersRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_remove_followers_request.TaskRemoveFollowersRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_remove_project_request.py b/test/test_task_remove_project_request.py deleted file mode 100644 index 2a63830b..00000000 --- a/test/test_task_remove_project_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_remove_project_request import TaskRemoveProjectRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTaskRemoveProjectRequest(unittest.TestCase): - """TaskRemoveProjectRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskRemoveProjectRequest(self): - """Test TaskRemoveProjectRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_remove_project_request.TaskRemoveProjectRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_remove_tag_request.py b/test/test_task_remove_tag_request.py deleted file mode 100644 index 95235a22..00000000 --- a/test/test_task_remove_tag_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_remove_tag_request import TaskRemoveTagRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTaskRemoveTagRequest(unittest.TestCase): - """TaskRemoveTagRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskRemoveTagRequest(self): - """Test TaskRemoveTagRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_remove_tag_request.TaskRemoveTagRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_request.py b/test/test_task_request.py deleted file mode 100644 index 77a3af10..00000000 --- a/test/test_task_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_request import TaskRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTaskRequest(unittest.TestCase): - """TaskRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskRequest(self): - """Test TaskRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_request.TaskRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_response.py b/test/test_task_response.py deleted file mode 100644 index b2fcd9c2..00000000 --- a/test/test_task_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_response import TaskResponse # noqa: E501 -from asana.rest import ApiException - - -class TestTaskResponse(unittest.TestCase): - """TaskResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskResponse(self): - """Test TaskResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_response.TaskResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_response_array.py b/test/test_task_response_array.py deleted file mode 100644 index 6ecbcf3b..00000000 --- a/test/test_task_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_response_array import TaskResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestTaskResponseArray(unittest.TestCase): - """TaskResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskResponseArray(self): - """Test TaskResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_response_array.TaskResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_response_assignee_section.py b/test/test_task_response_assignee_section.py deleted file mode 100644 index 9fada22f..00000000 --- a/test/test_task_response_assignee_section.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_response_assignee_section import TaskResponseAssigneeSection # noqa: E501 -from asana.rest import ApiException - - -class TestTaskResponseAssigneeSection(unittest.TestCase): - """TaskResponseAssigneeSection unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskResponseAssigneeSection(self): - """Test TaskResponseAssigneeSection""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_response_assignee_section.TaskResponseAssigneeSection() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_response_custom_fields.py b/test/test_task_response_custom_fields.py deleted file mode 100644 index e8af30d9..00000000 --- a/test/test_task_response_custom_fields.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_response_custom_fields import TaskResponseCustomFields # noqa: E501 -from asana.rest import ApiException - - -class TestTaskResponseCustomFields(unittest.TestCase): - """TaskResponseCustomFields unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskResponseCustomFields(self): - """Test TaskResponseCustomFields""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_response_custom_fields.TaskResponseCustomFields() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_response_data.py b/test/test_task_response_data.py deleted file mode 100644 index d07d4741..00000000 --- a/test/test_task_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_response_data import TaskResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestTaskResponseData(unittest.TestCase): - """TaskResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskResponseData(self): - """Test TaskResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_response_data.TaskResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_response_parent.py b/test/test_task_response_parent.py deleted file mode 100644 index 722f42cb..00000000 --- a/test/test_task_response_parent.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_response_parent import TaskResponseParent # noqa: E501 -from asana.rest import ApiException - - -class TestTaskResponseParent(unittest.TestCase): - """TaskResponseParent unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskResponseParent(self): - """Test TaskResponseParent""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_response_parent.TaskResponseParent() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_response_tags.py b/test/test_task_response_tags.py deleted file mode 100644 index 596a9b00..00000000 --- a/test/test_task_response_tags.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_response_tags import TaskResponseTags # noqa: E501 -from asana.rest import ApiException - - -class TestTaskResponseTags(unittest.TestCase): - """TaskResponseTags unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskResponseTags(self): - """Test TaskResponseTags""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_response_tags.TaskResponseTags() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_response_workspace.py b/test/test_task_response_workspace.py deleted file mode 100644 index 902a17d3..00000000 --- a/test/test_task_response_workspace.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_response_workspace import TaskResponseWorkspace # noqa: E501 -from asana.rest import ApiException - - -class TestTaskResponseWorkspace(unittest.TestCase): - """TaskResponseWorkspace unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskResponseWorkspace(self): - """Test TaskResponseWorkspace""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_response_workspace.TaskResponseWorkspace() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_set_parent_request.py b/test/test_task_set_parent_request.py deleted file mode 100644 index e15dca07..00000000 --- a/test/test_task_set_parent_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_set_parent_request import TaskSetParentRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTaskSetParentRequest(unittest.TestCase): - """TaskSetParentRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskSetParentRequest(self): - """Test TaskSetParentRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_set_parent_request.TaskSetParentRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_template_base.py b/test/test_task_template_base.py deleted file mode 100644 index 88492bc7..00000000 --- a/test/test_task_template_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_template_base import TaskTemplateBase # noqa: E501 -from asana.rest import ApiException - - -class TestTaskTemplateBase(unittest.TestCase): - """TaskTemplateBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskTemplateBase(self): - """Test TaskTemplateBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_template_base.TaskTemplateBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_template_compact.py b/test/test_task_template_compact.py deleted file mode 100644 index 139c9e73..00000000 --- a/test/test_task_template_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_template_compact import TaskTemplateCompact # noqa: E501 -from asana.rest import ApiException - - -class TestTaskTemplateCompact(unittest.TestCase): - """TaskTemplateCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskTemplateCompact(self): - """Test TaskTemplateCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_template_compact.TaskTemplateCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_template_gid_instantiate_task_body.py b/test/test_task_template_gid_instantiate_task_body.py deleted file mode 100644 index 0e4b04a0..00000000 --- a/test/test_task_template_gid_instantiate_task_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_template_gid_instantiate_task_body import TaskTemplateGidInstantiateTaskBody # noqa: E501 -from asana.rest import ApiException - - -class TestTaskTemplateGidInstantiateTaskBody(unittest.TestCase): - """TaskTemplateGidInstantiateTaskBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskTemplateGidInstantiateTaskBody(self): - """Test TaskTemplateGidInstantiateTaskBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_template_gid_instantiate_task_body.TaskTemplateGidInstantiateTaskBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_template_instantiate_task_request.py b/test/test_task_template_instantiate_task_request.py deleted file mode 100644 index dee89ff0..00000000 --- a/test/test_task_template_instantiate_task_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_template_instantiate_task_request import TaskTemplateInstantiateTaskRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTaskTemplateInstantiateTaskRequest(unittest.TestCase): - """TaskTemplateInstantiateTaskRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskTemplateInstantiateTaskRequest(self): - """Test TaskTemplateInstantiateTaskRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_template_instantiate_task_request.TaskTemplateInstantiateTaskRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_template_recipe.py b/test/test_task_template_recipe.py deleted file mode 100644 index 146ea294..00000000 --- a/test/test_task_template_recipe.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_template_recipe import TaskTemplateRecipe # noqa: E501 -from asana.rest import ApiException - - -class TestTaskTemplateRecipe(unittest.TestCase): - """TaskTemplateRecipe unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskTemplateRecipe(self): - """Test TaskTemplateRecipe""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_template_recipe.TaskTemplateRecipe() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_template_recipe_attachments.py b/test/test_task_template_recipe_attachments.py deleted file mode 100644 index 8be2604f..00000000 --- a/test/test_task_template_recipe_attachments.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_template_recipe_attachments import TaskTemplateRecipeAttachments # noqa: E501 -from asana.rest import ApiException - - -class TestTaskTemplateRecipeAttachments(unittest.TestCase): - """TaskTemplateRecipeAttachments unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskTemplateRecipeAttachments(self): - """Test TaskTemplateRecipeAttachments""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_template_recipe_attachments.TaskTemplateRecipeAttachments() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_template_recipe_compact.py b/test/test_task_template_recipe_compact.py deleted file mode 100644 index 2c384e2f..00000000 --- a/test/test_task_template_recipe_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_template_recipe_compact import TaskTemplateRecipeCompact # noqa: E501 -from asana.rest import ApiException - - -class TestTaskTemplateRecipeCompact(unittest.TestCase): - """TaskTemplateRecipeCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskTemplateRecipeCompact(self): - """Test TaskTemplateRecipeCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_template_recipe_compact.TaskTemplateRecipeCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_template_recipe_dependencies.py b/test/test_task_template_recipe_dependencies.py deleted file mode 100644 index 2460ace4..00000000 --- a/test/test_task_template_recipe_dependencies.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_template_recipe_dependencies import TaskTemplateRecipeDependencies # noqa: E501 -from asana.rest import ApiException - - -class TestTaskTemplateRecipeDependencies(unittest.TestCase): - """TaskTemplateRecipeDependencies unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskTemplateRecipeDependencies(self): - """Test TaskTemplateRecipeDependencies""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_template_recipe_dependencies.TaskTemplateRecipeDependencies() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_template_response.py b/test/test_task_template_response.py deleted file mode 100644 index 1cc1746d..00000000 --- a/test/test_task_template_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_template_response import TaskTemplateResponse # noqa: E501 -from asana.rest import ApiException - - -class TestTaskTemplateResponse(unittest.TestCase): - """TaskTemplateResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskTemplateResponse(self): - """Test TaskTemplateResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_template_response.TaskTemplateResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_template_response_array.py b/test/test_task_template_response_array.py deleted file mode 100644 index 99bb1e33..00000000 --- a/test/test_task_template_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_template_response_array import TaskTemplateResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestTaskTemplateResponseArray(unittest.TestCase): - """TaskTemplateResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskTemplateResponseArray(self): - """Test TaskTemplateResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_template_response_array.TaskTemplateResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_template_response_data.py b/test/test_task_template_response_data.py deleted file mode 100644 index eeded579..00000000 --- a/test/test_task_template_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.task_template_response_data import TaskTemplateResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestTaskTemplateResponseData(unittest.TestCase): - """TaskTemplateResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTaskTemplateResponseData(self): - """Test TaskTemplateResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.task_template_response_data.TaskTemplateResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_task_templates_api.py b/test/test_task_templates_api.py deleted file mode 100644 index 5bf08710..00000000 --- a/test/test_task_templates_api.py +++ /dev/null @@ -1,54 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.task_templates_api import TaskTemplatesApi # noqa: E501 -from asana.rest import ApiException - - -class TestTaskTemplatesApi(unittest.TestCase): - """TaskTemplatesApi unit test stubs""" - - def setUp(self): - self.api = TaskTemplatesApi() # noqa: E501 - - def tearDown(self): - pass - - def test_get_task_template(self): - """Test case for get_task_template - - Get a task template # noqa: E501 - """ - pass - - def test_get_task_templates(self): - """Test case for get_task_templates - - Get multiple task templates # noqa: E501 - """ - pass - - def test_instantiate_task(self): - """Test case for instantiate_task - - Instantiate a task from a task template # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_tasks_api.py b/test/test_tasks_api.py deleted file mode 100644 index a66ced7e..00000000 --- a/test/test_tasks_api.py +++ /dev/null @@ -1,215 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.tasks_api import TasksApi # noqa: E501 -from asana.rest import ApiException - - -class TestTasksApi(unittest.TestCase): - """TasksApi unit test stubs""" - - def setUp(self): - self.api = TasksApi() # noqa: E501 - - def tearDown(self): - pass - - def test_add_dependencies_for_task(self): - """Test case for add_dependencies_for_task - - Set dependencies for a task # noqa: E501 - """ - pass - - def test_add_dependents_for_task(self): - """Test case for add_dependents_for_task - - Set dependents for a task # noqa: E501 - """ - pass - - def test_add_followers_for_task(self): - """Test case for add_followers_for_task - - Add followers to a task # noqa: E501 - """ - pass - - def test_add_project_for_task(self): - """Test case for add_project_for_task - - Add a project to a task # noqa: E501 - """ - pass - - def test_add_tag_for_task(self): - """Test case for add_tag_for_task - - Add a tag to a task # noqa: E501 - """ - pass - - def test_create_subtask_for_task(self): - """Test case for create_subtask_for_task - - Create a subtask # noqa: E501 - """ - pass - - def test_create_task(self): - """Test case for create_task - - Create a task # noqa: E501 - """ - pass - - def test_delete_task(self): - """Test case for delete_task - - Delete a task # noqa: E501 - """ - pass - - def test_duplicate_task(self): - """Test case for duplicate_task - - Duplicate a task # noqa: E501 - """ - pass - - def test_get_dependencies_for_task(self): - """Test case for get_dependencies_for_task - - Get dependencies from a task # noqa: E501 - """ - pass - - def test_get_dependents_for_task(self): - """Test case for get_dependents_for_task - - Get dependents from a task # noqa: E501 - """ - pass - - def test_get_subtasks_for_task(self): - """Test case for get_subtasks_for_task - - Get subtasks from a task # noqa: E501 - """ - pass - - def test_get_task(self): - """Test case for get_task - - Get a task # noqa: E501 - """ - pass - - def test_get_tasks(self): - """Test case for get_tasks - - Get multiple tasks # noqa: E501 - """ - pass - - def test_get_tasks_for_project(self): - """Test case for get_tasks_for_project - - Get tasks from a project # noqa: E501 - """ - pass - - def test_get_tasks_for_section(self): - """Test case for get_tasks_for_section - - Get tasks from a section # noqa: E501 - """ - pass - - def test_get_tasks_for_tag(self): - """Test case for get_tasks_for_tag - - Get tasks from a tag # noqa: E501 - """ - pass - - def test_get_tasks_for_user_task_list(self): - """Test case for get_tasks_for_user_task_list - - Get tasks from a user task list # noqa: E501 - """ - pass - - def test_remove_dependencies_for_task(self): - """Test case for remove_dependencies_for_task - - Unlink dependencies from a task # noqa: E501 - """ - pass - - def test_remove_dependents_for_task(self): - """Test case for remove_dependents_for_task - - Unlink dependents from a task # noqa: E501 - """ - pass - - def test_remove_follower_for_task(self): - """Test case for remove_follower_for_task - - Remove followers from a task # noqa: E501 - """ - pass - - def test_remove_project_for_task(self): - """Test case for remove_project_for_task - - Remove a project from a task # noqa: E501 - """ - pass - - def test_remove_tag_for_task(self): - """Test case for remove_tag_for_task - - Remove a tag from a task # noqa: E501 - """ - pass - - def test_search_tasks_for_workspace(self): - """Test case for search_tasks_for_workspace - - Search tasks in a workspace # noqa: E501 - """ - pass - - def test_set_parent_for_task(self): - """Test case for set_parent_for_task - - Set the parent of a task # noqa: E501 - """ - pass - - def test_update_task(self): - """Test case for update_task - - Update a task # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_tasks_body.py b/test/test_tasks_body.py deleted file mode 100644 index 0b98bc56..00000000 --- a/test/test_tasks_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.tasks_body import TasksBody # noqa: E501 -from asana.rest import ApiException - - -class TestTasksBody(unittest.TestCase): - """TasksBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTasksBody(self): - """Test TasksBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.tasks_body.TasksBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_tasks_task_gid_body.py b/test/test_tasks_task_gid_body.py deleted file mode 100644 index ece50ffa..00000000 --- a/test/test_tasks_task_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.tasks_task_gid_body import TasksTaskGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestTasksTaskGidBody(unittest.TestCase): - """TasksTaskGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTasksTaskGidBody(self): - """Test TasksTaskGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.tasks_task_gid_body.TasksTaskGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_add_user_request.py b/test/test_team_add_user_request.py deleted file mode 100644 index 11d0f64f..00000000 --- a/test/test_team_add_user_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_add_user_request import TeamAddUserRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTeamAddUserRequest(unittest.TestCase): - """TeamAddUserRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamAddUserRequest(self): - """Test TeamAddUserRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_add_user_request.TeamAddUserRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_base.py b/test/test_team_base.py deleted file mode 100644 index d7523e28..00000000 --- a/test/test_team_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_base import TeamBase # noqa: E501 -from asana.rest import ApiException - - -class TestTeamBase(unittest.TestCase): - """TeamBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamBase(self): - """Test TeamBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_base.TeamBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_compact.py b/test/test_team_compact.py deleted file mode 100644 index 2b783a57..00000000 --- a/test/test_team_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_compact import TeamCompact # noqa: E501 -from asana.rest import ApiException - - -class TestTeamCompact(unittest.TestCase): - """TeamCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamCompact(self): - """Test TeamCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_compact.TeamCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_gid_add_user_body.py b/test/test_team_gid_add_user_body.py deleted file mode 100644 index b9e225d8..00000000 --- a/test/test_team_gid_add_user_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_gid_add_user_body import TeamGidAddUserBody # noqa: E501 -from asana.rest import ApiException - - -class TestTeamGidAddUserBody(unittest.TestCase): - """TeamGidAddUserBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamGidAddUserBody(self): - """Test TeamGidAddUserBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_gid_add_user_body.TeamGidAddUserBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_gid_projects_body.py b/test/test_team_gid_projects_body.py deleted file mode 100644 index 7156fd47..00000000 --- a/test/test_team_gid_projects_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_gid_projects_body import TeamGidProjectsBody # noqa: E501 -from asana.rest import ApiException - - -class TestTeamGidProjectsBody(unittest.TestCase): - """TeamGidProjectsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamGidProjectsBody(self): - """Test TeamGidProjectsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_gid_projects_body.TeamGidProjectsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_gid_remove_user_body.py b/test/test_team_gid_remove_user_body.py deleted file mode 100644 index 28411801..00000000 --- a/test/test_team_gid_remove_user_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_gid_remove_user_body import TeamGidRemoveUserBody # noqa: E501 -from asana.rest import ApiException - - -class TestTeamGidRemoveUserBody(unittest.TestCase): - """TeamGidRemoveUserBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamGidRemoveUserBody(self): - """Test TeamGidRemoveUserBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_gid_remove_user_body.TeamGidRemoveUserBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_membership_base.py b/test/test_team_membership_base.py deleted file mode 100644 index 825e6fed..00000000 --- a/test/test_team_membership_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_membership_base import TeamMembershipBase # noqa: E501 -from asana.rest import ApiException - - -class TestTeamMembershipBase(unittest.TestCase): - """TeamMembershipBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamMembershipBase(self): - """Test TeamMembershipBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_membership_base.TeamMembershipBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_membership_compact.py b/test/test_team_membership_compact.py deleted file mode 100644 index 83f6fc70..00000000 --- a/test/test_team_membership_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_membership_compact import TeamMembershipCompact # noqa: E501 -from asana.rest import ApiException - - -class TestTeamMembershipCompact(unittest.TestCase): - """TeamMembershipCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamMembershipCompact(self): - """Test TeamMembershipCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_membership_compact.TeamMembershipCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_membership_response.py b/test/test_team_membership_response.py deleted file mode 100644 index f1df40d5..00000000 --- a/test/test_team_membership_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_membership_response import TeamMembershipResponse # noqa: E501 -from asana.rest import ApiException - - -class TestTeamMembershipResponse(unittest.TestCase): - """TeamMembershipResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamMembershipResponse(self): - """Test TeamMembershipResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_membership_response.TeamMembershipResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_membership_response_array.py b/test/test_team_membership_response_array.py deleted file mode 100644 index d9197dac..00000000 --- a/test/test_team_membership_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_membership_response_array import TeamMembershipResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestTeamMembershipResponseArray(unittest.TestCase): - """TeamMembershipResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamMembershipResponseArray(self): - """Test TeamMembershipResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_membership_response_array.TeamMembershipResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_membership_response_data.py b/test/test_team_membership_response_data.py deleted file mode 100644 index fa2d2305..00000000 --- a/test/test_team_membership_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_membership_response_data import TeamMembershipResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestTeamMembershipResponseData(unittest.TestCase): - """TeamMembershipResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamMembershipResponseData(self): - """Test TeamMembershipResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_membership_response_data.TeamMembershipResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_memberships_api.py b/test/test_team_memberships_api.py deleted file mode 100644 index 6ed7e137..00000000 --- a/test/test_team_memberships_api.py +++ /dev/null @@ -1,61 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.team_memberships_api import TeamMembershipsApi # noqa: E501 -from asana.rest import ApiException - - -class TestTeamMembershipsApi(unittest.TestCase): - """TeamMembershipsApi unit test stubs""" - - def setUp(self): - self.api = TeamMembershipsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_get_team_membership(self): - """Test case for get_team_membership - - Get a team membership # noqa: E501 - """ - pass - - def test_get_team_memberships(self): - """Test case for get_team_memberships - - Get team memberships # noqa: E501 - """ - pass - - def test_get_team_memberships_for_team(self): - """Test case for get_team_memberships_for_team - - Get memberships from a team # noqa: E501 - """ - pass - - def test_get_team_memberships_for_user(self): - """Test case for get_team_memberships_for_user - - Get memberships from a user # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_remove_user_request.py b/test/test_team_remove_user_request.py deleted file mode 100644 index 54869ada..00000000 --- a/test/test_team_remove_user_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_remove_user_request import TeamRemoveUserRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTeamRemoveUserRequest(unittest.TestCase): - """TeamRemoveUserRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamRemoveUserRequest(self): - """Test TeamRemoveUserRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_remove_user_request.TeamRemoveUserRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_request.py b/test/test_team_request.py deleted file mode 100644 index 51c43370..00000000 --- a/test/test_team_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_request import TeamRequest # noqa: E501 -from asana.rest import ApiException - - -class TestTeamRequest(unittest.TestCase): - """TeamRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamRequest(self): - """Test TeamRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_request.TeamRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_response.py b/test/test_team_response.py deleted file mode 100644 index 89370908..00000000 --- a/test/test_team_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_response import TeamResponse # noqa: E501 -from asana.rest import ApiException - - -class TestTeamResponse(unittest.TestCase): - """TeamResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamResponse(self): - """Test TeamResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_response.TeamResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_response_array.py b/test/test_team_response_array.py deleted file mode 100644 index c0946f90..00000000 --- a/test/test_team_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_response_array import TeamResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestTeamResponseArray(unittest.TestCase): - """TeamResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamResponseArray(self): - """Test TeamResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_response_array.TeamResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_response_data.py b/test/test_team_response_data.py deleted file mode 100644 index 875a8977..00000000 --- a/test/test_team_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_response_data import TeamResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestTeamResponseData(unittest.TestCase): - """TeamResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamResponseData(self): - """Test TeamResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_response_data.TeamResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_team_response_organization.py b/test/test_team_response_organization.py deleted file mode 100644 index 176bccf5..00000000 --- a/test/test_team_response_organization.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.team_response_organization import TeamResponseOrganization # noqa: E501 -from asana.rest import ApiException - - -class TestTeamResponseOrganization(unittest.TestCase): - """TeamResponseOrganization unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamResponseOrganization(self): - """Test TeamResponseOrganization""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.team_response_organization.TeamResponseOrganization() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_teams_api.py b/test/test_teams_api.py deleted file mode 100644 index 6b114d60..00000000 --- a/test/test_teams_api.py +++ /dev/null @@ -1,82 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.teams_api import TeamsApi # noqa: E501 -from asana.rest import ApiException - - -class TestTeamsApi(unittest.TestCase): - """TeamsApi unit test stubs""" - - def setUp(self): - self.api = TeamsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_add_user_for_team(self): - """Test case for add_user_for_team - - Add a user to a team # noqa: E501 - """ - pass - - def test_create_team(self): - """Test case for create_team - - Create a team # noqa: E501 - """ - pass - - def test_get_team(self): - """Test case for get_team - - Get a team # noqa: E501 - """ - pass - - def test_get_teams_for_user(self): - """Test case for get_teams_for_user - - Get teams for a user # noqa: E501 - """ - pass - - def test_get_teams_for_workspace(self): - """Test case for get_teams_for_workspace - - Get teams in a workspace # noqa: E501 - """ - pass - - def test_remove_user_for_team(self): - """Test case for remove_user_for_team - - Remove a user from a team # noqa: E501 - """ - pass - - def test_update_team(self): - """Test case for update_team - - Update a team # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_teams_body.py b/test/test_teams_body.py deleted file mode 100644 index dc5782e1..00000000 --- a/test/test_teams_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.teams_body import TeamsBody # noqa: E501 -from asana.rest import ApiException - - -class TestTeamsBody(unittest.TestCase): - """TeamsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamsBody(self): - """Test TeamsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.teams_body.TeamsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_teams_team_gid_body.py b/test/test_teams_team_gid_body.py deleted file mode 100644 index 31c84fc1..00000000 --- a/test/test_teams_team_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.teams_team_gid_body import TeamsTeamGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestTeamsTeamGidBody(unittest.TestCase): - """TeamsTeamGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTeamsTeamGidBody(self): - """Test TeamsTeamGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.teams_team_gid_body.TeamsTeamGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_template_role.py b/test/test_template_role.py deleted file mode 100644 index 9b8f9ccd..00000000 --- a/test/test_template_role.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.template_role import TemplateRole # noqa: E501 -from asana.rest import ApiException - - -class TestTemplateRole(unittest.TestCase): - """TemplateRole unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTemplateRole(self): - """Test TemplateRole""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.template_role.TemplateRole() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_time_period_base.py b/test/test_time_period_base.py deleted file mode 100644 index 00a7b675..00000000 --- a/test/test_time_period_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.time_period_base import TimePeriodBase # noqa: E501 -from asana.rest import ApiException - - -class TestTimePeriodBase(unittest.TestCase): - """TimePeriodBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTimePeriodBase(self): - """Test TimePeriodBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.time_period_base.TimePeriodBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_time_period_compact.py b/test/test_time_period_compact.py deleted file mode 100644 index 61034f5a..00000000 --- a/test/test_time_period_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.time_period_compact import TimePeriodCompact # noqa: E501 -from asana.rest import ApiException - - -class TestTimePeriodCompact(unittest.TestCase): - """TimePeriodCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTimePeriodCompact(self): - """Test TimePeriodCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.time_period_compact.TimePeriodCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_time_period_response.py b/test/test_time_period_response.py deleted file mode 100644 index 35315067..00000000 --- a/test/test_time_period_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.time_period_response import TimePeriodResponse # noqa: E501 -from asana.rest import ApiException - - -class TestTimePeriodResponse(unittest.TestCase): - """TimePeriodResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTimePeriodResponse(self): - """Test TimePeriodResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.time_period_response.TimePeriodResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_time_period_response_array.py b/test/test_time_period_response_array.py deleted file mode 100644 index ef76c954..00000000 --- a/test/test_time_period_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.time_period_response_array import TimePeriodResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestTimePeriodResponseArray(unittest.TestCase): - """TimePeriodResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTimePeriodResponseArray(self): - """Test TimePeriodResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.time_period_response_array.TimePeriodResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_time_period_response_data.py b/test/test_time_period_response_data.py deleted file mode 100644 index 697f9974..00000000 --- a/test/test_time_period_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.time_period_response_data import TimePeriodResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestTimePeriodResponseData(unittest.TestCase): - """TimePeriodResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTimePeriodResponseData(self): - """Test TimePeriodResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.time_period_response_data.TimePeriodResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_time_periods_api.py b/test/test_time_periods_api.py deleted file mode 100644 index 1520f9d0..00000000 --- a/test/test_time_periods_api.py +++ /dev/null @@ -1,47 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.time_periods_api import TimePeriodsApi # noqa: E501 -from asana.rest import ApiException - - -class TestTimePeriodsApi(unittest.TestCase): - """TimePeriodsApi unit test stubs""" - - def setUp(self): - self.api = TimePeriodsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_get_time_period(self): - """Test case for get_time_period - - Get a time period # noqa: E501 - """ - pass - - def test_get_time_periods(self): - """Test case for get_time_periods - - Get time periods # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_time_tracking_entries_api.py b/test/test_time_tracking_entries_api.py deleted file mode 100644 index badc3f1b..00000000 --- a/test/test_time_tracking_entries_api.py +++ /dev/null @@ -1,68 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.time_tracking_entries_api import TimeTrackingEntriesApi # noqa: E501 -from asana.rest import ApiException - - -class TestTimeTrackingEntriesApi(unittest.TestCase): - """TimeTrackingEntriesApi unit test stubs""" - - def setUp(self): - self.api = TimeTrackingEntriesApi() # noqa: E501 - - def tearDown(self): - pass - - def test_create_time_tracking_entry(self): - """Test case for create_time_tracking_entry - - Create a time tracking entry # noqa: E501 - """ - pass - - def test_delete_time_tracking_entry(self): - """Test case for delete_time_tracking_entry - - Delete a time tracking entry # noqa: E501 - """ - pass - - def test_get_time_tracking_entries_for_task(self): - """Test case for get_time_tracking_entries_for_task - - Get time tracking entries for a task # noqa: E501 - """ - pass - - def test_get_time_tracking_entry(self): - """Test case for get_time_tracking_entry - - Get a time tracking entry # noqa: E501 - """ - pass - - def test_update_time_tracking_entry(self): - """Test case for update_time_tracking_entry - - Update a time tracking entry # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_time_tracking_entries_time_tracking_entry_gid_body.py b/test/test_time_tracking_entries_time_tracking_entry_gid_body.py deleted file mode 100644 index 68390ea2..00000000 --- a/test/test_time_tracking_entries_time_tracking_entry_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.time_tracking_entries_time_tracking_entry_gid_body import TimeTrackingEntriesTimeTrackingEntryGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestTimeTrackingEntriesTimeTrackingEntryGidBody(unittest.TestCase): - """TimeTrackingEntriesTimeTrackingEntryGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTimeTrackingEntriesTimeTrackingEntryGidBody(self): - """Test TimeTrackingEntriesTimeTrackingEntryGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.time_tracking_entries_time_tracking_entry_gid_body.TimeTrackingEntriesTimeTrackingEntryGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_time_tracking_entry_base.py b/test/test_time_tracking_entry_base.py deleted file mode 100644 index b064c15c..00000000 --- a/test/test_time_tracking_entry_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.time_tracking_entry_base import TimeTrackingEntryBase # noqa: E501 -from asana.rest import ApiException - - -class TestTimeTrackingEntryBase(unittest.TestCase): - """TimeTrackingEntryBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTimeTrackingEntryBase(self): - """Test TimeTrackingEntryBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.time_tracking_entry_base.TimeTrackingEntryBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_time_tracking_entry_base_data.py b/test/test_time_tracking_entry_base_data.py deleted file mode 100644 index 878a5f74..00000000 --- a/test/test_time_tracking_entry_base_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.time_tracking_entry_base_data import TimeTrackingEntryBaseData # noqa: E501 -from asana.rest import ApiException - - -class TestTimeTrackingEntryBaseData(unittest.TestCase): - """TimeTrackingEntryBaseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTimeTrackingEntryBaseData(self): - """Test TimeTrackingEntryBaseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.time_tracking_entry_base_data.TimeTrackingEntryBaseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_time_tracking_entry_compact.py b/test/test_time_tracking_entry_compact.py deleted file mode 100644 index 53951059..00000000 --- a/test/test_time_tracking_entry_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.time_tracking_entry_compact import TimeTrackingEntryCompact # noqa: E501 -from asana.rest import ApiException - - -class TestTimeTrackingEntryCompact(unittest.TestCase): - """TimeTrackingEntryCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTimeTrackingEntryCompact(self): - """Test TimeTrackingEntryCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.time_tracking_entry_compact.TimeTrackingEntryCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_time_tracking_entry_compact_array.py b/test/test_time_tracking_entry_compact_array.py deleted file mode 100644 index 9885cb46..00000000 --- a/test/test_time_tracking_entry_compact_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.time_tracking_entry_compact_array import TimeTrackingEntryCompactArray # noqa: E501 -from asana.rest import ApiException - - -class TestTimeTrackingEntryCompactArray(unittest.TestCase): - """TimeTrackingEntryCompactArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testTimeTrackingEntryCompactArray(self): - """Test TimeTrackingEntryCompactArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.time_tracking_entry_compact_array.TimeTrackingEntryCompactArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_typeahead_api.py b/test/test_typeahead_api.py deleted file mode 100644 index 3d977d05..00000000 --- a/test/test_typeahead_api.py +++ /dev/null @@ -1,40 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.typeahead_api import TypeaheadApi # noqa: E501 -from asana.rest import ApiException - - -class TestTypeaheadApi(unittest.TestCase): - """TypeaheadApi unit test stubs""" - - def setUp(self): - self.api = TypeaheadApi() # noqa: E501 - - def tearDown(self): - pass - - def test_typeahead_for_workspace(self): - """Test case for typeahead_for_workspace - - Get objects via typeahead # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_update_time_tracking_entry_request.py b/test/test_update_time_tracking_entry_request.py deleted file mode 100644 index 0f388df9..00000000 --- a/test/test_update_time_tracking_entry_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.update_time_tracking_entry_request import UpdateTimeTrackingEntryRequest # noqa: E501 -from asana.rest import ApiException - - -class TestUpdateTimeTrackingEntryRequest(unittest.TestCase): - """UpdateTimeTrackingEntryRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUpdateTimeTrackingEntryRequest(self): - """Test UpdateTimeTrackingEntryRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.update_time_tracking_entry_request.UpdateTimeTrackingEntryRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_base.py b/test/test_user_base.py deleted file mode 100644 index 7b29864b..00000000 --- a/test/test_user_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_base import UserBase # noqa: E501 -from asana.rest import ApiException - - -class TestUserBase(unittest.TestCase): - """UserBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserBase(self): - """Test UserBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_base.UserBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_base_response.py b/test/test_user_base_response.py deleted file mode 100644 index 56cc3faa..00000000 --- a/test/test_user_base_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_base_response import UserBaseResponse # noqa: E501 -from asana.rest import ApiException - - -class TestUserBaseResponse(unittest.TestCase): - """UserBaseResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserBaseResponse(self): - """Test UserBaseResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_base_response.UserBaseResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_base_response_data.py b/test/test_user_base_response_data.py deleted file mode 100644 index b8f1d456..00000000 --- a/test/test_user_base_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_base_response_data import UserBaseResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestUserBaseResponseData(unittest.TestCase): - """UserBaseResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserBaseResponseData(self): - """Test UserBaseResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_base_response_data.UserBaseResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_base_response_photo.py b/test/test_user_base_response_photo.py deleted file mode 100644 index 292c00cf..00000000 --- a/test/test_user_base_response_photo.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_base_response_photo import UserBaseResponsePhoto # noqa: E501 -from asana.rest import ApiException - - -class TestUserBaseResponsePhoto(unittest.TestCase): - """UserBaseResponsePhoto unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserBaseResponsePhoto(self): - """Test UserBaseResponsePhoto""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_base_response_photo.UserBaseResponsePhoto() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_compact.py b/test/test_user_compact.py deleted file mode 100644 index 6f776b71..00000000 --- a/test/test_user_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_compact import UserCompact # noqa: E501 -from asana.rest import ApiException - - -class TestUserCompact(unittest.TestCase): - """UserCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserCompact(self): - """Test UserCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_compact.UserCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_request.py b/test/test_user_request.py deleted file mode 100644 index 7b346736..00000000 --- a/test/test_user_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_request import UserRequest # noqa: E501 -from asana.rest import ApiException - - -class TestUserRequest(unittest.TestCase): - """UserRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserRequest(self): - """Test UserRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_request.UserRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_response.py b/test/test_user_response.py deleted file mode 100644 index ecb3ab97..00000000 --- a/test/test_user_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_response import UserResponse # noqa: E501 -from asana.rest import ApiException - - -class TestUserResponse(unittest.TestCase): - """UserResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserResponse(self): - """Test UserResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_response.UserResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_response_array.py b/test/test_user_response_array.py deleted file mode 100644 index 3713aaf4..00000000 --- a/test/test_user_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_response_array import UserResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestUserResponseArray(unittest.TestCase): - """UserResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserResponseArray(self): - """Test UserResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_response_array.UserResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_response_data.py b/test/test_user_response_data.py deleted file mode 100644 index eb46541e..00000000 --- a/test/test_user_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_response_data import UserResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestUserResponseData(unittest.TestCase): - """UserResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserResponseData(self): - """Test UserResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_response_data.UserResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_task_list_base.py b/test/test_user_task_list_base.py deleted file mode 100644 index ae6860ab..00000000 --- a/test/test_user_task_list_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_task_list_base import UserTaskListBase # noqa: E501 -from asana.rest import ApiException - - -class TestUserTaskListBase(unittest.TestCase): - """UserTaskListBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserTaskListBase(self): - """Test UserTaskListBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_task_list_base.UserTaskListBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_task_list_compact.py b/test/test_user_task_list_compact.py deleted file mode 100644 index afcb5835..00000000 --- a/test/test_user_task_list_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_task_list_compact import UserTaskListCompact # noqa: E501 -from asana.rest import ApiException - - -class TestUserTaskListCompact(unittest.TestCase): - """UserTaskListCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserTaskListCompact(self): - """Test UserTaskListCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_task_list_compact.UserTaskListCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_task_list_request.py b/test/test_user_task_list_request.py deleted file mode 100644 index 11527131..00000000 --- a/test/test_user_task_list_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_task_list_request import UserTaskListRequest # noqa: E501 -from asana.rest import ApiException - - -class TestUserTaskListRequest(unittest.TestCase): - """UserTaskListRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserTaskListRequest(self): - """Test UserTaskListRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_task_list_request.UserTaskListRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_task_list_response.py b/test/test_user_task_list_response.py deleted file mode 100644 index d9663333..00000000 --- a/test/test_user_task_list_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_task_list_response import UserTaskListResponse # noqa: E501 -from asana.rest import ApiException - - -class TestUserTaskListResponse(unittest.TestCase): - """UserTaskListResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserTaskListResponse(self): - """Test UserTaskListResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_task_list_response.UserTaskListResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_task_list_response_data.py b/test/test_user_task_list_response_data.py deleted file mode 100644 index c3c285f0..00000000 --- a/test/test_user_task_list_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.user_task_list_response_data import UserTaskListResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestUserTaskListResponseData(unittest.TestCase): - """UserTaskListResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testUserTaskListResponseData(self): - """Test UserTaskListResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.user_task_list_response_data.UserTaskListResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_user_task_lists_api.py b/test/test_user_task_lists_api.py deleted file mode 100644 index c7d53c27..00000000 --- a/test/test_user_task_lists_api.py +++ /dev/null @@ -1,47 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.user_task_lists_api import UserTaskListsApi # noqa: E501 -from asana.rest import ApiException - - -class TestUserTaskListsApi(unittest.TestCase): - """UserTaskListsApi unit test stubs""" - - def setUp(self): - self.api = UserTaskListsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_get_user_task_list(self): - """Test case for get_user_task_list - - Get a user task list # noqa: E501 - """ - pass - - def test_get_user_task_list_for_user(self): - """Test case for get_user_task_list_for_user - - Get a user's task list # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_users_api.py b/test/test_users_api.py deleted file mode 100644 index 73258f4d..00000000 --- a/test/test_users_api.py +++ /dev/null @@ -1,68 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.users_api import UsersApi # noqa: E501 -from asana.rest import ApiException - - -class TestUsersApi(unittest.TestCase): - """UsersApi unit test stubs""" - - def setUp(self): - self.api = UsersApi() # noqa: E501 - - def tearDown(self): - pass - - def test_get_favorites_for_user(self): - """Test case for get_favorites_for_user - - Get a user's favorites # noqa: E501 - """ - pass - - def test_get_user(self): - """Test case for get_user - - Get a user # noqa: E501 - """ - pass - - def test_get_users(self): - """Test case for get_users - - Get multiple users # noqa: E501 - """ - pass - - def test_get_users_for_team(self): - """Test case for get_users_for_team - - Get users in a team # noqa: E501 - """ - pass - - def test_get_users_for_workspace(self): - """Test case for get_users_for_workspace - - Get users in a workspace or organization # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_webhook_compact.py b/test/test_webhook_compact.py deleted file mode 100644 index 1246e52d..00000000 --- a/test/test_webhook_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.webhook_compact import WebhookCompact # noqa: E501 -from asana.rest import ApiException - - -class TestWebhookCompact(unittest.TestCase): - """WebhookCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWebhookCompact(self): - """Test WebhookCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.webhook_compact.WebhookCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_webhook_compact_resource.py b/test/test_webhook_compact_resource.py deleted file mode 100644 index 67fe2c21..00000000 --- a/test/test_webhook_compact_resource.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.webhook_compact_resource import WebhookCompactResource # noqa: E501 -from asana.rest import ApiException - - -class TestWebhookCompactResource(unittest.TestCase): - """WebhookCompactResource unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWebhookCompactResource(self): - """Test WebhookCompactResource""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.webhook_compact_resource.WebhookCompactResource() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_webhook_filter.py b/test/test_webhook_filter.py deleted file mode 100644 index e3e98a22..00000000 --- a/test/test_webhook_filter.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.webhook_filter import WebhookFilter # noqa: E501 -from asana.rest import ApiException - - -class TestWebhookFilter(unittest.TestCase): - """WebhookFilter unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWebhookFilter(self): - """Test WebhookFilter""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.webhook_filter.WebhookFilter() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_webhook_request.py b/test/test_webhook_request.py deleted file mode 100644 index 599e36d5..00000000 --- a/test/test_webhook_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.webhook_request import WebhookRequest # noqa: E501 -from asana.rest import ApiException - - -class TestWebhookRequest(unittest.TestCase): - """WebhookRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWebhookRequest(self): - """Test WebhookRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.webhook_request.WebhookRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_webhook_request_filters.py b/test/test_webhook_request_filters.py deleted file mode 100644 index 5d800967..00000000 --- a/test/test_webhook_request_filters.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.webhook_request_filters import WebhookRequestFilters # noqa: E501 -from asana.rest import ApiException - - -class TestWebhookRequestFilters(unittest.TestCase): - """WebhookRequestFilters unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWebhookRequestFilters(self): - """Test WebhookRequestFilters""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.webhook_request_filters.WebhookRequestFilters() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_webhook_response.py b/test/test_webhook_response.py deleted file mode 100644 index 71c3f748..00000000 --- a/test/test_webhook_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.webhook_response import WebhookResponse # noqa: E501 -from asana.rest import ApiException - - -class TestWebhookResponse(unittest.TestCase): - """WebhookResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWebhookResponse(self): - """Test WebhookResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.webhook_response.WebhookResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_webhook_response_array.py b/test/test_webhook_response_array.py deleted file mode 100644 index 7eacac9d..00000000 --- a/test/test_webhook_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.webhook_response_array import WebhookResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestWebhookResponseArray(unittest.TestCase): - """WebhookResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWebhookResponseArray(self): - """Test WebhookResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.webhook_response_array.WebhookResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_webhook_response_data.py b/test/test_webhook_response_data.py deleted file mode 100644 index b840733f..00000000 --- a/test/test_webhook_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.webhook_response_data import WebhookResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestWebhookResponseData(unittest.TestCase): - """WebhookResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWebhookResponseData(self): - """Test WebhookResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.webhook_response_data.WebhookResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_webhook_update_request.py b/test/test_webhook_update_request.py deleted file mode 100644 index e00e90cc..00000000 --- a/test/test_webhook_update_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.webhook_update_request import WebhookUpdateRequest # noqa: E501 -from asana.rest import ApiException - - -class TestWebhookUpdateRequest(unittest.TestCase): - """WebhookUpdateRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWebhookUpdateRequest(self): - """Test WebhookUpdateRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.webhook_update_request.WebhookUpdateRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_webhooks_api.py b/test/test_webhooks_api.py deleted file mode 100644 index 9816f96a..00000000 --- a/test/test_webhooks_api.py +++ /dev/null @@ -1,68 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.webhooks_api import WebhooksApi # noqa: E501 -from asana.rest import ApiException - - -class TestWebhooksApi(unittest.TestCase): - """WebhooksApi unit test stubs""" - - def setUp(self): - self.api = WebhooksApi() # noqa: E501 - - def tearDown(self): - pass - - def test_create_webhook(self): - """Test case for create_webhook - - Establish a webhook # noqa: E501 - """ - pass - - def test_delete_webhook(self): - """Test case for delete_webhook - - Delete a webhook # noqa: E501 - """ - pass - - def test_get_webhook(self): - """Test case for get_webhook - - Get a webhook # noqa: E501 - """ - pass - - def test_get_webhooks(self): - """Test case for get_webhooks - - Get multiple webhooks # noqa: E501 - """ - pass - - def test_update_webhook(self): - """Test case for update_webhook - - Update a webhook # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_webhooks_body.py b/test/test_webhooks_body.py deleted file mode 100644 index 912bfe76..00000000 --- a/test/test_webhooks_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.webhooks_body import WebhooksBody # noqa: E501 -from asana.rest import ApiException - - -class TestWebhooksBody(unittest.TestCase): - """WebhooksBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWebhooksBody(self): - """Test WebhooksBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.webhooks_body.WebhooksBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_webhooks_webhook_gid_body.py b/test/test_webhooks_webhook_gid_body.py deleted file mode 100644 index 03bafdd3..00000000 --- a/test/test_webhooks_webhook_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.webhooks_webhook_gid_body import WebhooksWebhookGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestWebhooksWebhookGidBody(unittest.TestCase): - """WebhooksWebhookGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWebhooksWebhookGidBody(self): - """Test WebhooksWebhookGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.webhooks_webhook_gid_body.WebhooksWebhookGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_add_user_request.py b/test/test_workspace_add_user_request.py deleted file mode 100644 index 40f0ef16..00000000 --- a/test/test_workspace_add_user_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_add_user_request import WorkspaceAddUserRequest # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceAddUserRequest(unittest.TestCase): - """WorkspaceAddUserRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceAddUserRequest(self): - """Test WorkspaceAddUserRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_add_user_request.WorkspaceAddUserRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_base.py b/test/test_workspace_base.py deleted file mode 100644 index d9dba153..00000000 --- a/test/test_workspace_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_base import WorkspaceBase # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceBase(unittest.TestCase): - """WorkspaceBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceBase(self): - """Test WorkspaceBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_base.WorkspaceBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_compact.py b/test/test_workspace_compact.py deleted file mode 100644 index c61d120f..00000000 --- a/test/test_workspace_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_compact import WorkspaceCompact # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceCompact(unittest.TestCase): - """WorkspaceCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceCompact(self): - """Test WorkspaceCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_compact.WorkspaceCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_gid_add_user_body.py b/test/test_workspace_gid_add_user_body.py deleted file mode 100644 index 5b3ad3c4..00000000 --- a/test/test_workspace_gid_add_user_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_gid_add_user_body import WorkspaceGidAddUserBody # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceGidAddUserBody(unittest.TestCase): - """WorkspaceGidAddUserBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceGidAddUserBody(self): - """Test WorkspaceGidAddUserBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_gid_add_user_body.WorkspaceGidAddUserBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_gid_projects_body.py b/test/test_workspace_gid_projects_body.py deleted file mode 100644 index b73d4f10..00000000 --- a/test/test_workspace_gid_projects_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_gid_projects_body import WorkspaceGidProjectsBody # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceGidProjectsBody(unittest.TestCase): - """WorkspaceGidProjectsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceGidProjectsBody(self): - """Test WorkspaceGidProjectsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_gid_projects_body.WorkspaceGidProjectsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_gid_remove_user_body.py b/test/test_workspace_gid_remove_user_body.py deleted file mode 100644 index e4a71add..00000000 --- a/test/test_workspace_gid_remove_user_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_gid_remove_user_body import WorkspaceGidRemoveUserBody # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceGidRemoveUserBody(unittest.TestCase): - """WorkspaceGidRemoveUserBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceGidRemoveUserBody(self): - """Test WorkspaceGidRemoveUserBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_gid_remove_user_body.WorkspaceGidRemoveUserBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_gid_tags_body.py b/test/test_workspace_gid_tags_body.py deleted file mode 100644 index 4cc74b68..00000000 --- a/test/test_workspace_gid_tags_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_gid_tags_body import WorkspaceGidTagsBody # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceGidTagsBody(unittest.TestCase): - """WorkspaceGidTagsBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceGidTagsBody(self): - """Test WorkspaceGidTagsBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_gid_tags_body.WorkspaceGidTagsBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_membership_base.py b/test/test_workspace_membership_base.py deleted file mode 100644 index 96a4feb6..00000000 --- a/test/test_workspace_membership_base.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_membership_base import WorkspaceMembershipBase # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceMembershipBase(unittest.TestCase): - """WorkspaceMembershipBase unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceMembershipBase(self): - """Test WorkspaceMembershipBase""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_membership_base.WorkspaceMembershipBase() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_membership_compact.py b/test/test_workspace_membership_compact.py deleted file mode 100644 index 1f6676de..00000000 --- a/test/test_workspace_membership_compact.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_membership_compact import WorkspaceMembershipCompact # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceMembershipCompact(unittest.TestCase): - """WorkspaceMembershipCompact unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceMembershipCompact(self): - """Test WorkspaceMembershipCompact""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_membership_compact.WorkspaceMembershipCompact() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_membership_request.py b/test/test_workspace_membership_request.py deleted file mode 100644 index aa462c5c..00000000 --- a/test/test_workspace_membership_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_membership_request import WorkspaceMembershipRequest # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceMembershipRequest(unittest.TestCase): - """WorkspaceMembershipRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceMembershipRequest(self): - """Test WorkspaceMembershipRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_membership_request.WorkspaceMembershipRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_membership_response.py b/test/test_workspace_membership_response.py deleted file mode 100644 index 3ec481ea..00000000 --- a/test/test_workspace_membership_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_membership_response import WorkspaceMembershipResponse # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceMembershipResponse(unittest.TestCase): - """WorkspaceMembershipResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceMembershipResponse(self): - """Test WorkspaceMembershipResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_membership_response.WorkspaceMembershipResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_membership_response_array.py b/test/test_workspace_membership_response_array.py deleted file mode 100644 index 9d32867a..00000000 --- a/test/test_workspace_membership_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_membership_response_array import WorkspaceMembershipResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceMembershipResponseArray(unittest.TestCase): - """WorkspaceMembershipResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceMembershipResponseArray(self): - """Test WorkspaceMembershipResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_membership_response_array.WorkspaceMembershipResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_membership_response_data.py b/test/test_workspace_membership_response_data.py deleted file mode 100644 index c792885e..00000000 --- a/test/test_workspace_membership_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_membership_response_data import WorkspaceMembershipResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceMembershipResponseData(unittest.TestCase): - """WorkspaceMembershipResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceMembershipResponseData(self): - """Test WorkspaceMembershipResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_membership_response_data.WorkspaceMembershipResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_membership_response_user_task_list.py b/test/test_workspace_membership_response_user_task_list.py deleted file mode 100644 index 599e2bfb..00000000 --- a/test/test_workspace_membership_response_user_task_list.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_membership_response_user_task_list import WorkspaceMembershipResponseUserTaskList # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceMembershipResponseUserTaskList(unittest.TestCase): - """WorkspaceMembershipResponseUserTaskList unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceMembershipResponseUserTaskList(self): - """Test WorkspaceMembershipResponseUserTaskList""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_membership_response_user_task_list.WorkspaceMembershipResponseUserTaskList() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_membership_response_vacation_dates.py b/test/test_workspace_membership_response_vacation_dates.py deleted file mode 100644 index d5dc1e45..00000000 --- a/test/test_workspace_membership_response_vacation_dates.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_membership_response_vacation_dates import WorkspaceMembershipResponseVacationDates # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceMembershipResponseVacationDates(unittest.TestCase): - """WorkspaceMembershipResponseVacationDates unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceMembershipResponseVacationDates(self): - """Test WorkspaceMembershipResponseVacationDates""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_membership_response_vacation_dates.WorkspaceMembershipResponseVacationDates() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_memberships_api.py b/test/test_workspace_memberships_api.py deleted file mode 100644 index 3d78d88b..00000000 --- a/test/test_workspace_memberships_api.py +++ /dev/null @@ -1,54 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.workspace_memberships_api import WorkspaceMembershipsApi # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceMembershipsApi(unittest.TestCase): - """WorkspaceMembershipsApi unit test stubs""" - - def setUp(self): - self.api = WorkspaceMembershipsApi() # noqa: E501 - - def tearDown(self): - pass - - def test_get_workspace_membership(self): - """Test case for get_workspace_membership - - Get a workspace membership # noqa: E501 - """ - pass - - def test_get_workspace_memberships_for_user(self): - """Test case for get_workspace_memberships_for_user - - Get workspace memberships for a user # noqa: E501 - """ - pass - - def test_get_workspace_memberships_for_workspace(self): - """Test case for get_workspace_memberships_for_workspace - - Get the workspace memberships for a workspace # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_remove_user_request.py b/test/test_workspace_remove_user_request.py deleted file mode 100644 index e5acbe1d..00000000 --- a/test/test_workspace_remove_user_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_remove_user_request import WorkspaceRemoveUserRequest # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceRemoveUserRequest(unittest.TestCase): - """WorkspaceRemoveUserRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceRemoveUserRequest(self): - """Test WorkspaceRemoveUserRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_remove_user_request.WorkspaceRemoveUserRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_request.py b/test/test_workspace_request.py deleted file mode 100644 index 7b46a24c..00000000 --- a/test/test_workspace_request.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_request import WorkspaceRequest # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceRequest(unittest.TestCase): - """WorkspaceRequest unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceRequest(self): - """Test WorkspaceRequest""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_request.WorkspaceRequest() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_response.py b/test/test_workspace_response.py deleted file mode 100644 index c26fad4a..00000000 --- a/test/test_workspace_response.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_response import WorkspaceResponse # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceResponse(unittest.TestCase): - """WorkspaceResponse unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceResponse(self): - """Test WorkspaceResponse""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_response.WorkspaceResponse() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_response_array.py b/test/test_workspace_response_array.py deleted file mode 100644 index 9589f988..00000000 --- a/test/test_workspace_response_array.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_response_array import WorkspaceResponseArray # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceResponseArray(unittest.TestCase): - """WorkspaceResponseArray unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceResponseArray(self): - """Test WorkspaceResponseArray""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_response_array.WorkspaceResponseArray() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspace_response_data.py b/test/test_workspace_response_data.py deleted file mode 100644 index 026eb8f4..00000000 --- a/test/test_workspace_response_data.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspace_response_data import WorkspaceResponseData # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspaceResponseData(unittest.TestCase): - """WorkspaceResponseData unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspaceResponseData(self): - """Test WorkspaceResponseData""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspace_response_data.WorkspaceResponseData() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspaces_api.py b/test/test_workspaces_api.py deleted file mode 100644 index 68447122..00000000 --- a/test/test_workspaces_api.py +++ /dev/null @@ -1,68 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.api.workspaces_api import WorkspacesApi # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspacesApi(unittest.TestCase): - """WorkspacesApi unit test stubs""" - - def setUp(self): - self.api = WorkspacesApi() # noqa: E501 - - def tearDown(self): - pass - - def test_add_user_for_workspace(self): - """Test case for add_user_for_workspace - - Add a user to a workspace or organization # noqa: E501 - """ - pass - - def test_get_workspace(self): - """Test case for get_workspace - - Get a workspace # noqa: E501 - """ - pass - - def test_get_workspaces(self): - """Test case for get_workspaces - - Get multiple workspaces # noqa: E501 - """ - pass - - def test_remove_user_for_workspace(self): - """Test case for remove_user_for_workspace - - Remove a user from a workspace or organization # noqa: E501 - """ - pass - - def test_update_workspace(self): - """Test case for update_workspace - - Update a workspace # noqa: E501 - """ - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/test/test_workspaces_workspace_gid_body.py b/test/test_workspaces_workspace_gid_body.py deleted file mode 100644 index 726566bc..00000000 --- a/test/test_workspaces_workspace_gid_body.py +++ /dev/null @@ -1,39 +0,0 @@ -# coding: utf-8 - -""" - Asana - - This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml). # noqa: E501 - - OpenAPI spec version: 1.0 - - Generated by: https://github.com/swagger-api/swagger-codegen.git -""" - -from __future__ import absolute_import - -import unittest - -import asana -from asana.models.workspaces_workspace_gid_body import WorkspacesWorkspaceGidBody # noqa: E501 -from asana.rest import ApiException - - -class TestWorkspacesWorkspaceGidBody(unittest.TestCase): - """WorkspacesWorkspaceGidBody unit test stubs""" - - def setUp(self): - pass - - def tearDown(self): - pass - - def testWorkspacesWorkspaceGidBody(self): - """Test WorkspacesWorkspaceGidBody""" - # FIXME: construct object with mandatory attributes with example values - # model = asana.models.workspaces_workspace_gid_body.WorkspacesWorkspaceGidBody() # noqa: E501 - pass - - -if __name__ == '__main__': - unittest.main() diff --git a/tests/__init__.py b/tests/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/tests/helpers.py b/tests/helpers.py new file mode 100644 index 00000000..5167c04b --- /dev/null +++ b/tests/helpers.py @@ -0,0 +1,40 @@ +import json +import unittest + +import asana +import requests +import responses +from responses import GET, PUT, POST, DELETE + +# Define JSON primitives so we can just copy in JSON: +false = False +true = True +null = None + + +def create_decorating_metaclass(decorators, prefix='test_'): + class DecoratingMethodsMetaclass(type): + def __new__(cls, name, bases, namespace): + namespace_items = tuple(namespace.items()) + for key, val in namespace_items: + if key.startswith(prefix) and callable(val): + for dec in decorators: + val = dec(val) + namespace[key] = val + return type.__new__(cls, name, bases, dict(namespace)) + + return DecoratingMethodsMetaclass + + +# TestCase subclass that automatically decorates test methods with +# responses.activate and sets up a client instance +class ClientTestCase(unittest.TestCase, metaclass=create_decorating_metaclass((responses.activate,))): + + def setUp(self): + self.client = asana.Client( + base_url='http://app', + # no delay when polling to speed up tests + poll_interval=0, + # disable iterator and limit to match existing tests for now + iterator_type=None, + ) diff --git a/tests/test_client.py b/tests/test_client.py new file mode 100644 index 00000000..9dd1c62f --- /dev/null +++ b/tests/test_client.py @@ -0,0 +1,407 @@ +import warnings +try: + from mock import patch, call +except ImportError: + from unittest.mock import patch, call + +from .helpers import * + +class TestClient(ClientTestCase): + + def test_version_values(self): + values = self.client._version_values() + self.assertEqual('Python', values['language']) + self.assertRegex(values['version'], r'[0-9]+[.][0-9]+[.][0-9]+') + self.assertSetEqual( + {'language', 'version', 'language_version', 'os', 'os_version'}, + set(values.keys())) + + def test_version_header(self): + self.assertRegex( + self.client._version_header(), r'language=Python') + + def test_default_headers(self): + self.client.headers['key'] = 'value' + responses.add(GET, 'http://app/users/me', status=200, body='{"data":{}}') + self.client.users.get_user('me') + self.assertLessEqual( + set({'key': 'value'}.items()), + set(responses.calls[0].request.headers.items()) + ) + + def test_request_headers(self): + responses.add(GET, 'http://app/users/me', status=200, body='{"data":{}}') + self.client.users.get_user('me', headers={'key': 'value'}) + self.assertLessEqual( + set({'key': 'value'}.items()), + set(responses.calls[0].request.headers.items()) + ) + + def test_overriding_headers(self): + self.client.headers['key'] = 'value' + self.client.headers['key2'] = 'value2' + responses.add(GET, 'http://app/users/me', status=200, body='{"data":{}}') + self.client.users.get_user('me', headers={'key2': 'value3'}) + self.assertLessEqual( + set({'key': 'value', 'key2': 'value3'}.items()), + set(responses.calls[0].request.headers.items()) + ) + + def test_content_type_headers(self): + self.client.headers['key'] = 'value' + responses.add(POST, 'http://app/tasks/123/addProject', status=200, + body='{"data":{}}') + self.client.tasks.add_project(123, project=456, headers={'key2': 'value2'}) + self.assertLessEqual( + set({'content-type': 'application/json'}.items()), + set(responses.calls[0].request.headers.items()) + ) + + def test_users_me_not_authorized(self): + res = { + "errors": [ + { "message": "Not Authorized" } + ] + } + responses.add(GET, 'http://app/users/me', status=401, body=json.dumps(res), match_querystring=True) + self.assertRaises(asana.error.NoAuthorizationError, self.client.users.get_user, 'me') + + def test_tasks_get_tasks_invalid_request(self): + res = { + "errors": [ + { "message": "workspace: Missing input" } + ] + } + responses.add(GET, 'http://app/tasks', status=400, body=json.dumps(res), match_querystring=True) + self.assertRaises(asana.error.InvalidRequestError, self.client.tasks.get_tasks) + + def test_users_me_server_error(self): + res = { + "errors": [ + { + "message": "Server Error", + "phrase": "6 sad squid snuggle softly" + } + ] + } + responses.add(GET, 'http://app/users/me', status=500, body=json.dumps(res), match_querystring=True) + self.assertRaises(asana.error.ServerError, self.client.users.get_user, 'me', max_retries=0) + + def test_users_me_unfriendly_server_error(self): + res = "Crappy Response" + responses.add(GET, 'http://app/users/me', status=504, body=res, match_querystring=True) + self.assertRaises(asana.error.ServerError, self.client.users.get_user, 'me', max_retries=0) + + def test_users_get_user_not_found(self): + res = { + "errors": [ + { "message": "user: Unknown object: 1234124312341" } + ] + } + responses.add(GET, 'http://app/users/1234', status=404, body=json.dumps(res), match_querystring=True) + self.assertRaises(asana.error.NotFoundError, self.client.users.get_user, ('1234')) + + def test_users_get_user_forbidden(self): + res = { + "errors": [ + { "message": "user: Forbidden" } + ] + } + responses.add(GET, 'http://app/users/1234', status=403, body=json.dumps(res), match_querystring=True) + self.assertRaises(asana.error.ForbiddenError, self.client.users.get_user, ('1234')) + + def test_option_pretty(self): + res = { + "data": { "email": "sanchez@...", "id": 999, "name": "Greg Sanchez" } + } + responses.add(GET, 'http://app/users/me?opt_pretty=true', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.users.get_user('me', pretty=True), res['data']) + + def test_option_fields(self): + res = { + "data": { "name": "Make a list", "notes": "Check it twice!", "id": 1224 } + } + responses.add(GET, 'http://app/tasks/1224?opt_fields=name%2Cnotes', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.get_task('1224', fields=['name','notes']), res['data']) + + def test_option_expand(self): + req = { + 'data': { 'assignee': 1234 }, + 'options': { 'expand' : ['projects'] } + } + res = { + "data": { + "id": 1001, + "projects": [ + { + "archived": false, + "created_at": "", + "followers": [], + "modified_at": "", + "notes": "", + "id": 1331, + "name": "Things to buy" + } + ] + # ... + } + } + responses.add(PUT, 'http://app/tasks/1001', status=200, body=json.dumps(res), match_querystring=True) + # -d "assignee=1234" \ + # -d "options.expand=%2Aprojects%2A" + self.assertEqual(self.client.tasks.update_task('1001', req['data'], expand=['projects']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_pagination(self): + res = { + "data": [ + { "id": 1000, "name": "Task 1" } + ], + "next_page": { + "offset": "yJ0eXAiOiJKV1QiLCJhbGciOiJIRzI1NiJ9", + "path": "/tasks?project=1337&limit=5&offset=yJ0eXAiOiJKV1QiLCJhbGciOiJIRzI1NiJ9", + "uri": "https://app.asana.com/api/1.0/tasks?project=1337&limit=5&offset=yJ0eXAiOiJKV1QiLCJhbGciOiJIRzI1NiJ9" + } + } + responses.add(GET, 'http://app/projects/1337/tasks?limit=5&offset=eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9', status=200, body=json.dumps(res), match_querystring=True) + + self.assertEqual(self.client.tasks.get_tasks_for_project('1337', { 'limit': 5, 'offset': 'eyJ0eXAiOJiKV1iQLCJhbGciOiJIUzI1NiJ9'}), res['data']) + + @unittest.skip("iterator_type='pages' disabled") + def test_page_iterator_item_limit_lt_items(self): + responses.add(GET, 'http://app/projects/1337/tasks?limit=2', status=200, body=json.dumps({ 'data': ['a', 'b'], 'next_page': { 'offset': 'a', 'path': '/projects/1337/tasks?limit=2&offset=a' } }), match_querystring=True) + responses.add(GET, 'http://app/projects/1337/tasks?limit=2&offset=a', status=200, body=json.dumps({ 'data': ['c'], 'next_page': null }), match_querystring=True) + + iterator = self.client.tasks.get_tasks_for_project('1337', item_limit=2, page_size=2, iterator_type='pages') + self.assertEqual(next(iterator), ['a', 'b']) + self.assertRaises(StopIteration, next, (iterator)) + + @unittest.skip("iterator_type='pages' disabled") + def test_page_iterator_item_limit_eq_items(self): + responses.add(GET, 'http://app/projects/1337/tasks?limit=2', status=200, body=json.dumps({ 'data': ['a', 'b'], 'next_page': { 'offset': 'a', 'path': '/projects/1337/tasks?limit=2&offset=a' } }), match_querystring=True) + responses.add(GET, 'http://app/projects/1337/tasks?limit=1&offset=a', status=200, body=json.dumps({ 'data': ['c'], 'next_page': null }), match_querystring=True) + + iterator = self.client.tasks.get_tasks_for_project('1337', item_limit=3, page_size=2, iterator_type='pages') + self.assertEqual(next(iterator), ['a', 'b']) + self.assertEqual(next(iterator), ['c']) + self.assertRaises(StopIteration, next, (iterator)) + + @unittest.skip("iterator_type='pages' disabled") + def test_page_iterator_item_limit_gt_items(self): + responses.add(GET, 'http://app/projects/1337/tasks?limit=2', status=200, body=json.dumps({ 'data': ['a', 'b'], 'next_page': { 'offset': 'a', 'path': '/projects/1337/tasks?limit=2&offset=a' } }), match_querystring=True) + responses.add(GET, 'http://app/projects/1337/tasks?limit=2&offset=a', status=200, body=json.dumps({ 'data': ['c'], 'next_page': null }), match_querystring=True) + + iterator = self.client.tasks.get_tasks_for_project('1337', item_limit=4, page_size=2, iterator_type='pages') + self.assertEqual(next(iterator), ['a', 'b']) + self.assertEqual(next(iterator), ['c']) + self.assertRaises(StopIteration, next, (iterator)) + + def test_item_iterator_item_limit_lt_items(self): + responses.add(GET, 'http://app/projects/1337/tasks?limit=2', status=200, body=json.dumps({ 'data': ['a', 'b'], 'next_page': { 'offset': 'a', 'path': '/projects/1337/tasks?limit=2&offset=a' } }), match_querystring=True) + + iterator = self.client.tasks.get_tasks_for_project('1337', item_limit=2, page_size=2, iterator_type='items') + self.assertEqual(next(iterator), 'a') + self.assertEqual(next(iterator), 'b') + self.assertRaises(StopIteration, next, (iterator)) + + def test_item_iterator_item_limit_eq_items(self): + responses.add(GET, 'http://app/projects/1337/tasks?limit=2', status=200, body=json.dumps({ 'data': ['a', 'b'], 'next_page': { 'offset': 'a', 'path': '/projects/1337/tasks?limit=2&offset=a' } }), match_querystring=True) + responses.add(GET, 'http://app/projects/1337/tasks?limit=1&offset=a', status=200, body=json.dumps({ 'data': ['c'], 'next_page': null }), match_querystring=True) + + iterator = self.client.tasks.get_tasks_for_project('1337', item_limit=3, page_size=2, iterator_type='items') + self.assertEqual(next(iterator), 'a') + self.assertEqual(next(iterator), 'b') + self.assertEqual(next(iterator), 'c') + self.assertRaises(StopIteration, next, (iterator)) + + def test_item_iterator_item_limit_gt_items(self): + responses.add(GET, 'http://app/projects/1337/tasks?limit=2', status=200, body=json.dumps({ 'data': ['a', 'b'], 'next_page': { 'offset': 'a', 'path': '/projects/1337/tasks?limit=2&offset=a' } }), match_querystring=True) + responses.add(GET, 'http://app/projects/1337/tasks?limit=2&offset=a', status=200, body=json.dumps({ 'data': ['c'], 'next_page': null }), match_querystring=True) + + iterator = self.client.tasks.get_tasks_for_project('1337', item_limit=4, page_size=2, iterator_type='items') + self.assertEqual(next(iterator), 'a') + self.assertEqual(next(iterator), 'b') + self.assertEqual(next(iterator), 'c') + self.assertRaises(StopIteration, next, (iterator)) + + def test_item_iterator_preserve_opt_fields(self): + responses.add(GET, 'http://app/projects/1337/tasks?limit=2&opt_fields=foo', status=200, body=json.dumps({ 'data': ['a', 'b'], 'next_page': { 'offset': 'a', 'path': '/projects/1337/tasks?limit=2&offset=a' } }), match_querystring=True) + responses.add(GET, 'http://app/projects/1337/tasks?limit=1&opt_fields=foo&offset=a', status=200, body=json.dumps({ 'data': ['c'], 'next_page': null }), match_querystring=True) + + iterator = self.client.tasks.get_tasks_for_project('1337', item_limit=3, page_size=2, fields=['foo'], iterator_type='items') + self.assertEqual(next(iterator), 'a') + self.assertEqual(next(iterator), 'b') + self.assertEqual(next(iterator), 'c') + self.assertRaises(StopIteration, next, (iterator)) + + @patch('time.sleep') + def test_rate_limiting(self, time_sleep): + res = [ + (429, { 'Retry-After': '10' }, '{}'), + (200, {}, json.dumps({ 'data': 'me' })) + ] + responses.add_callback(responses.GET, 'http://app/users/me', callback=lambda r: res.pop(0), content_type='application/json') + + self.assertEqual(self.client.users.get_user('me'), 'me') + self.assertEqual(len(responses.calls), 2) + self.assertEqual(time_sleep.mock_calls, [call(10.0)]) + + @patch('time.sleep') + def test_rate_limited_twice(self, time_sleep): + res = [ + (429, { 'Retry-After': '10' }, '{}'), + (429, { 'Retry-After': '1' }, '{}'), + (200, {}, json.dumps({ 'data': 'me' })) + ] + responses.add_callback(responses.GET, 'http://app/users/me', callback=lambda r: res.pop(0), content_type='application/json') + + self.assertEqual(self.client.users.get_user('me'), 'me') + self.assertEqual(len(responses.calls), 3) + self.assertEqual(time_sleep.mock_calls, [call(10.0), call(1.0)]) + + @patch('time.sleep') + def test_server_error_retry(self, time_sleep): + res = [ + (500, {}, '{}'), + (500, {}, '{}'), + (500, {}, '{}'), + (200, {}, json.dumps({ 'data': 'me' })) + ] + responses.add_callback(responses.GET, 'http://app/users/me', callback=lambda r: res.pop(0), content_type='application/json') + + self.assertRaises(asana.error.ServerError, self.client.users.get_user, 'me', max_retries=2) + self.assertEqual(time_sleep.mock_calls, [call(1.0), call(2.0)]) + + @patch('time.sleep') + def test_server_error_retry_backoff(self, time_sleep): + res = [ + (500, {}, '{}'), + (500, {}, '{}'), + (500, {}, '{}'), + (200, {}, json.dumps({ 'data': 'me' })) + ] + responses.add_callback(responses.GET, 'http://app/users/me', callback=lambda r: res.pop(0), content_type='application/json') + + self.assertEqual(self.client.users.get_user('me'), 'me') + self.assertEqual(time_sleep.mock_calls, [call(1.0), call(2.0), call(4.0)]) + + + def test_get_named_parameters(self): + responses.add(GET, 'http://app/tasks?workspace=14916&assignee=me', status=200, body=json.dumps({ 'data': 'dummy data' }), match_querystring=True) + + self.assertEqual(self.client.tasks.get_tasks(workspace=14916, assignee="me"), 'dummy data') + + def test_post_named_parameters(self): + responses.add(POST, 'http://app/tasks', status=201, body='{ "data": "dummy data" }', match_querystring=True) + + self.assertEqual(self.client.tasks.create_task(assignee=1235, followers=[5678], name="Hello, world."), 'dummy data') + self.assertEqual(json.loads(responses.calls[0].request.body), { + "data": { + "assignee": 1235, + "followers": [5678], + "name": "Hello, world." + } + }) + + def test_put_named_parameters(self): + responses.add(PUT, 'http://app/tasks/1001', status=200, body='{ "data": "dummy data" }', match_querystring=True) + + self.assertEqual(self.client.tasks.update_task('1001', assignee=1235, followers=[5678], name="Hello, world."), 'dummy data') + self.assertEqual(json.loads(responses.calls[0].request.body), { + "data": { + "assignee": 1235, + "followers": [5678], + "name": "Hello, world." + } + }) + + def test_asana_change_header_logging(self): + with warnings.catch_warnings(record=True) as w: + warnings.simplefilter("always") + + requestHeaders = {} + responseHeaders = { + 'asana-change': 'name=string_ids;info=something;affected=true' + } + self.client._log_asana_change_header(requestHeaders, responseHeaders) + + assert len(w) == 1 + + def test_asana_change_header_logging_turned_off(self): + with warnings.catch_warnings(record=True) as w: + warnings.simplefilter("always") + + requestHeaders = {} + responseHeaders = { + 'asana-change': 'name=string_ids;info=something;affected=true' + } + self.client.LOG_ASANA_CHANGE_WARNINGS = false + self.client._log_asana_change_header(requestHeaders, responseHeaders) + + assert len(w) == 0 + + def test_asana_change_header_ignore_case(self): + with warnings.catch_warnings(record=True) as w: + warnings.simplefilter("always") + + requestHeaders = {} + responseHeaders = { + 'asANa-chANge': 'name=string_ids;info=something;affected=true' + } + self.client._log_asana_change_header(requestHeaders, responseHeaders) + + assert len(w) == 1 + + def test_asana_change_header_enable(self): + with warnings.catch_warnings(record=True) as w: + warnings.simplefilter("always") + + requestHeaders = { + 'asana-enable': 'string_ids' + } + responseHeaders = { + 'asana-change': 'name=string_ids;info=something;affected=true' + } + self.client._log_asana_change_header(requestHeaders, responseHeaders) + + assert len(w) == 0 + + def test_asana_change_header_disable(self): + with warnings.catch_warnings(record=True) as w: + warnings.simplefilter("always") + + requestHeaders = { + 'asana-disable': 'string_ids' + } + responseHeaders = { + 'asana-change': 'name=string_ids;info=something;affected=true' + } + self.client._log_asana_change_header(requestHeaders, responseHeaders) + + assert len(w) == 0 + + def test_asana_change_header_multiple(self): + with warnings.catch_warnings(record=True) as w: + warnings.simplefilter("always") + + requestHeaders = {} + responseHeaders = { + 'asana-change': 'name=string_ids;info=something;affected=true,name=new_sections;info=something;affected=true' + } + self.client._log_asana_change_header(requestHeaders, responseHeaders) + + assert len(w) == 2 + + def test_asana_change_header_multiple_disable(self): + with warnings.catch_warnings(record=True) as w: + warnings.simplefilter("always") + + requestHeaders = { + 'asana-disable': 'string_ids,new_sections' + } + responseHeaders = { + 'asana-change': 'name=string_ids;info=something;affected=true,name=new_sections;info=something;affected=true' + } + self.client._log_asana_change_header(requestHeaders, responseHeaders) + + assert len(w) == 0 diff --git a/tests/test_client_attachments.py b/tests/test_client_attachments.py new file mode 100644 index 00000000..6affeb81 --- /dev/null +++ b/tests/test_client_attachments.py @@ -0,0 +1,46 @@ +import io +import cgi + +from .helpers import * + + +class TestClientAttachments(ClientTestCase): + + def test_attachments_get_attachment(self): + res = { + "data": { + "created_at": "", + "download_url": "https://www.dropbox.com/s/1234567890abcdef/Screenshot.png?dl=1", + "host": "dropbox", + "id": 5678, + "name": "Screenshot.png", + "parent": { "id": 1337, "name": "My Task" }, + "view_url": "https://www.dropbox.com/s/1234567890abcdef/Screenshot.png" + } + } + responses.add(GET, 'http://app/attachments/5678', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.attachments.get_attachment('5678'), res['data']) + + def test_attachments_find_by_task(self): + res = { + "data": [ + { "id": 5678, "name": "Background.png" }, + { "id": 9012, "name": "New Design Draft.pdf" } + ] + } + responses.add(GET, 'http://app/tasks/1234/attachments', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.attachments.find_by_task('1234'), res['data']) + + def test_attachments_create_on_task(self): + res = { "data": { "id": 5678, "name": "file.txt" } } + responses.add(POST, 'http://app/tasks/1337/attachments', status=200, body=json.dumps(res), match_querystring=True) + + self.assertEqual(self.client.attachments.create_on_task('1337', 'file content', 'file name', 'file content-type'), res['data']) + + request_content_type, pdict = cgi.parse_header(responses.calls[0].request.headers['Content-Type']) + self.assertEqual(request_content_type, 'multipart/form-data') + + content_file = io.BytesIO(responses.calls[0].request.body) + multipart = cgi.parse_multipart(content_file, { 'boundary': bytes(pdict['boundary'], "UTF-8") }) + self.assertEqual(multipart['file'][0], bytes('file content', 'UTF-8')) + # TODO: verify filename and content-type, possibly using a different multipart decoder diff --git a/tests/test_client_audit_log_api.py b/tests/test_client_audit_log_api.py new file mode 100644 index 00000000..ca0dc9fe --- /dev/null +++ b/tests/test_client_audit_log_api.py @@ -0,0 +1,152 @@ +from .helpers import * + + +class TestClientAuditLogAPI(ClientTestCase): + + def test_get_audit_log_events(self): + res = { + "data": [ + { + "actor": { + "actor_type": "user", + "email": "gregsanchez@example.com", + "gid": "1111", + "name": "Greg Sanchez" + }, + "context": { + "api_authentication_method": "cookie", + "client_ip_address": "1.1.1.1", + "context_type": "web", + "oauth_app_name": "string", + "user_agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.103 Safari/537.36" + }, + "created_at": "2021-01-01T00:00:00.000Z", + "details": {}, + "event_category": "deletion", + "event_type": "task_deleted", + "gid": "12345", + "resource": { + "email": "string", + "gid": "1111", + "name": "Example Task", + "resource_subtype": "milestone", + "resource_type": "task" + } + } + ], + "next_page": { + "offset": "a", + "path": "/workspaces/1337/audit_log_events?offset=a", + "uri": "https://app.asana.com/api/1.0/workspaces/1337/audit_log_events?offset=a" + } + } + responses.add(GET, 'http://app/workspaces/1337/audit_log_events?', + status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual( + self.client.audit_log_api.get_audit_log_events("1337"), res['data']) + + def test_get_audit_log_events_iterator(self): + res1 = { + "data": [ + { + "actor": { + "actor_type": "user", + "email": "gregsanchez@example.com", + "gid": "1111", + "name": "Greg Sanchez" + }, + "context": { + "api_authentication_method": "cookie", + "client_ip_address": "1.1.1.1", + "context_type": "web", + "oauth_app_name": "string", + "user_agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.103 Safari/537.36" + }, + "created_at": "2021-01-01T00:00:00.000Z", + "details": {}, + "event_category": "deletion", + "event_type": "task_deleted", + "gid": "12345", + "resource": { + "email": "string", + "gid": "1111", + "name": "Example Task", + "resource_subtype": "milestone", + "resource_type": "task" + } + } + ], + "next_page": { + "offset": "a", + "path": "/workspaces/1337/audit_log_events?limit=1&offset=a", + "uri": "https://app.asana.com/api/1.0/workspaces/1337/audit_log_events?limit=1&offset=a" + } + } + res2 = { + "data": [ + { + "actor": { + "actor_type": "user", + "email": "tbizarro@example.com", + "gid": "1234", + "name": "Tim Bizarro" + }, + "context": { + "api_authentication_method": "cookie", + "client_ip_address": "1.1.1.1", + "context_type": "web", + "oauth_app_name": "string", + "user_agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.103 Safari/537.36" + }, + "created_at": "2021-01-01T00:00:00.000Z", + "details": {}, + "event_category": "deletion", + "event_type": "task_deleted", + "gid": "12345", + "resource": { + "email": "string", + "gid": "1111", + "name": "Example Task", + "resource_subtype": "milestone", + "resource_type": "task" + } + } + ], + "next_page": { + "offset": "b", + "path": "/workspaces/1337/audit_log_events?limit=1&offset=b", + "uri": "https://app.asana.com/api/1.0/workspaces/1337/audit_log_events?limit=1&offset=b" + } + } + res3 = { + "data": [], + "next_page": { + "offset": "c", + "path": "/workspaces/1337/audit_log_events?limit=1&offset=c", + "uri": "https://app.asana.com/api/1.0/workspaces/1337/audit_log_events?limit=1&offset=c" + } + } + res4 = { + "data": [], + "next_page": { + "offset": "d", + "path": "/workspaces/1337/audit_log_events?limit=1&offset=d", + "uri": "https://app.asana.com/api/1.0/workspaces/1337/audit_log_events?limit=1&offset=d" + } + } + responses.add(GET, 'http://app/workspaces/1337/audit_log_events?limit=1', + status=200, body=json.dumps(res1), match_querystring=True) + responses.add(GET, 'http://app/workspaces/1337/audit_log_events?limit=1&offset=a', + status=200, body=json.dumps(res2), match_querystring=True) + responses.add(GET, 'http://app/workspaces/1337/audit_log_events?limit=1&offset=b', + status=200, body=json.dumps(res3), match_querystring=True) + responses.add(GET, 'http://app/workspaces/1337/audit_log_events?limit=1&offset=c', + status=200, body=json.dumps(res4), match_querystring=True) + # Set iterator_type to 'items' to return an iterator + iterator = self.client.audit_log_api.get_audit_log_events( + "1337", page_size=1, iterator_type='items' + ) + # Iterator should stop on third call + self.assertEqual(next(iterator), res1['data'][0]) + self.assertEqual(next(iterator), res2['data'][0]) + self.assertRaises(StopIteration, next, (iterator)) diff --git a/tests/test_client_custom_field_settings.py b/tests/test_client_custom_field_settings.py new file mode 100644 index 00000000..506ccc2b --- /dev/null +++ b/tests/test_client_custom_field_settings.py @@ -0,0 +1,43 @@ +from .helpers import * + +class TestClientCustomFieldSettings(ClientTestCase): + def test_custom_field_settings_get_custom_field_settings_for_project(self): + res = { + "data": [ + { + "id": 258147, + "custom_field": [ + { + "id": 124578, + "name": "Priority", + "type": "enum" + } + ], + "project": [ + { + "id": 1331, + "name": "Things to buy" + } + ] + }, + { + "id": 369852, + "custom_field": [ + { + "id": 235689, + "name": "Cost", + "type": "enum" + } + ], + "project": [ + { + "id": 1331, + "name": "Things to buy" + } + ] + }, + ] + } + responses.add(GET, 'http://app/projects/1331/custom_field_settings', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.custom_field_settings.get_custom_field_settings_for_project('1331'), res['data']) + diff --git a/tests/test_client_custom_fields.py b/tests/test_client_custom_fields.py new file mode 100644 index 00000000..e7b0d0a8 --- /dev/null +++ b/tests/test_client_custom_fields.py @@ -0,0 +1,65 @@ +from .helpers import * + +class TestClientCustomFields(ClientTestCase): + def test_custom_fields_get_custom_field_text(self): + res = { + "data": [ + { + "id": 134679, + "created_at": "2016-07-11T14:29:23.249Z", + "name": "Owner", + "type": "text" + } + ] + } + responses.add(GET, 'http://app/custom_fields/134679', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.custom_fields.get_custom_field('134679'), res['data']) + + def test_custom_fields_get_custom_field_enum(self): + res = { + "data": [ + { + "id": 124578, + "created_at": "2016-07-11T14:29:23.249Z", + "name": "Priority", + "type": "enum", + "enum_options": [ + { + "id": 789, + "name": "Low", + "enabled": true, + "color": "blue" + }, + { + "id": 208, + "name": "Medium", + "enabled": false, + "color": "yellow" + }, + { + "id": 439, + "name": "High", + "enabled": true, + "color": "red" + } + ] + } + ] + } + responses.add(GET, 'http://app/custom_fields/124578', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.custom_fields.get_custom_field('124578'), res['data']) + + def test_custom_fields_get_custom_field_number(self): + res = { + "data": [ + { + "id": 938271, + "created_at": "2016-07-11T14:29:23.249Z", + "name": "Price", + "type": "number", + "precision": 2 + } + ] + } + responses.add(GET, 'http://app/custom_fields/938271', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.custom_fields.get_custom_field('938271'), res['data']) diff --git a/tests/test_client_events.py b/tests/test_client_events.py new file mode 100644 index 00000000..145a97d6 --- /dev/null +++ b/tests/test_client_events.py @@ -0,0 +1,78 @@ +from .helpers import * + +class TestClientEvents(ClientTestCase): + + def test_events_get(self): + res = { + "data": [ + { + "action": "changed", + "created_at": "2013-08-21T18:20:37.972Z", + "parent": null, + "resource": { "id": 1337, "name": "My Task" }, + "type": "task", + "user": { "id": 1123, "name": "Tom Bizarro" } + }, + { + "action": "changed", + "created_at": "2013-08-21T18:22:45.421Z", + "parent": null, + "resource": { "id": 1338, "name": "My Other Task" }, + "type": "task", + "user": { "id": 1428, "name": "Greg Sanchez" } + } + ], + "sync": "edfc0896b370b7a479886d316131bf5c:0" + } + responses.add(GET, 'http://app/events?resource=14321&sync=de4774f6915eae04714ca93bb2f5ee81%3A3', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.events.get({ 'resource': 14321, 'sync': 'de4774f6915eae04714ca93bb2f5ee81:3' }), res) + + def test_project_events_get_invalid_token(self): + res = { + "message": "Sync token invalid or too old. If you are attemping to keep resources in sync, you must re-fetch the full dataset for this query now.", + "sync": "edfc0896b370b7a479886d316131bf5c:0" + } + responses.add(GET, 'http://app/events?resource=3214312&sync=de4774f6915eae04714ca93bb2f5ee81%3A3', status=412, body=json.dumps(res), match_querystring=True) + # responses.add(GET, 'http://app/project/3214312/events?sync=de4774f6915eae04714ca93bb2f5ee81%3A3', status=412, body=json.dumps(res), match_querystring=True) + self.assertRaises(asana.error.InvalidTokenError, self.client.events.get, ({ 'resource': 3214312, 'sync': 'de4774f6915eae04714ca93bb2f5ee81:3' })) + # self.assertEqual(self.client.events.get({ 'resource': 3214312, 'sync': 'de4774f6915eae04714ca93bb2f5ee81:3' }), res) + + def test_project_events_get_next(self): + responses.add(GET, 'http://app/events?resource=1', status=412, body=json.dumps({ "sync": "1" }), match_querystring=True) + responses.add(GET, 'http://app/events?resource=1&sync=1', status=200, body=json.dumps({ "data": [], "sync": "2" }), match_querystring=True) + responses.add(GET, 'http://app/events?resource=1&sync=2', status=200, body=json.dumps({ "data": [{}, {}, {}], "sync": "3" }), match_querystring=True) + + self.assertEqual(len(self.client.events.get_next({ "resource": "1" })[0]), 3) + + def test_project_events_get_next_unknown_object(self): + responses.add(GET, 'http://app/events?resource=1', status=400, body=json.dumps({ "sync": "1" }), match_querystring=True) + + self.assertRaises(asana.error.InvalidRequestError, self.client.events.get_next, ({ "resource": 1 })) + + def test_project_events_get_next_invalid_token(self): + responses.add(GET, 'http://app/events?resource=1&sync=invalid', status=412, body=json.dumps({ "sync": "1" }), match_querystring=True) + + self.assertRaises(asana.error.InvalidTokenError, self.client.events.get_next, ({ "resource": 1, "sync": "invalid" })) + + def test_project_events_get_iterator(self): + responses.add(GET, 'http://app/events?resource=1', status=412, body=json.dumps({ "sync": "1" }), match_querystring=True) + responses.add(GET, 'http://app/events?resource=1&sync=1', status=200, body=json.dumps({ "data": [], "sync": "2" }), match_querystring=True) + responses.add(GET, 'http://app/events?resource=1&sync=2', status=200, body=json.dumps({ "data": ['a', 'b'], "sync": "3" }), match_querystring=True) + responses.add(GET, 'http://app/events?resource=1&sync=3', status=200, body=json.dumps({ "data": ['c'], "sync": "4" }), match_querystring=True) + + iterator = self.client.events.get_iterator({ "resource": "1" }) + self.assertEqual(next(iterator), 'a') + self.assertEqual(next(iterator), 'b') + self.assertEqual(next(iterator), 'c') + + def test_project_events_get_iterator_unknown_object(self): + responses.add(GET, 'http://app/events?resource=1', status=400, body=json.dumps({ "sync": "1" }), match_querystring=True) + + iterator = self.client.events.get_iterator({ "resource": 1 }) + self.assertRaises(asana.error.InvalidRequestError, next, (iterator)) + + def test_project_events_get_iterator_invalid_token(self): + responses.add(GET, 'http://app/events?resource=1&sync=invalid', status=412, body=json.dumps({ "sync": "1" }), match_querystring=True) + + iterator = self.client.events.get_iterator({ "resource": 1, "sync": "invalid" }) + self.assertRaises(asana.error.InvalidTokenError, next, (iterator)) diff --git a/tests/test_client_jobs.py b/tests/test_client_jobs.py new file mode 100644 index 00000000..bbd69588 --- /dev/null +++ b/tests/test_client_jobs.py @@ -0,0 +1,13 @@ +from .helpers import * + +class TestClientJobs(ClientTestCase): + def test_jobs_get_job(self): + res = { + "data": { + "id": 1331, + "name": "Things to Buy" + } + } + responses.add(GET, 'http://app/jobs/1331', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.jobs.get_job('1331'), res['data']) + diff --git a/tests/test_client_organization_exports.py b/tests/test_client_organization_exports.py new file mode 100644 index 00000000..b768c2c3 --- /dev/null +++ b/tests/test_client_organization_exports.py @@ -0,0 +1,40 @@ +import json + +import responses + +from .helpers import ClientTestCase, GET, DELETE, POST, PUT + + +class TestClientOrganizationExports(ClientTestCase): + def test_organization_exports_get_organization_export(self): + resp = { + "data": { + "id": 1234, + "created_at": '2012-02-22T02:06:58.147Z', + "download_url": + 'https://asana-export.s3.amazonaws.com/export-1.json.gz', + "state": "pending", + "organization": { + "id": 14916, "name": "My Workspace" + } + } + } + + responses.add( + GET, 'http://app/organization_exports/1234', status=200, + body=json.dumps(resp), match_querystring=True) + self.assertEqual( + self.client.organization_exports.get_organization_export('1234'), resp['data']) + + def test_organization_exports_create_organization_export(self): + resp = { + "data": { + "organization": 14916 + } + } + + responses.add( + POST, 'http://app/organization_exports', status=200, + body=json.dumps(resp), match_querystring=True) + self.assertEqual( + self.client.organization_exports.create_organization_export(), resp['data']) diff --git a/tests/test_client_portfolio_memberships.py b/tests/test_client_portfolio_memberships.py new file mode 100644 index 00000000..84293080 --- /dev/null +++ b/tests/test_client_portfolio_memberships.py @@ -0,0 +1,34 @@ +from .helpers import * + +class TestClientPortfolioMemberships(ClientTestCase): + def test_portfolio_memberships_get_portfolio_membership(self): + res = { + "data": { + "id": 1331, + "name": "Things to Buy" + } + } + responses.add(GET, 'http://app/portfolio_memberships/1331', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.portfolio_memberships.get_portfolio_membership('1331'), res['data']) + + def test_portfolio_memberships_get_portfolio_memberships_for_portfolio(self): + res = { + "data": [ + { + "id": 1331, + "name": "Things to Buy" + } + ] + } + responses.add(GET, 'http://app/portfolios/1331/portfolio_memberships', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.portfolio_memberships.get_portfolio_memberships_for_portfolio('1331'), res['data']) + + def test_portfolio_memberships_get_portfolio_memberships(self): + res = { + "data": [ + { "id": 1331, "name": "Things to buy" }, + { "id": 14641, "name": "Cat Stuff" } + ] + } + responses.add(GET, 'http://app/portfolio_memberships', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.portfolio_memberships.get_portfolio_memberships(), res['data']) diff --git a/tests/test_client_portfolios.py b/tests/test_client_portfolios.py new file mode 100644 index 00000000..d9627413 --- /dev/null +++ b/tests/test_client_portfolios.py @@ -0,0 +1,95 @@ +from .helpers import * + +class TestClientPortfolios(ClientTestCase): + def test_portfolios_create_portfolio(self): + req = { + "data": { + "name": "Things to Buy", + "notes": "These are things we want to purchase.", + "workspace": 14916 + } + } + res = { + "data": { + "id": 1331, + "name": "Things to Buy", + "notes": "These are things we want to purchase." + } + } + responses.add(POST, 'http://app/portfolios', status=201, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.portfolios.create_portfolio(req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_portfolios_get_portfolio(self): + res = { + "data": { + "id": 1331, + "name": "Things to Buy", + "notes": "These are things we want to purchase." + } + } + responses.add(GET, 'http://app/portfolios/1331', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.portfolios.get_portfolio('1331'), res['data']) + + def test_portfolios_update_portfolio(self): + req = { + "data": { + "notes": "These are things we NEED to purchase." + } + } + res = { + "data": { + "id": 1331, + "name": "Things to Buy", + "notes": "These are things we NEED to purchase." + } + } + responses.add(PUT, 'http://app/portfolios/1331', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.portfolios.update_portfolio('1331', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_portfolios_delete_portfolio(self): + res = { "data": {} } + responses.add(DELETE, 'http://app/portfolios/1331', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.portfolios.delete_portfolio('1331'), res['data']) + + def test_portfolios_get_portfolios(self): + res = { + "data": [ + { "id": 1331, "name": "Things to buy" }, + { "id": 14641, "name": "Cat Stuff" } + ] + } + responses.add(GET, 'http://app/portfolios', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.portfolios.get_portfolios(), res['data']) + + def test_portfolios_add_custom_field_settings(self): + req = { + "data": { + "custom_field":124578, + "is_important": true + } + } + res = { + "data": {} + } + + responses.add(POST, 'http://app/portfolios/1331/addCustomFieldSetting', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.portfolios.add_custom_field_setting(1331, req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + + def test_portfolios_remove_custom_field_settings(self): + req = { + "data": { + "custom_field":124578, + } + } + res = { + "data": {} + } + + responses.add(POST, 'http://app/portfolios/1331/addCustomFieldSetting', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.portfolios.add_custom_field_setting('1331', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + diff --git a/tests/test_client_projects.py b/tests/test_client_projects.py new file mode 100644 index 00000000..7932e688 --- /dev/null +++ b/tests/test_client_projects.py @@ -0,0 +1,104 @@ +from .helpers import * + +class TestClientProjects(ClientTestCase): + def test_projects_create_project(self): + req = { + "data": { + "name": "Things to Buy", + "notes": "These are things we want to purchase.", + "workspace": 14916 + } + } + res = { + "data": { + "id": 1331, + "name": "Things to Buy", + "notes": "These are things we want to purchase." + } + } + responses.add(POST, 'http://app/projects', status=201, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.projects.create_project(req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_projects_get_project(self): + res = { + "data": { + "id": 1331, + "name": "Things to Buy", + "notes": "These are things we want to purchase." + } + } + responses.add(GET, 'http://app/projects/1331', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.projects.get_project('1331'), res['data']) + + def test_projects_update_project(self): + req = { + "data": { + "notes": "These are things we NEED to purchase." + } + } + res = { + "data": { + "id": 1331, + "name": "Things to Buy", + "notes": "These are things we NEED to purchase." + } + } + responses.add(PUT, 'http://app/projects/1331', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.projects.update_project('1331', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_projects_delete_project(self): + res = { "data": {} } + responses.add(DELETE, 'http://app/projects/1331', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.projects.delete_project('1331'), res['data']) + + def test_projects_get_projects_for_workspace(self): + res = { + "data": [ + { "id": 1331, "name": "Things to buy" }, + { "id": 14641, "name": "Cat Stuff" } + ] + } + responses.add(GET, 'http://app/workspaces/14916/projects', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.projects.get_projects_for_workspace('14916'), res['data']) + + def test_projects_get_projects(self): + res = { + "data": [ + { "id": 1331, "name": "Things to buy" }, + { "id": 14641, "name": "Cat Stuff" } + ] + } + responses.add(GET, 'http://app/projects', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.projects.get_projects(), res['data']) + + def test_projects_add_custom_field_setting_for_project(self): + req = { + "data": { + "custom_field":124578, + "is_important": true + } + } + res = { + "data": {} + } + + responses.add(POST, 'http://app/projects/1331/addCustomFieldSetting', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.projects.add_custom_field_setting_for_project('1331', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + + def test_projects_remove_custom_field_setting_for_project(self): + req = { + "data": { + "custom_field":124578, + } + } + res = { + "data": {} + } + + responses.add(POST, 'http://app/projects/1331/removeCustomFieldSetting', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.projects.remove_custom_field_setting_for_project('1331', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) diff --git a/tests/test_client_sections.py b/tests/test_client_sections.py new file mode 100644 index 00000000..1026cf19 --- /dev/null +++ b/tests/test_client_sections.py @@ -0,0 +1,114 @@ +import json + +import responses + +from .helpers import ClientTestCase, GET, DELETE, POST, PUT + + +class TestClientSections(ClientTestCase): + + def test_sections_create_section_for_project(self): + resp = { + "data": { + "id": 2001, + "name": "High Priority:", + "created_at": "2017-01-17T22:06:39.249Z", + "project": { + "id": 1331, + "name": "Things to buy" + } + } + } + + responses.add( + POST, 'http://app/projects/1331/sections', status=200, + body=json.dumps(resp), match_querystring=True) + self.assertEqual( + self.client.sections.create_section_for_project('1331'), resp['data']) + + def test_sections_get_sections_for_project(self): + resp = { + "data": [ + { + "id": 2001, + "name": "High Priority:" + }, + { + "id": 2002, + "name": "Low Priority:" + }, + ] + } + + responses.add( + GET, 'http://app/projects/1331/sections', status=200, + body=json.dumps(resp), match_querystring=True) + self.assertEqual( + self.client.sections.get_sections_for_project('1331'), resp['data']) + + def test_sections_get_section(self): + resp = { + "data": { + "id": 2001, + "name": "High Priority:", + "created_at": "2017-01-17T22:06:39.249Z", + "project": { + "id": 1331, + "name": "Things to buy" + } + } + } + + responses.add( + GET, 'http://app/sections/2001', status=200, + body=json.dumps(resp), match_querystring=True) + self.assertEqual( + self.client.sections.get_section('2001'), resp['data']) + + def test_sections_update_section(self): + req = { + "name": "High Priority, renamed:" + } + resp = { + "data": { + "id": 2001, + "name": "High Priority, renamed:", + "created_at": "2017-01-17T22:06:39.249Z", + "project": { + "id": 1331, + "name": "Things to buy" + } + } + } + + responses.add( + PUT, 'http://app/sections/2001', status=200, + body=json.dumps(resp), match_querystring=True) + self.assertEqual( + self.client.sections.update_section('2001', req), resp['data']) + + def test_sections_delete_section(self): + resp = { + "data": {} + } + + responses.add( + DELETE, 'http://app/sections/2001', status=200, + body=json.dumps(resp), match_querystring=True) + self.assertEqual( + self.client.sections.delete_section('2001'), resp['data']) + + def test_sections_insert_section_for_project(self): + resp = { + "data": { + "section": 2001, + "project": 1331, + "before_section": 1330 + } + } + + responses.add( + POST, 'http://app/projects/1331/sections/insert', status=200, + body=json.dumps(resp), match_querystring=True) + self.assertEqual( + self.client.sections.insert_section_for_project('1331'), resp['data']) diff --git a/tests/test_client_stories.py b/tests/test_client_stories.py new file mode 100644 index 00000000..8f37df53 --- /dev/null +++ b/tests/test_client_stories.py @@ -0,0 +1,57 @@ +from .helpers import * + +class TestClientStories(ClientTestCase): + + def test_stories_get_stories_for_task(self): + res = { + "data": [ + { + "created_at": "2011-12-21T23:23:01.259Z", + "created_by": { "id": 5678, "name": "Greg Sanchez" }, + "id": 2001, + "text": "added to Things To Buy", + "type": "system" + }, + { + "created_at": "2012-01-02T21:32:40.112Z", + "created_by": { "id": 1234, "name": "Tim Bizarro" }, + "id": 2002, + "text": "Again? Wow, we really go through this stuff fast.", + "type": "comment" + } + ] + } + responses.add(GET, 'http://app/tasks/1001/stories', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.stories.get_stories_for_task('1001'), res['data']) + + def test_stories_get_story(self): + res = { + "data": { + "created_at": "2012-02-22T02:06:58.147Z", + "created_by": { "id": 1123, "name": "Mittens" }, + "id": 2001, + "source": "web", + "target": { "id": 1234, "name": "Buy catnip" }, + "text": "Yes, please!", + "type": "comment" + } + } + responses.add(GET, 'http://app/stories/2001', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.stories.get_story('2001'), res['data']) + + def test_stories_create_story_for_task(self): + req = { "data": { "text": "This is a very nice comment." } } + res = { + "data": { + "created_at": "2011-12-21T23:23:01.259Z", + "created_by": { "id": 5678, "name": "Greg Sanchez" }, + "id": 2001, + "source": "api", + "target": { "id": 1001, "name": "Buy catnip" }, + "text": "This is a very nice comment.", + "type": "comment" + } + } + responses.add(POST, 'http://app/tasks/1001/stories', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.stories.create_story_for_task('1001', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) diff --git a/tests/test_client_tags.py b/tests/test_client_tags.py new file mode 100644 index 00000000..553fa960 --- /dev/null +++ b/tests/test_client_tags.py @@ -0,0 +1,37 @@ +from .helpers import * + +class TestClientTags(ClientTestCase): + def test_tags_create_tag(self): + req = { "data": { "name": "fluffy", "workspace": 14916 } } + res = { "data": { "id": 1771, "name": "fluffy" } } + responses.add(POST, 'http://app/tags', status=201, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tags.create_tag(req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_tags_get_tag(self): + res = { + "data": { + "id": 1331, + "name": "Things to Buy", + "notes": "These are things we want to purchase." + } + } + responses.add(GET, 'http://app/tags/1331', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tags.get_tag('1331'), res['data']) + + def test_tags_update_tag(self): + req = { "data": { "name": "Things to Sell" } } + res = { "data": { "id": 1331, "name": "Things to Sell" } } + responses.add(PUT, 'http://app/tags/1331', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tags.update_tag('1331', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_tags_get_tags_for_workspace(self): + res = { + "data": [ + { "id": 1331, "name": "Things to buy" }, + { "id": 14641, "name": "Cat Stuff" } + ] + } + responses.add(GET, 'http://app/workspaces/14916/tags', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tags.get_tags_for_workspace('14916'), res['data']) diff --git a/tests/test_client_tasks.py b/tests/test_client_tasks.py new file mode 100644 index 00000000..343b5653 --- /dev/null +++ b/tests/test_client_tasks.py @@ -0,0 +1,239 @@ +from .helpers import * + +class TestClientTasks(ClientTestCase): + + def test_tasks_create_task(self): + req = { + "data": { + "assignee": 1235, + "followers": [5678], + "name": "Hello, world.", + "notes": "How are you today?", + "workspace": 14916 + } + } + res = { + "data": { + "assignee": { "id": 1235, "name": "Tim Bizarro" }, + "assignee_status": "inbox", + "completed": false, + "completed_at": null, + "created_at": "2012-02-22T02:06:58.158Z", + "due_on": null, + "followers": [{ "id": 5678, "name": "Greg Sanchez" } ], + "id": 1001, + "modified_at": "2012-02-22T02:06:58.158Z", + "name": "Hello, world!", + "notes": "How are you today?", + "parent": null, + "projects": [{ "id": 14641, "name": "Cat Stuff" }], + "workspace": { "id": 14916, "name": "My Favorite Workspace" } + } + } + responses.add(POST, 'http://app/tasks', status=201, body=json.dumps(res), match_querystring=True) + + self.assertEqual(self.client.tasks.create_task(req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_tasks_get_task(self): + res = { + "data": { + "assignee": { "id": 1234, "name": "Tim Bizarro" }, + "created_at": "2012-02-22T02:06:58.158Z" + } + } + responses.add(GET, 'http://app/tasks/1001', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.get_task('1001'), res['data']) + + def test_tasks_get_tasks_for_project(self): + res = { + "data": [ + { "id": 2001, "name": "Catnip" }, + { "id": 2002, "name": "Kitty litter" } + ] + } + responses.add(GET, 'http://app/projects/1331/tasks', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.get_tasks_for_project('1331'), res['data']) + + def test_tasks_update_task(self): + req = { "data": { "assignee": "me" } } + res = { + "data": { + "assignee": { "id": 1234, "name": "Tim Bizarro" }, + "id": 1001 + } + } + responses.add(PUT, 'http://app/tasks/1001', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.update_task('1001', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_tasks_delete_task(self): + res = { "data": {} } + responses.add(DELETE, 'http://app/tasks/1001', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.delete_task('1001'), res['data']) + + def test_tasks_get_tasks(self): + res = { + "data": [ + { "id": 1248, "name": "Buy catnip" }, + { "id": 24816, "name": "Reflect on role of kittens in society" } + ] + } + responses.add(GET, 'http://app/tasks?workspace=14916&assignee=me', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.get_tasks({ 'workspace': 14916, 'assignee': 'me' }), res['data']) + + def test_tasks_add_subtask(self): + req = { + "data": { + "assignee": 1235, + "followers": [5678], + "name": "Tell Luke", + "notes": "He's going to be upset." + } + } + res = { + "data": { + "assignee": { "id": 1235, "name": "Darth Vader" }, + "assignee_status": "inbox", + "completed": false, + "completed_at": null, + "created_at": "2012-02-22T02:06:58.158Z", + "due_on": null, + "followers": [{ "id": 5678, "name": "Emperor Palpatine" } ], + "id": 1001, + "modified_at": "2012-02-22T02:06:58.158Z", + "name": "Tell Luke", + "notes": "He's going to be upset.", + "parent": { "id": 2272, "name": "Tell kids I am their father." }, + "projects": [], + "workspace": { "id": 14916, "name": "Star Wars" } + } + } + responses.add(POST, 'http://app/tasks/2272/subtasks', status=201, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.add_subtask('2272', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_tasks_subtasks(self): + res = { + "data": [ + { "id": 5005, "name": "Steal Underwear" }, + { "id": 6709, "name": "???" }, + { "id": 9812, "name": "Profit" } + ] + } + responses.add(GET, 'http://app/tasks/7331/subtasks', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.subtasks(7331), res['data']) + + def test_tasks_set_parent(self): + req = { "data": { "parent": 1331 } } + res = { + "data": { + "id": 2272, + "name": "Tell Luke", + "parent": [{ "id": 1331, "name": "Tell kids I am their father" }] + } + } + responses.add(POST, 'http://app/tasks/2272/setParent', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.set_parent('2272', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_tasks_projects(self): + res = { + "data": [ + { "id": 1331, "name": "Things To Buy" }, + { "id": 14641, "name": "Cat Stuff" } + ] + } + responses.add(GET, 'http://app/tasks/1001/projects', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.projects('1001'), res['data']) + + def test_tasks_add_project(self): + req = { "data": { "project": 14641 } } + res = { "data": {} } + responses.add(POST, 'http://app/tasks/1001/addProject', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.add_project('1001', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_tasks_remove_project(self): + req = { "data": { "project": 14641 } } + res = { "data": {} } + responses.add(POST, 'http://app/tasks/1001/removeProject', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.remove_project('1001', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_tasks_tags(self): + res = { + "data": [ + { "id": 1331, "name": "orange" }, + { "id": 1771, "name": "fluffy" } + ] + } + responses.add(GET, 'http://app/tasks/1001/tags', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.tags('1001'), res['data']) + + def test_tasks_1001_addTag(self): + req = { "data": { "tag": 1771 } } + res = { "data": {} } + responses.add(POST, 'http://app/tasks/1001/addTag', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.add_tag('1001', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_tasks_removeTag(self): + req = { "data": { "tag": 1771 } } + res = { "data": {} } + responses.add(POST, 'http://app/tasks/1001/removeTag', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.remove_tag('1001', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_tasks_add_followers(self): + req = { "data": { "followers": [1235] } } + res = { + "data": { + "followers": [{ "id": 1235, "name": "Darth Vader" }], + "id": 1001 + } + } + responses.add(POST, 'http://app/tasks/1001/addFollowers', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.add_followers('1001', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_tasks_remove_followers(self): + req = { "data": { "followers": [1235] } } + res = { "data": { "followers": [], "id": 1001 } } + responses.add(POST, 'http://app/tasks/1001/removeFollowers', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.remove_followers('1001', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) + + def test_tasks_get_tasks_for_tag(self): + res = { + "data": [ + { "id": 2001, "name": "Catnip" }, + { "id": 2002, "name": "Kitty litter" } + ] + } + responses.add(GET, 'http://app/tags/1331/tasks', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.get_tasks_for_tag('1331'), res['data']) + + def test_tasks_custom_field_data(self): + res = { + "data": { + "id": 1001, + "name": "Hello, world!", + "completed": false, + "custom_fields": [ + { + "id": 124578, + "name": "Priority", + "type": "enum", + "enum_value": { + "id": 789, + "name": "Low", + "enabled": true, + "color": "blue" + } + } + ] + } + } + responses.add(GET, 'http://app/tasks/1001', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.get_task('1001'), res['data']) diff --git a/tests/test_client_teams.py b/tests/test_client_teams.py new file mode 100644 index 00000000..7a6a2e0c --- /dev/null +++ b/tests/test_client_teams.py @@ -0,0 +1,13 @@ +from .helpers import * + +class TestClientTeams(ClientTestCase): + + def test_teams_get_teams_for_workspace(self): + res = { + "data": [ + { "id": 5832, "name": "Atlanta Braves" }, + { "id": 15923, "name": "New York Yankees" } + ] + } + responses.add(GET, 'http://app/workspaces/13523/teams', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.teams.get_teams_for_workspace('13523'), res['data']) diff --git a/tests/test_client_user_task_lists.py b/tests/test_client_user_task_lists.py new file mode 100644 index 00000000..1576122d --- /dev/null +++ b/tests/test_client_user_task_lists.py @@ -0,0 +1,33 @@ +from .helpers import * + +class TestClientUserTaskLists(ClientTestCase): + def test_user_task_lists_get_user_task_list(self): + res = { + "data": { + "id": 1331, + "name": "Things to Buy" + } + } + responses.add(GET, 'http://app/user_task_lists/1331', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.user_task_lists.get_user_task_list('1331'), res['data']) + + def test_user_task_lists_get_user_task_list_for_user(self): + res = { + "data": { + "id": 1331, + "name": "Things to Buy" + } + } + responses.add(GET, 'http://app/users/1331/user_task_list', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.user_task_lists.get_user_task_list_for_user('1331'), res['data']) + + def test_task_get_tasks_for_user_task_list(self): + res = { + "data": [ + { "id": 1331, "name": "Things to buy" }, + { "id": 14641, "name": "Cat Stuff" } + ] + } + responses.add(GET, 'http://app/user_task_lists/1335/tasks', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.tasks.get_tasks_for_user_task_list('1335'), res['data']) + diff --git a/tests/test_client_users.py b/tests/test_client_users.py new file mode 100644 index 00000000..f905256b --- /dev/null +++ b/tests/test_client_users.py @@ -0,0 +1,42 @@ +from .helpers import * + +class TestClientUsers(ClientTestCase): + + def test_users_me(self): + res = { + "data": { "email":"sanchez@...", "id": 999, "name":"Greg Sanchez" } + } + responses.add(GET, 'http://app/users/me', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.users.get_user('me'), res['data']) + + def test_users_get_user(self): + res = { + "data": { + "email": "gsanchez@example.com", + "id": 5678, + "name": "Greg Sanchez", + "workspaces": [{ "id": 1337, "name": "My Favorite Workspace" }] + } + } + responses.add(GET, 'http://app/users/5678', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.users.get_user('5678'), res['data']) + + def test_users_get_users(self): + res = { + "data": [ + { "email": "tbizarro@example.com", "id": 1234, "name": "Tim Bizarro" }, + { "email": "gsanchez@example.com", "id": 5678, "name": "Greg Sanchez" } + ] + } + # responses.add(GET, 'http://app/users?opt_fields=name,email', status=200, body=json.dumps(res), match_querystring=True) + responses.add(GET, 'http://app/users', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.users.get_users(), res['data']) + + def test_users_get_users_for_workspace(self): + res = { + "data": [ + { "id": 5678, "name": "Greg Sanchez" } + ] + } + responses.add(GET, 'http://app/workspaces/1337/users', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.users.get_users_for_workspace('1337'), res['data']) diff --git a/tests/test_client_webhooks.py b/tests/test_client_webhooks.py new file mode 100644 index 00000000..9efd5556 --- /dev/null +++ b/tests/test_client_webhooks.py @@ -0,0 +1,38 @@ +from .helpers import * + + +class TestClientWebhooks(ClientTestCase): + + def setUp(self): + ClientTestCase.setUp(self) + self.webhook_data = { + "id": 222, + "resource": { + "id": 111, + "name": "the resource" + }, + "target": "https://foo/123", + "active": true + } + + def test_webhooks_create_webhook(self): + req = { "resource": 111, "target": "https://foo/123" } + res = { "data": self.webhook_data } + responses.add(POST, 'http://app/webhooks', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.webhooks.create_webhook(req), self.webhook_data) + + def test_webhooks_get_webhooks(self): + req = { "workspace": 1337 } + res = { "data": [self.webhook_data] } + responses.add(GET, 'http://app/webhooks?workspace=1337', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.webhooks.get_webhooks(req), [self.webhook_data]) + + def test_webhooks_get_webhook(self): + res = { "data": self.webhook_data } + responses.add(GET, 'http://app/webhooks/222', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.webhooks.get_webhook('222'), self.webhook_data) + + def test_webhooks_delete_webhook(self): + res = { "data": {} } + responses.add(DELETE, 'http://app/webhooks/222', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.webhooks.delete_webhook('222'), {}) diff --git a/tests/test_client_workspaces.py b/tests/test_client_workspaces.py new file mode 100644 index 00000000..6226a242 --- /dev/null +++ b/tests/test_client_workspaces.py @@ -0,0 +1,20 @@ +from .helpers import * + +class TestClientWorkspaces(ClientTestCase): + + def test_workspaces_get_workspaces(self): + res = { "data": [{ "id": 1337, "name": "My Favorite Workspace" }]} + responses.add(GET, 'http://app/workspaces', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.workspaces.get_workspaces(), res['data']) + + def test_workspaces_get_workspace(self): + res = { "data": [{ "id": 1337, "name": "My Favorite Workspace" }]} + responses.add(GET, 'http://app/workspaces/222', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.workspaces.get_workspace('222'), res['data']) + + def test_workspaces_update_workspace(self): + req = { "data": { "name": "Everyone's Favorite Workspace" } } + res = { "data": { "id": 1337, "name": "Everyone's Favorite Workspace" } } + responses.add(PUT, 'http://app/workspaces/1337', status=200, body=json.dumps(res), match_querystring=True) + self.assertEqual(self.client.workspaces.update_workspace('1337', req['data']), res['data']) + self.assertEqual(json.loads(responses.calls[0].request.body), req) diff --git a/tests/test_errors.py b/tests/test_errors.py new file mode 100644 index 00000000..162ce08d --- /dev/null +++ b/tests/test_errors.py @@ -0,0 +1,24 @@ +import json + +import responses + +from .helpers import asana, ClientTestCase + + +class TestErrors(ClientTestCase): + def test_premium_only_402(self): + resp_json = { + "errors": [ + { + "message": ( + "Custom Fields are not available for free " + "users or guests.") + } + ] + } + responses.add( + responses.GET, + 'http://app/workspaces/12345/custom_fields', status=402, + body=json.dumps(resp_json), match_querystring=True) + with self.assertRaises(asana.error.PremiumOnlyError): + self.client.custom_fields.get_custom_fields_for_workspace('12345') diff --git a/tox.ini b/tox.ini deleted file mode 100644 index a310bec9..00000000 --- a/tox.ini +++ /dev/null @@ -1,10 +0,0 @@ -[tox] -envlist = py3 - -[testenv] -deps=-r{toxinidir}/requirements.txt - -r{toxinidir}/test-requirements.txt - -commands= - nosetests \ - []