flat_api 0.3.5 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +69 -0
- data/LICENSE +201 -0
- data/README.md +92 -0
- data/lib/flat_api/api/account_api.rb +4 -4
- data/lib/flat_api/api/class_api.rb +281 -63
- data/lib/flat_api/api/collection_api.rb +63 -50
- data/lib/flat_api/api/edu_resources_api.rb +38 -26
- data/lib/flat_api/api/group_api.rb +432 -9
- data/lib/flat_api/api/omr_api.rb +894 -0
- data/lib/flat_api/api/organization_api.rb +307 -35
- data/lib/flat_api/api/score_api.rb +129 -80
- data/lib/flat_api/api/task_api.rb +5 -5
- data/lib/flat_api/api/user_api.rb +45 -14
- data/lib/flat_api/api_client.rb +169 -96
- data/lib/flat_api/api_error.rb +3 -3
- data/lib/flat_api/api_model_base.rb +88 -0
- data/lib/flat_api/client.rb +69 -0
- data/lib/flat_api/configuration.rb +124 -25
- data/lib/flat_api/errors.rb +86 -0
- data/lib/flat_api/models/add_group_user200_response.rb +148 -0
- data/lib/flat_api/models/add_group_user_request.rb +165 -0
- data/lib/flat_api/models/api_access_token.rb +13 -80
- data/lib/flat_api/models/app_scopes.rb +6 -4
- data/lib/flat_api/models/assignment.rb +190 -85
- data/lib/flat_api/models/assignment_capabilities.rb +53 -80
- data/lib/flat_api/models/assignment_capabilities_can_publish_in_class_error.rb +33 -80
- data/lib/flat_api/models/assignment_copy.rb +5 -6
- data/lib/flat_api/models/assignment_copy_response.rb +187 -82
- data/lib/flat_api/models/assignment_copy_to_class.rb +23 -80
- data/lib/flat_api/models/assignment_copy_to_resource_library.rb +23 -80
- data/lib/flat_api/models/assignment_group.rb +232 -0
- data/lib/flat_api/models/assignment_submission.rb +104 -81
- data/lib/flat_api/models/assignment_submission_comment.rb +13 -80
- data/lib/flat_api/models/assignment_submission_comment_creation.rb +23 -80
- data/lib/flat_api/models/assignment_submission_comments.rb +13 -80
- data/lib/flat_api/models/assignment_submission_history.rb +33 -80
- data/lib/flat_api/models/assignment_submission_history_attachment.rb +13 -80
- data/lib/flat_api/models/assignment_submission_history_state.rb +3 -3
- data/lib/flat_api/models/assignment_submission_lti.rb +64 -86
- data/lib/flat_api/models/{assignment_submission_playback_inner.rb → assignment_submission_playback.rb} +36 -83
- data/lib/flat_api/models/assignment_submission_state.rb +3 -3
- data/lib/flat_api/models/assignment_submission_students_mode.rb +40 -0
- data/lib/flat_api/models/assignment_submission_update.rb +25 -81
- data/lib/flat_api/models/assignment_type.rb +5 -4
- data/lib/flat_api/models/assignment_update.rb +218 -87
- data/lib/flat_api/models/class_assignment.rb +219 -82
- data/lib/flat_api/models/class_assignment_all_of_canvas.rb +13 -80
- data/lib/flat_api/models/class_assignment_all_of_lti.rb +13 -80
- data/lib/flat_api/models/class_assignment_all_of_mfc.rb +13 -80
- data/lib/flat_api/models/class_assignment_update.rb +237 -94
- data/lib/flat_api/models/class_assignment_update_all_of_google_classroom.rb +13 -80
- data/lib/flat_api/models/class_assignment_update_all_of_microsoft_graph.rb +13 -80
- data/lib/flat_api/models/class_attachment_creation.rb +51 -86
- data/lib/flat_api/models/class_creation.rb +13 -80
- data/lib/flat_api/models/class_details.rb +85 -81
- data/lib/flat_api/models/class_details_canvas.rb +13 -80
- data/lib/flat_api/models/class_details_clever.rb +13 -80
- data/lib/flat_api/models/class_details_google_classroom.rb +13 -80
- data/lib/flat_api/models/class_details_google_drive.rb +13 -80
- data/lib/flat_api/models/class_details_issues.rb +13 -80
- data/lib/flat_api/models/class_details_issues_sync_inner.rb +15 -82
- data/lib/flat_api/models/class_details_lti.rb +28 -85
- data/lib/flat_api/models/class_details_mfc.rb +13 -80
- data/lib/flat_api/models/class_details_microsoft_graph.rb +13 -80
- data/lib/flat_api/models/class_grade_level.rb +3 -3
- data/lib/flat_api/models/class_roles.rb +3 -3
- data/lib/flat_api/models/class_state.rb +5 -4
- data/lib/flat_api/models/class_update.rb +13 -80
- data/lib/flat_api/models/collection.rb +182 -81
- data/lib/flat_api/models/collection_app.rb +13 -80
- data/lib/flat_api/models/collection_capabilities.rb +63 -80
- data/lib/flat_api/models/collection_contents.rb +166 -0
- data/lib/flat_api/models/collection_creation.rb +20 -99
- data/lib/flat_api/models/collection_modification.rb +17 -82
- data/lib/flat_api/models/collection_privacy.rb +3 -3
- data/lib/flat_api/models/collection_type.rb +7 -6
- data/lib/flat_api/models/credit_transaction.rb +388 -0
- data/lib/flat_api/models/edu_library.rb +63 -82
- data/lib/flat_api/models/edu_resource.rb +101 -84
- data/lib/flat_api/models/edu_resource_assignment_creation.rb +170 -0
- data/lib/flat_api/models/edu_resource_capabilities.rb +27 -84
- data/lib/flat_api/models/edu_resource_copy.rb +23 -80
- data/lib/flat_api/models/edu_resource_creation.rb +96 -86
- data/lib/flat_api/models/edu_resource_folder.rb +39 -84
- data/lib/flat_api/models/edu_resource_lti_link.rb +23 -80
- data/lib/flat_api/models/edu_resource_move.rb +23 -80
- data/lib/flat_api/models/edu_resource_privacy.rb +3 -3
- data/lib/flat_api/models/edu_resource_resource.rb +5 -6
- data/lib/flat_api/models/edu_resource_type.rb +3 -3
- data/lib/flat_api/models/edu_resource_update.rb +101 -86
- data/lib/flat_api/models/edu_resource_use_in_class.rb +23 -80
- data/lib/flat_api/models/flat_error_response.rb +47 -84
- data/lib/flat_api/models/google_classroom_coursework.rb +13 -80
- data/lib/flat_api/models/google_classroom_submission.rb +43 -80
- data/lib/flat_api/models/grade.rb +51 -0
- data/lib/flat_api/models/group.rb +14 -94
- data/lib/flat_api/models/group_creation.rb +238 -0
- data/lib/flat_api/models/group_details.rb +178 -84
- data/lib/flat_api/models/group_type.rb +6 -4
- data/lib/flat_api/models/license_mode.rb +3 -3
- data/lib/flat_api/models/license_sources.rb +3 -3
- data/lib/flat_api/models/lms_name.rb +3 -3
- data/lib/flat_api/models/lti_configuration.rb +56 -0
- data/lib/flat_api/models/lti_configuration1p1.rb +361 -0
- data/lib/flat_api/models/lti_configuration1p1_all_of_tool.rb +199 -0
- data/lib/flat_api/models/lti_configuration1p3.rb +106 -0
- data/lib/flat_api/models/lti_configuration1p3_base.rb +336 -0
- data/lib/flat_api/models/lti_configuration1p3_base_supported_services.rb +166 -0
- data/lib/flat_api/models/lti_configuration1p3_base_supported_services_ags.rb +179 -0
- data/lib/flat_api/models/lti_configuration1p3_base_supported_services_deep_linking.rb +159 -0
- data/lib/flat_api/models/lti_configuration1p3_base_supported_services_nrps.rb +169 -0
- data/lib/flat_api/models/lti_configuration1p3_base_tool.rb +199 -0
- data/lib/flat_api/models/lti_configuration1p3_deployment.rb +529 -0
- data/lib/flat_api/models/lti_configuration1p3_dynamic.rb +530 -0
- data/lib/flat_api/models/lti_configuration1p3_manual.rb +489 -0
- data/lib/flat_api/models/lti_configuration_base.rb +306 -0
- data/lib/flat_api/models/lti_configuration_create.rb +60 -0
- data/lib/flat_api/models/lti_configuration_create1p1.rb +210 -0
- data/lib/flat_api/models/lti_configuration_create1p3_deployment.rb +264 -0
- data/lib/flat_api/models/lti_configuration_create1p3_dynamic.rb +209 -0
- data/lib/flat_api/models/lti_configuration_create1p3_dynamic_platform_info.rb +159 -0
- data/lib/flat_api/models/lti_configuration_create1p3_manual.rb +270 -0
- data/lib/flat_api/models/lti_configuration_update.rb +104 -0
- data/lib/flat_api/models/lti_configuration_update_deployment.rb +169 -0
- data/lib/flat_api/models/lti_configuration_update_standalone.rb +219 -0
- data/lib/flat_api/models/lti_credentials.rb +29 -84
- data/lib/flat_api/models/lti_credentials_creation.rb +23 -80
- data/lib/flat_api/models/media_attachment.rb +43 -88
- data/lib/flat_api/models/media_score_sharing_mode.rb +3 -3
- data/lib/flat_api/models/microsoft_graph_assignment.rb +99 -88
- data/lib/flat_api/models/microsoft_graph_submission.rb +33 -80
- data/lib/flat_api/models/omr_capabilities.rb +480 -0
- data/lib/flat_api/models/omr_details_step_data.rb +228 -0
- data/lib/flat_api/models/omr_details_submission.rb +288 -0
- data/lib/flat_api/models/omr_detected_instrument.rb +260 -0
- data/lib/flat_api/models/omr_imported_metadata.rb +181 -0
- data/lib/flat_api/models/omr_instrument_override.rb +311 -0
- data/lib/flat_api/models/omr_job.rb +394 -0
- data/lib/flat_api/models/omr_job_creation.rb +238 -0
- data/lib/flat_api/models/omr_job_file_metadata.rb +199 -0
- data/lib/flat_api/models/omr_job_file_upload.rb +176 -0
- data/lib/flat_api/models/omr_job_file_upload_result.rb +159 -0
- data/lib/flat_api/models/omr_job_input_file.rb +176 -0
- data/lib/flat_api/models/omr_job_output.rb +40 -0
- data/lib/flat_api/models/omr_job_progress.rb +169 -0
- data/lib/flat_api/models/omr_job_result.rb +161 -0
- data/lib/flat_api/models/omr_job_retention.rb +176 -0
- data/lib/flat_api/models/omr_job_status.rb +44 -0
- data/lib/flat_api/models/omr_locale_details.rb +193 -0
- data/lib/flat_api/models/omr_pending_step.rb +213 -0
- data/lib/flat_api/models/omr_step_name.rb +39 -0
- data/lib/flat_api/models/organization_invitation.rb +54 -81
- data/lib/flat_api/models/organization_invitation_creation.rb +15 -82
- data/lib/flat_api/models/organization_roles.rb +5 -5
- data/lib/flat_api/models/organization_user_access_token_creation.rb +23 -80
- data/lib/flat_api/models/rename_group_request.rb +165 -0
- data/lib/flat_api/models/resource_collaborator.rb +43 -85
- data/lib/flat_api/models/resource_collaborator_creation.rb +13 -80
- data/lib/flat_api/models/resource_rights.rb +43 -85
- data/lib/flat_api/models/score_comment.rb +122 -80
- data/lib/flat_api/models/score_comment_context.rb +73 -80
- data/lib/flat_api/models/score_comment_creation.rb +24 -81
- data/lib/flat_api/models/score_comment_moderation.rb +13 -80
- data/lib/flat_api/models/score_comment_update.rb +18 -85
- data/lib/flat_api/models/score_comments_counts.rb +28 -85
- data/lib/flat_api/models/score_creation.rb +5 -6
- data/lib/flat_api/models/score_creation_builder_data.rb +24 -88
- data/lib/flat_api/models/score_creation_builder_data_all_of_builder_data.rb +23 -80
- data/lib/flat_api/models/score_creation_builder_data_all_of_builder_data_layout_data.rb +13 -80
- data/lib/flat_api/models/score_creation_builder_data_all_of_builder_data_score_data.rb +24 -81
- data/lib/flat_api/models/score_creation_builder_data_all_of_builder_data_score_data_instruments.rb +33 -80
- data/lib/flat_api/models/score_creation_common.rb +14 -81
- data/lib/flat_api/models/score_creation_file_import.rb +39 -86
- data/lib/flat_api/models/score_creation_google_drive_import.rb +24 -81
- data/lib/flat_api/models/score_creation_type.rb +4 -5
- data/lib/flat_api/models/score_details.rb +180 -89
- data/lib/flat_api/models/score_details_all_of_me.rb +193 -0
- data/lib/flat_api/models/score_fork.rb +14 -83
- data/lib/flat_api/models/score_license.rb +4 -5
- data/lib/flat_api/models/score_likes_counts.rb +28 -106
- data/lib/flat_api/models/score_modification.rb +13 -80
- data/lib/flat_api/models/score_plays_counts.rb +28 -85
- data/lib/flat_api/models/score_privacy.rb +3 -3
- data/lib/flat_api/models/score_revision.rb +81 -87
- data/lib/flat_api/models/score_revision_creation.rb +23 -80
- data/lib/flat_api/models/score_revision_statistics.rb +13 -80
- data/lib/flat_api/models/score_source.rb +13 -80
- data/lib/flat_api/models/score_summary.rb +63 -80
- data/lib/flat_api/models/score_track.rb +94 -88
- data/lib/flat_api/models/score_track_creation.rb +13 -80
- data/lib/flat_api/models/score_track_creation_response.rb +165 -0
- data/lib/flat_api/models/score_track_point.rb +23 -80
- data/lib/flat_api/models/score_track_purpose.rb +3 -3
- data/lib/flat_api/models/score_track_state.rb +3 -3
- data/lib/flat_api/models/score_track_type.rb +3 -3
- data/lib/flat_api/models/score_track_update.rb +25 -81
- data/lib/flat_api/models/score_views_counts.rb +28 -85
- data/lib/flat_api/models/task.rb +62 -87
- data/lib/flat_api/models/task_export_options.rb +13 -80
- data/lib/flat_api/models/task_progress.rb +13 -80
- data/lib/flat_api/models/task_result.rb +13 -80
- data/lib/flat_api/models/teaching_theme.rb +47 -0
- data/lib/flat_api/models/tutteo_product.rb +3 -3
- data/lib/flat_api/models/user_admin_update.rb +17 -95
- data/lib/flat_api/models/user_azure_details.rb +13 -80
- data/lib/flat_api/models/user_basics.rb +43 -80
- data/lib/flat_api/models/user_community_profile_links.rb +13 -80
- data/lib/flat_api/models/user_creation.rb +21 -98
- data/lib/flat_api/models/user_details.rb +101 -96
- data/lib/flat_api/models/user_details_admin.rb +72 -85
- data/lib/flat_api/models/user_details_admin_all_of_license.rb +13 -80
- data/lib/flat_api/models/user_public.rb +89 -94
- data/lib/flat_api/models/user_public_summary.rb +58 -81
- data/lib/flat_api/models/user_signin_link.rb +24 -81
- data/lib/flat_api/models/user_signin_link_creation.rb +13 -80
- data/lib/flat_api/oauth.rb +128 -0
- data/lib/flat_api/pagination.rb +88 -0
- data/lib/flat_api/retry.rb +56 -0
- data/lib/flat_api/version.rb +4 -4
- data/lib/flat_api.rb +70 -5
- metadata +98 -330
- data/lib/flat_api/models/flat_locales.rb +0 -56
- data/spec/api/account_api_spec.rb +0 -47
- data/spec/api/class_api_spec.rb +0 -422
- data/spec/api/collection_api_spec.rb +0 -158
- data/spec/api/edu_resources_api_spec.rb +0 -181
- data/spec/api/group_api_spec.rb +0 -71
- data/spec/api/organization_api_spec.rb +0 -201
- data/spec/api/score_api_spec.rb +0 -440
- data/spec/api/task_api_spec.rb +0 -47
- data/spec/api/user_api_spec.rb +0 -75
- data/spec/models/api_access_token_spec.rb +0 -66
- data/spec/models/app_scopes_spec.rb +0 -30
- data/spec/models/assignment_capabilities_can_publish_in_class_error_spec.rb +0 -42
- data/spec/models/assignment_capabilities_spec.rb +0 -60
- data/spec/models/assignment_copy_response_spec.rb +0 -124
- data/spec/models/assignment_copy_spec.rb +0 -32
- data/spec/models/assignment_copy_to_class_spec.rb +0 -48
- data/spec/models/assignment_copy_to_resource_library_spec.rb +0 -42
- data/spec/models/assignment_spec.rb +0 -118
- data/spec/models/assignment_submission_comment_creation_spec.rb +0 -36
- data/spec/models/assignment_submission_comment_spec.rb +0 -72
- data/spec/models/assignment_submission_comments_spec.rb +0 -42
- data/spec/models/assignment_submission_history_attachment_spec.rb +0 -48
- data/spec/models/assignment_submission_history_spec.rb +0 -112
- data/spec/models/assignment_submission_history_state_spec.rb +0 -30
- data/spec/models/assignment_submission_lti_spec.rb +0 -36
- data/spec/models/assignment_submission_playback_inner_spec.rb +0 -42
- data/spec/models/assignment_submission_spec.rb +0 -144
- data/spec/models/assignment_submission_state_spec.rb +0 -30
- data/spec/models/assignment_submission_update_spec.rb +0 -66
- data/spec/models/assignment_type_spec.rb +0 -30
- data/spec/models/assignment_update_spec.rb +0 -100
- data/spec/models/class_assignment_all_of_canvas_spec.rb +0 -42
- data/spec/models/class_assignment_all_of_lti_spec.rb +0 -36
- data/spec/models/class_assignment_all_of_mfc_spec.rb +0 -42
- data/spec/models/class_assignment_spec.rb +0 -216
- data/spec/models/class_assignment_update_all_of_google_classroom_spec.rb +0 -36
- data/spec/models/class_assignment_update_all_of_microsoft_graph_spec.rb +0 -36
- data/spec/models/class_assignment_update_spec.rb +0 -150
- data/spec/models/class_attachment_creation_spec.rb +0 -76
- data/spec/models/class_creation_spec.rb +0 -64
- data/spec/models/class_details_canvas_spec.rb +0 -42
- data/spec/models/class_details_clever_spec.rb +0 -76
- data/spec/models/class_details_google_classroom_spec.rb +0 -42
- data/spec/models/class_details_google_drive_spec.rb +0 -42
- data/spec/models/class_details_issues_spec.rb +0 -36
- data/spec/models/class_details_issues_sync_inner_spec.rb +0 -52
- data/spec/models/class_details_lti_spec.rb +0 -48
- data/spec/models/class_details_mfc_spec.rb +0 -42
- data/spec/models/class_details_microsoft_graph_spec.rb +0 -36
- data/spec/models/class_details_spec.rb +0 -178
- data/spec/models/class_grade_level_spec.rb +0 -30
- data/spec/models/class_roles_spec.rb +0 -30
- data/spec/models/class_state_spec.rb +0 -30
- data/spec/models/class_update_spec.rb +0 -64
- data/spec/models/collection_app_spec.rb +0 -48
- data/spec/models/collection_capabilities_spec.rb +0 -60
- data/spec/models/collection_creation_spec.rb +0 -42
- data/spec/models/collection_modification_spec.rb +0 -42
- data/spec/models/collection_privacy_spec.rb +0 -30
- data/spec/models/collection_spec.rb +0 -114
- data/spec/models/collection_type_spec.rb +0 -30
- data/spec/models/edu_library_spec.rb +0 -62
- data/spec/models/edu_resource_capabilities_spec.rb +0 -48
- data/spec/models/edu_resource_copy_spec.rb +0 -36
- data/spec/models/edu_resource_creation_spec.rb +0 -48
- data/spec/models/edu_resource_folder_spec.rb +0 -36
- data/spec/models/edu_resource_lti_link_spec.rb +0 -36
- data/spec/models/edu_resource_move_spec.rb +0 -36
- data/spec/models/edu_resource_privacy_spec.rb +0 -30
- data/spec/models/edu_resource_resource_spec.rb +0 -32
- data/spec/models/edu_resource_spec.rb +0 -96
- data/spec/models/edu_resource_type_spec.rb +0 -30
- data/spec/models/edu_resource_update_spec.rb +0 -42
- data/spec/models/edu_resource_use_in_class_spec.rb +0 -42
- data/spec/models/flat_error_response_spec.rb +0 -54
- data/spec/models/flat_locales_spec.rb +0 -30
- data/spec/models/google_classroom_coursework_spec.rb +0 -54
- data/spec/models/google_classroom_submission_spec.rb +0 -48
- data/spec/models/group_details_spec.rb +0 -72
- data/spec/models/group_spec.rb +0 -76
- data/spec/models/group_type_spec.rb +0 -30
- data/spec/models/license_mode_spec.rb +0 -30
- data/spec/models/license_sources_spec.rb +0 -30
- data/spec/models/lms_name_spec.rb +0 -30
- data/spec/models/lti_credentials_creation_spec.rb +0 -42
- data/spec/models/lti_credentials_spec.rb +0 -84
- data/spec/models/media_attachment_spec.rb +0 -166
- data/spec/models/media_score_sharing_mode_spec.rb +0 -30
- data/spec/models/microsoft_graph_assignment_spec.rb +0 -54
- data/spec/models/microsoft_graph_submission_spec.rb +0 -42
- data/spec/models/organization_invitation_creation_spec.rb +0 -46
- data/spec/models/organization_invitation_spec.rb +0 -84
- data/spec/models/organization_roles_spec.rb +0 -30
- data/spec/models/organization_user_access_token_creation_spec.rb +0 -36
- data/spec/models/resource_collaborator_creation_spec.rb +0 -72
- data/spec/models/resource_collaborator_spec.rb +0 -112
- data/spec/models/resource_rights_spec.rb +0 -64
- data/spec/models/score_comment_context_spec.rb +0 -78
- data/spec/models/score_comment_creation_spec.rb +0 -66
- data/spec/models/score_comment_moderation_spec.rb +0 -46
- data/spec/models/score_comment_spec.rb +0 -130
- data/spec/models/score_comment_update_spec.rb +0 -54
- data/spec/models/score_comments_counts_spec.rb +0 -54
- data/spec/models/score_creation_builder_data_all_of_builder_data_layout_data_spec.rb +0 -82
- data/spec/models/score_creation_builder_data_all_of_builder_data_score_data_instruments_spec.rb +0 -60
- data/spec/models/score_creation_builder_data_all_of_builder_data_score_data_spec.rb +0 -66
- data/spec/models/score_creation_builder_data_all_of_builder_data_spec.rb +0 -42
- data/spec/models/score_creation_builder_data_spec.rb +0 -60
- data/spec/models/score_creation_common_spec.rb +0 -54
- data/spec/models/score_creation_file_import_spec.rb +0 -76
- data/spec/models/score_creation_google_drive_import_spec.rb +0 -60
- data/spec/models/score_creation_spec.rb +0 -32
- data/spec/models/score_creation_type_spec.rb +0 -30
- data/spec/models/score_details_spec.rb +0 -240
- data/spec/models/score_fork_spec.rb +0 -48
- data/spec/models/score_license_spec.rb +0 -30
- data/spec/models/score_likes_counts_spec.rb +0 -48
- data/spec/models/score_modification_spec.rb +0 -102
- data/spec/models/score_plays_counts_spec.rb +0 -48
- data/spec/models/score_privacy_spec.rb +0 -30
- data/spec/models/score_revision_creation_spec.rb +0 -58
- data/spec/models/score_revision_spec.rb +0 -78
- data/spec/models/score_revision_statistics_spec.rb +0 -54
- data/spec/models/score_source_spec.rb +0 -36
- data/spec/models/score_summary_spec.rb +0 -66
- data/spec/models/score_track_creation_spec.rb +0 -66
- data/spec/models/score_track_point_spec.rb +0 -52
- data/spec/models/score_track_purpose_spec.rb +0 -30
- data/spec/models/score_track_spec.rb +0 -108
- data/spec/models/score_track_state_spec.rb +0 -30
- data/spec/models/score_track_type_spec.rb +0 -30
- data/spec/models/score_track_update_spec.rb +0 -54
- data/spec/models/score_views_counts_spec.rb +0 -48
- data/spec/models/task_export_options_spec.rb +0 -36
- data/spec/models/task_progress_spec.rb +0 -42
- data/spec/models/task_result_spec.rb +0 -42
- data/spec/models/task_spec.rb +0 -100
- data/spec/models/tutteo_product_spec.rb +0 -30
- data/spec/models/user_admin_update_spec.rb +0 -66
- data/spec/models/user_azure_details_spec.rb +0 -48
- data/spec/models/user_basics_spec.rb +0 -94
- data/spec/models/user_community_profile_links_spec.rb +0 -66
- data/spec/models/user_creation_spec.rb +0 -76
- data/spec/models/user_details_admin_all_of_license_spec.rb +0 -60
- data/spec/models/user_details_admin_spec.rb +0 -142
- data/spec/models/user_details_spec.rb +0 -214
- data/spec/models/user_public_spec.rb +0 -178
- data/spec/models/user_public_summary_spec.rb +0 -118
- data/spec/models/user_signin_link_creation_spec.rb +0 -36
- data/spec/models/user_signin_link_spec.rb +0 -42
- data/spec/spec_helper.rb +0 -111
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#Flat API
|
|
3
3
|
|
|
4
|
-
#The Flat API allows you to easily extend the abilities of the [Flat Platform](https://flat.io), with a wide range of use cases including the following: * Creating and importing new music scores using MusicXML, MIDI, Guitar Pro
|
|
4
|
+
#The Flat API allows you to easily extend the abilities of the [Flat Platform](https://flat.io), with a wide range of use cases including the following: * Creating and importing new music scores using MusicXML, MIDI, Guitar Pro, MuseScore, ABC notation, and many other formats * Browsing, updating, copying, exporting the user's scores (for example in MP3, WAV or MIDI) * Managing educational resources with Flat for Education: creating & updating the organization accounts, the classes, rosters and assignments. The Flat API is built on HTTP. Our API is RESTful It has predictable resource URLs. It returns HTTP response codes to indicate errors. It also accepts and returns JSON in the HTTP body. The [schema](/swagger.yaml) of this API follows the [OpenAPI Initiative (OAI) specification](https://www.openapis.org/), you can use and work with [compatible Swagger tools](http://swagger.io/open-source-integrations/). This API features Cross-Origin Resource Sharing (CORS) implemented in compliance with [W3C spec](https://www.w3.org/TR/cors/). You can use your favorite HTTP/REST library for your programming language to use Flat's API. This specification and reference is [available on Github](https://github.com/FlatIO/api-reference). Getting Started and learn more: * [API Overview and introduction](https://flat.io/developers/docs/api/) * [Authentication (Personal Access Tokens or OAuth2)](https://flat.io/developers/docs/api/authentication.html) * [SDKs](https://flat.io/developers/docs/api/sdks.html) * [Rate Limits](https://flat.io/developers/docs/api/rate-limits.html) * [Changelog](https://flat.io/developers/docs/api/changelog.html)
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2.
|
|
6
|
+
The version of the OpenAPI document: 2.26.1
|
|
7
7
|
Contact: developers@flat.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
|
-
|
|
9
|
+
Generator version: 7.24.0
|
|
10
10
|
|
|
11
11
|
=end
|
|
12
12
|
|
|
@@ -15,7 +15,7 @@ require 'time'
|
|
|
15
15
|
|
|
16
16
|
module FlatApi
|
|
17
17
|
# User details
|
|
18
|
-
class UserDetails
|
|
18
|
+
class UserDetails < ApiModelBase
|
|
19
19
|
# The user unique identifier
|
|
20
20
|
attr_accessor :id
|
|
21
21
|
|
|
@@ -73,22 +73,32 @@ module FlatApi
|
|
|
73
73
|
# Number of public scores the user have
|
|
74
74
|
attr_accessor :owned_public_scores_count
|
|
75
75
|
|
|
76
|
+
# Total number of public scores the user participates in (owned + joined)
|
|
77
|
+
attr_accessor :all_public_scores_count
|
|
78
|
+
|
|
79
|
+
# Number of likes on the user published scores
|
|
80
|
+
attr_accessor :likes_count
|
|
81
|
+
|
|
82
|
+
# Number of plays on the user published scores
|
|
83
|
+
attr_accessor :plays_count
|
|
84
|
+
|
|
76
85
|
# Cover picture (backgroud) for the profile
|
|
77
86
|
attr_accessor :cover_picture
|
|
78
87
|
|
|
79
88
|
# Theme (background) for the profile
|
|
80
89
|
attr_accessor :profile_theme
|
|
81
90
|
|
|
82
|
-
# An array of the instrument identifiers. The format of the strings is `{instrument-group}.{instrument-id}`.
|
|
83
|
-
attr_accessor :instruments
|
|
84
|
-
|
|
85
91
|
attr_accessor :links
|
|
86
92
|
|
|
93
|
+
# Whether the user's email address has been verified
|
|
94
|
+
attr_accessor :is_email_verified
|
|
95
|
+
|
|
87
96
|
attr_accessor :azure_details
|
|
88
97
|
|
|
89
98
|
# Tell either this user profile is private or not (individual accounts only)
|
|
90
99
|
attr_accessor :private_profile
|
|
91
100
|
|
|
101
|
+
# The user language. Input values will be automatically normalized to a supported locale code. Unknown locales will default to `en`. Current supported locales include: `da`, `de`, `en`, `en-GB`, `es`, `fi`, `fil`, `fr`, `fr-CA`, `hi`, `id`, `it`, `ja`, `ja-HIRA`, `ko`, `ms`, `nb`, `nl`, `pl`, `pt`, `pt-BR`, `ro`, `ru`, `sv`, `tr`, `zh-Hans`, `zh-HK`, `zh-TW`
|
|
92
102
|
attr_accessor :locale
|
|
93
103
|
|
|
94
104
|
# For Flat for Education accounts, list of Group identifiers the user is part of.
|
|
@@ -145,10 +155,13 @@ module FlatApi
|
|
|
145
155
|
:'followers_count' => :'followersCount',
|
|
146
156
|
:'following_count' => :'followingCount',
|
|
147
157
|
:'owned_public_scores_count' => :'ownedPublicScoresCount',
|
|
158
|
+
:'all_public_scores_count' => :'allPublicScoresCount',
|
|
159
|
+
:'likes_count' => :'likesCount',
|
|
160
|
+
:'plays_count' => :'playsCount',
|
|
148
161
|
:'cover_picture' => :'coverPicture',
|
|
149
162
|
:'profile_theme' => :'profileTheme',
|
|
150
|
-
:'instruments' => :'instruments',
|
|
151
163
|
:'links' => :'links',
|
|
164
|
+
:'is_email_verified' => :'isEmailVerified',
|
|
152
165
|
:'azure_details' => :'azureDetails',
|
|
153
166
|
:'private_profile' => :'privateProfile',
|
|
154
167
|
:'locale' => :'locale',
|
|
@@ -158,9 +171,14 @@ module FlatApi
|
|
|
158
171
|
}
|
|
159
172
|
end
|
|
160
173
|
|
|
174
|
+
# Returns attribute mapping this model knows about
|
|
175
|
+
def self.acceptable_attribute_map
|
|
176
|
+
attribute_map
|
|
177
|
+
end
|
|
178
|
+
|
|
161
179
|
# Returns all the JSON keys this model knows about
|
|
162
180
|
def self.acceptable_attributes
|
|
163
|
-
|
|
181
|
+
acceptable_attribute_map.values
|
|
164
182
|
end
|
|
165
183
|
|
|
166
184
|
# Attribute type mapping.
|
|
@@ -186,13 +204,16 @@ module FlatApi
|
|
|
186
204
|
:'followers_count' => :'Integer',
|
|
187
205
|
:'following_count' => :'Integer',
|
|
188
206
|
:'owned_public_scores_count' => :'Integer',
|
|
207
|
+
:'all_public_scores_count' => :'Integer',
|
|
208
|
+
:'likes_count' => :'Integer',
|
|
209
|
+
:'plays_count' => :'Integer',
|
|
189
210
|
:'cover_picture' => :'String',
|
|
190
211
|
:'profile_theme' => :'String',
|
|
191
|
-
:'instruments' => :'Array<String>',
|
|
192
212
|
:'links' => :'UserCommunityProfileLinks',
|
|
213
|
+
:'is_email_verified' => :'Boolean',
|
|
193
214
|
:'azure_details' => :'UserAzureDetails',
|
|
194
215
|
:'private_profile' => :'Boolean',
|
|
195
|
-
:'locale' => :'
|
|
216
|
+
:'locale' => :'String',
|
|
196
217
|
:'groups' => :'Array<String>',
|
|
197
218
|
:'picture_file' => :'String',
|
|
198
219
|
:'cover_picture_file' => :'String'
|
|
@@ -202,8 +223,6 @@ module FlatApi
|
|
|
202
223
|
# List of attributes with nullable: true
|
|
203
224
|
def self.openapi_nullable
|
|
204
225
|
Set.new([
|
|
205
|
-
:'picture',
|
|
206
|
-
:'cover_picture',
|
|
207
226
|
:'picture_file',
|
|
208
227
|
:'cover_picture_file'
|
|
209
228
|
])
|
|
@@ -224,9 +243,10 @@ module FlatApi
|
|
|
224
243
|
end
|
|
225
244
|
|
|
226
245
|
# check to see if the attribute exists and convert string to symbol for hash key
|
|
246
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
227
247
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
228
|
-
if (!
|
|
229
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `FlatApi::UserDetails`. Please check the name to make sure it's valid. List of attributes: " +
|
|
248
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
249
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `FlatApi::UserDetails`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
230
250
|
end
|
|
231
251
|
h[k.to_sym] = v
|
|
232
252
|
}
|
|
@@ -323,6 +343,18 @@ module FlatApi
|
|
|
323
343
|
self.owned_public_scores_count = attributes[:'owned_public_scores_count']
|
|
324
344
|
end
|
|
325
345
|
|
|
346
|
+
if attributes.key?(:'all_public_scores_count')
|
|
347
|
+
self.all_public_scores_count = attributes[:'all_public_scores_count']
|
|
348
|
+
end
|
|
349
|
+
|
|
350
|
+
if attributes.key?(:'likes_count')
|
|
351
|
+
self.likes_count = attributes[:'likes_count']
|
|
352
|
+
end
|
|
353
|
+
|
|
354
|
+
if attributes.key?(:'plays_count')
|
|
355
|
+
self.plays_count = attributes[:'plays_count']
|
|
356
|
+
end
|
|
357
|
+
|
|
326
358
|
if attributes.key?(:'cover_picture')
|
|
327
359
|
self.cover_picture = attributes[:'cover_picture']
|
|
328
360
|
end
|
|
@@ -331,16 +363,14 @@ module FlatApi
|
|
|
331
363
|
self.profile_theme = attributes[:'profile_theme']
|
|
332
364
|
end
|
|
333
365
|
|
|
334
|
-
if attributes.key?(:'instruments')
|
|
335
|
-
if (value = attributes[:'instruments']).is_a?(Array)
|
|
336
|
-
self.instruments = value
|
|
337
|
-
end
|
|
338
|
-
end
|
|
339
|
-
|
|
340
366
|
if attributes.key?(:'links')
|
|
341
367
|
self.links = attributes[:'links']
|
|
342
368
|
end
|
|
343
369
|
|
|
370
|
+
if attributes.key?(:'is_email_verified')
|
|
371
|
+
self.is_email_verified = attributes[:'is_email_verified']
|
|
372
|
+
end
|
|
373
|
+
|
|
344
374
|
if attributes.key?(:'azure_details')
|
|
345
375
|
self.azure_details = attributes[:'azure_details']
|
|
346
376
|
end
|
|
@@ -391,6 +421,10 @@ module FlatApi
|
|
|
391
421
|
invalid_properties.push('invalid value for "username", username cannot be nil.')
|
|
392
422
|
end
|
|
393
423
|
|
|
424
|
+
if @picture.nil?
|
|
425
|
+
invalid_properties.push('invalid value for "picture", picture cannot be nil.')
|
|
426
|
+
end
|
|
427
|
+
|
|
394
428
|
invalid_properties
|
|
395
429
|
end
|
|
396
430
|
|
|
@@ -404,9 +438,20 @@ module FlatApi
|
|
|
404
438
|
return false unless type_validator.valid?(@type)
|
|
405
439
|
return false if @product.nil?
|
|
406
440
|
return false if @username.nil?
|
|
441
|
+
return false if @picture.nil?
|
|
407
442
|
true
|
|
408
443
|
end
|
|
409
444
|
|
|
445
|
+
# Custom attribute writer method with validation
|
|
446
|
+
# @param [Object] id Value to be assigned
|
|
447
|
+
def id=(id)
|
|
448
|
+
if id.nil?
|
|
449
|
+
fail ArgumentError, 'id cannot be nil'
|
|
450
|
+
end
|
|
451
|
+
|
|
452
|
+
@id = id
|
|
453
|
+
end
|
|
454
|
+
|
|
410
455
|
# Custom attribute writer method checking allowed values (enum).
|
|
411
456
|
# @param [Object] type Object to be assigned
|
|
412
457
|
def type=(type)
|
|
@@ -417,6 +462,36 @@ module FlatApi
|
|
|
417
462
|
@type = type
|
|
418
463
|
end
|
|
419
464
|
|
|
465
|
+
# Custom attribute writer method with validation
|
|
466
|
+
# @param [Object] product Value to be assigned
|
|
467
|
+
def product=(product)
|
|
468
|
+
if product.nil?
|
|
469
|
+
fail ArgumentError, 'product cannot be nil'
|
|
470
|
+
end
|
|
471
|
+
|
|
472
|
+
@product = product
|
|
473
|
+
end
|
|
474
|
+
|
|
475
|
+
# Custom attribute writer method with validation
|
|
476
|
+
# @param [Object] username Value to be assigned
|
|
477
|
+
def username=(username)
|
|
478
|
+
if username.nil?
|
|
479
|
+
fail ArgumentError, 'username cannot be nil'
|
|
480
|
+
end
|
|
481
|
+
|
|
482
|
+
@username = username
|
|
483
|
+
end
|
|
484
|
+
|
|
485
|
+
# Custom attribute writer method with validation
|
|
486
|
+
# @param [Object] picture Value to be assigned
|
|
487
|
+
def picture=(picture)
|
|
488
|
+
if picture.nil?
|
|
489
|
+
fail ArgumentError, 'picture cannot be nil'
|
|
490
|
+
end
|
|
491
|
+
|
|
492
|
+
@picture = picture
|
|
493
|
+
end
|
|
494
|
+
|
|
420
495
|
# Checks equality by comparing each attribute.
|
|
421
496
|
# @param [Object] Object to be compared
|
|
422
497
|
def ==(o)
|
|
@@ -442,10 +517,13 @@ module FlatApi
|
|
|
442
517
|
followers_count == o.followers_count &&
|
|
443
518
|
following_count == o.following_count &&
|
|
444
519
|
owned_public_scores_count == o.owned_public_scores_count &&
|
|
520
|
+
all_public_scores_count == o.all_public_scores_count &&
|
|
521
|
+
likes_count == o.likes_count &&
|
|
522
|
+
plays_count == o.plays_count &&
|
|
445
523
|
cover_picture == o.cover_picture &&
|
|
446
524
|
profile_theme == o.profile_theme &&
|
|
447
|
-
instruments == o.instruments &&
|
|
448
525
|
links == o.links &&
|
|
526
|
+
is_email_verified == o.is_email_verified &&
|
|
449
527
|
azure_details == o.azure_details &&
|
|
450
528
|
private_profile == o.private_profile &&
|
|
451
529
|
locale == o.locale &&
|
|
@@ -463,7 +541,7 @@ module FlatApi
|
|
|
463
541
|
# Calculates hash code according to all attributes.
|
|
464
542
|
# @return [Integer] Hash code
|
|
465
543
|
def hash
|
|
466
|
-
[id, type, product, username, printable_name, firstname, lastname, name, picture, badges, organization, organization_role, class_role, html_url, bio, registration_date, liked_scores_count, followers_count, following_count, owned_public_scores_count, cover_picture, profile_theme,
|
|
544
|
+
[id, type, product, username, printable_name, firstname, lastname, name, picture, badges, organization, organization_role, class_role, html_url, bio, registration_date, liked_scores_count, followers_count, following_count, owned_public_scores_count, all_public_scores_count, likes_count, plays_count, cover_picture, profile_theme, links, is_email_verified, azure_details, private_profile, locale, groups, picture_file, cover_picture_file].hash
|
|
467
545
|
end
|
|
468
546
|
|
|
469
547
|
# Builds the object from hash
|
|
@@ -489,61 +567,6 @@ module FlatApi
|
|
|
489
567
|
new(transformed_hash)
|
|
490
568
|
end
|
|
491
569
|
|
|
492
|
-
# Deserializes the data based on type
|
|
493
|
-
# @param string type Data type
|
|
494
|
-
# @param string value Value to be deserialized
|
|
495
|
-
# @return [Object] Deserialized data
|
|
496
|
-
def self._deserialize(type, value)
|
|
497
|
-
case type.to_sym
|
|
498
|
-
when :Time
|
|
499
|
-
Time.parse(value)
|
|
500
|
-
when :Date
|
|
501
|
-
Date.parse(value)
|
|
502
|
-
when :String
|
|
503
|
-
value.to_s
|
|
504
|
-
when :Integer
|
|
505
|
-
value.to_i
|
|
506
|
-
when :Float
|
|
507
|
-
value.to_f
|
|
508
|
-
when :Boolean
|
|
509
|
-
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
510
|
-
true
|
|
511
|
-
else
|
|
512
|
-
false
|
|
513
|
-
end
|
|
514
|
-
when :Object
|
|
515
|
-
# generic object (usually a Hash), return directly
|
|
516
|
-
value
|
|
517
|
-
when /\AArray<(?<inner_type>.+)>\z/
|
|
518
|
-
inner_type = Regexp.last_match[:inner_type]
|
|
519
|
-
value.map { |v| _deserialize(inner_type, v) }
|
|
520
|
-
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
521
|
-
k_type = Regexp.last_match[:k_type]
|
|
522
|
-
v_type = Regexp.last_match[:v_type]
|
|
523
|
-
{}.tap do |hash|
|
|
524
|
-
value.each do |k, v|
|
|
525
|
-
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
526
|
-
end
|
|
527
|
-
end
|
|
528
|
-
else # model
|
|
529
|
-
# models (e.g. Pet) or oneOf
|
|
530
|
-
klass = FlatApi.const_get(type)
|
|
531
|
-
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
|
532
|
-
end
|
|
533
|
-
end
|
|
534
|
-
|
|
535
|
-
# Returns the string representation of the object
|
|
536
|
-
# @return [String] String presentation of the object
|
|
537
|
-
def to_s
|
|
538
|
-
to_hash.to_s
|
|
539
|
-
end
|
|
540
|
-
|
|
541
|
-
# to_body is an alias to to_hash (backward compatibility)
|
|
542
|
-
# @return [Hash] Returns the object in the form of hash
|
|
543
|
-
def to_body
|
|
544
|
-
to_hash
|
|
545
|
-
end
|
|
546
|
-
|
|
547
570
|
# Returns the object in the form of hash
|
|
548
571
|
# @return [Hash] Returns the object in the form of hash
|
|
549
572
|
def to_hash
|
|
@@ -560,24 +583,6 @@ module FlatApi
|
|
|
560
583
|
hash
|
|
561
584
|
end
|
|
562
585
|
|
|
563
|
-
# Outputs non-array value in the form of hash
|
|
564
|
-
# For object, use to_hash. Otherwise, just return the value
|
|
565
|
-
# @param [Object] value Any valid value
|
|
566
|
-
# @return [Hash] Returns the value in the form of hash
|
|
567
|
-
def _to_hash(value)
|
|
568
|
-
if value.is_a?(Array)
|
|
569
|
-
value.compact.map { |v| _to_hash(v) }
|
|
570
|
-
elsif value.is_a?(Hash)
|
|
571
|
-
{}.tap do |hash|
|
|
572
|
-
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
573
|
-
end
|
|
574
|
-
elsif value.respond_to? :to_hash
|
|
575
|
-
value.to_hash
|
|
576
|
-
else
|
|
577
|
-
value
|
|
578
|
-
end
|
|
579
|
-
end
|
|
580
|
-
|
|
581
586
|
end
|
|
582
587
|
|
|
583
588
|
end
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#Flat API
|
|
3
3
|
|
|
4
|
-
#The Flat API allows you to easily extend the abilities of the [Flat Platform](https://flat.io), with a wide range of use cases including the following: * Creating and importing new music scores using MusicXML, MIDI, Guitar Pro
|
|
4
|
+
#The Flat API allows you to easily extend the abilities of the [Flat Platform](https://flat.io), with a wide range of use cases including the following: * Creating and importing new music scores using MusicXML, MIDI, Guitar Pro, MuseScore, ABC notation, and many other formats * Browsing, updating, copying, exporting the user's scores (for example in MP3, WAV or MIDI) * Managing educational resources with Flat for Education: creating & updating the organization accounts, the classes, rosters and assignments. The Flat API is built on HTTP. Our API is RESTful It has predictable resource URLs. It returns HTTP response codes to indicate errors. It also accepts and returns JSON in the HTTP body. The [schema](/swagger.yaml) of this API follows the [OpenAPI Initiative (OAI) specification](https://www.openapis.org/), you can use and work with [compatible Swagger tools](http://swagger.io/open-source-integrations/). This API features Cross-Origin Resource Sharing (CORS) implemented in compliance with [W3C spec](https://www.w3.org/TR/cors/). You can use your favorite HTTP/REST library for your programming language to use Flat's API. This specification and reference is [available on Github](https://github.com/FlatIO/api-reference). Getting Started and learn more: * [API Overview and introduction](https://flat.io/developers/docs/api/) * [Authentication (Personal Access Tokens or OAuth2)](https://flat.io/developers/docs/api/authentication.html) * [SDKs](https://flat.io/developers/docs/api/sdks.html) * [Rate Limits](https://flat.io/developers/docs/api/rate-limits.html) * [Changelog](https://flat.io/developers/docs/api/changelog.html)
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 2.
|
|
6
|
+
The version of the OpenAPI document: 2.26.1
|
|
7
7
|
Contact: developers@flat.io
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
|
-
|
|
9
|
+
Generator version: 7.24.0
|
|
10
10
|
|
|
11
11
|
=end
|
|
12
12
|
|
|
@@ -15,7 +15,7 @@ require 'time'
|
|
|
15
15
|
|
|
16
16
|
module FlatApi
|
|
17
17
|
# User details (view for organization teacher / admin)
|
|
18
|
-
class UserDetailsAdmin
|
|
18
|
+
class UserDetailsAdmin < ApiModelBase
|
|
19
19
|
# The user unique identifier
|
|
20
20
|
attr_accessor :id
|
|
21
21
|
|
|
@@ -66,6 +66,9 @@ module FlatApi
|
|
|
66
66
|
# For Flat for Education accounts, list of Group identifiers the user is part of.
|
|
67
67
|
attr_accessor :groups
|
|
68
68
|
|
|
69
|
+
# Indicates if the user account is marked as a testing student account. Testing students are typically excluded from certain educational integrations and workflows. This field helps API clients distinguish between regular students and testing accounts.
|
|
70
|
+
attr_accessor :is_edu_testing_student
|
|
71
|
+
|
|
69
72
|
class EnumAttributeValidator
|
|
70
73
|
attr_reader :datatype
|
|
71
74
|
attr_reader :allowable_values
|
|
@@ -108,13 +111,19 @@ module FlatApi
|
|
|
108
111
|
:'email' => :'email',
|
|
109
112
|
:'last_activity_date' => :'lastActivityDate',
|
|
110
113
|
:'license' => :'license',
|
|
111
|
-
:'groups' => :'groups'
|
|
114
|
+
:'groups' => :'groups',
|
|
115
|
+
:'is_edu_testing_student' => :'isEduTestingStudent'
|
|
112
116
|
}
|
|
113
117
|
end
|
|
114
118
|
|
|
119
|
+
# Returns attribute mapping this model knows about
|
|
120
|
+
def self.acceptable_attribute_map
|
|
121
|
+
attribute_map
|
|
122
|
+
end
|
|
123
|
+
|
|
115
124
|
# Returns all the JSON keys this model knows about
|
|
116
125
|
def self.acceptable_attributes
|
|
117
|
-
|
|
126
|
+
acceptable_attribute_map.values
|
|
118
127
|
end
|
|
119
128
|
|
|
120
129
|
# Attribute type mapping.
|
|
@@ -137,14 +146,14 @@ module FlatApi
|
|
|
137
146
|
:'email' => :'String',
|
|
138
147
|
:'last_activity_date' => :'Time',
|
|
139
148
|
:'license' => :'UserDetailsAdminAllOfLicense',
|
|
140
|
-
:'groups' => :'Array<String>'
|
|
149
|
+
:'groups' => :'Array<String>',
|
|
150
|
+
:'is_edu_testing_student' => :'Boolean'
|
|
141
151
|
}
|
|
142
152
|
end
|
|
143
153
|
|
|
144
154
|
# List of attributes with nullable: true
|
|
145
155
|
def self.openapi_nullable
|
|
146
156
|
Set.new([
|
|
147
|
-
:'picture',
|
|
148
157
|
])
|
|
149
158
|
end
|
|
150
159
|
|
|
@@ -163,9 +172,10 @@ module FlatApi
|
|
|
163
172
|
end
|
|
164
173
|
|
|
165
174
|
# check to see if the attribute exists and convert string to symbol for hash key
|
|
175
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
166
176
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
167
|
-
if (!
|
|
168
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `FlatApi::UserDetailsAdmin`. Please check the name to make sure it's valid. List of attributes: " +
|
|
177
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
178
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `FlatApi::UserDetailsAdmin`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
169
179
|
end
|
|
170
180
|
h[k.to_sym] = v
|
|
171
181
|
}
|
|
@@ -255,6 +265,10 @@ module FlatApi
|
|
|
255
265
|
self.groups = value
|
|
256
266
|
end
|
|
257
267
|
end
|
|
268
|
+
|
|
269
|
+
if attributes.key?(:'is_edu_testing_student')
|
|
270
|
+
self.is_edu_testing_student = attributes[:'is_edu_testing_student']
|
|
271
|
+
end
|
|
258
272
|
end
|
|
259
273
|
|
|
260
274
|
# Show invalid properties with the reasons. Usually used together with valid?
|
|
@@ -278,6 +292,10 @@ module FlatApi
|
|
|
278
292
|
invalid_properties.push('invalid value for "username", username cannot be nil.')
|
|
279
293
|
end
|
|
280
294
|
|
|
295
|
+
if @picture.nil?
|
|
296
|
+
invalid_properties.push('invalid value for "picture", picture cannot be nil.')
|
|
297
|
+
end
|
|
298
|
+
|
|
281
299
|
invalid_properties
|
|
282
300
|
end
|
|
283
301
|
|
|
@@ -291,9 +309,20 @@ module FlatApi
|
|
|
291
309
|
return false unless type_validator.valid?(@type)
|
|
292
310
|
return false if @product.nil?
|
|
293
311
|
return false if @username.nil?
|
|
312
|
+
return false if @picture.nil?
|
|
294
313
|
true
|
|
295
314
|
end
|
|
296
315
|
|
|
316
|
+
# Custom attribute writer method with validation
|
|
317
|
+
# @param [Object] id Value to be assigned
|
|
318
|
+
def id=(id)
|
|
319
|
+
if id.nil?
|
|
320
|
+
fail ArgumentError, 'id cannot be nil'
|
|
321
|
+
end
|
|
322
|
+
|
|
323
|
+
@id = id
|
|
324
|
+
end
|
|
325
|
+
|
|
297
326
|
# Custom attribute writer method checking allowed values (enum).
|
|
298
327
|
# @param [Object] type Object to be assigned
|
|
299
328
|
def type=(type)
|
|
@@ -304,6 +333,36 @@ module FlatApi
|
|
|
304
333
|
@type = type
|
|
305
334
|
end
|
|
306
335
|
|
|
336
|
+
# Custom attribute writer method with validation
|
|
337
|
+
# @param [Object] product Value to be assigned
|
|
338
|
+
def product=(product)
|
|
339
|
+
if product.nil?
|
|
340
|
+
fail ArgumentError, 'product cannot be nil'
|
|
341
|
+
end
|
|
342
|
+
|
|
343
|
+
@product = product
|
|
344
|
+
end
|
|
345
|
+
|
|
346
|
+
# Custom attribute writer method with validation
|
|
347
|
+
# @param [Object] username Value to be assigned
|
|
348
|
+
def username=(username)
|
|
349
|
+
if username.nil?
|
|
350
|
+
fail ArgumentError, 'username cannot be nil'
|
|
351
|
+
end
|
|
352
|
+
|
|
353
|
+
@username = username
|
|
354
|
+
end
|
|
355
|
+
|
|
356
|
+
# Custom attribute writer method with validation
|
|
357
|
+
# @param [Object] picture Value to be assigned
|
|
358
|
+
def picture=(picture)
|
|
359
|
+
if picture.nil?
|
|
360
|
+
fail ArgumentError, 'picture cannot be nil'
|
|
361
|
+
end
|
|
362
|
+
|
|
363
|
+
@picture = picture
|
|
364
|
+
end
|
|
365
|
+
|
|
307
366
|
# Checks equality by comparing each attribute.
|
|
308
367
|
# @param [Object] Object to be compared
|
|
309
368
|
def ==(o)
|
|
@@ -326,7 +385,8 @@ module FlatApi
|
|
|
326
385
|
email == o.email &&
|
|
327
386
|
last_activity_date == o.last_activity_date &&
|
|
328
387
|
license == o.license &&
|
|
329
|
-
groups == o.groups
|
|
388
|
+
groups == o.groups &&
|
|
389
|
+
is_edu_testing_student == o.is_edu_testing_student
|
|
330
390
|
end
|
|
331
391
|
|
|
332
392
|
# @see the `==` method
|
|
@@ -338,7 +398,7 @@ module FlatApi
|
|
|
338
398
|
# Calculates hash code according to all attributes.
|
|
339
399
|
# @return [Integer] Hash code
|
|
340
400
|
def hash
|
|
341
|
-
[id, type, product, username, printable_name, firstname, lastname, name, picture, badges, organization, organization_role, class_role, html_url, email, last_activity_date, license, groups].hash
|
|
401
|
+
[id, type, product, username, printable_name, firstname, lastname, name, picture, badges, organization, organization_role, class_role, html_url, email, last_activity_date, license, groups, is_edu_testing_student].hash
|
|
342
402
|
end
|
|
343
403
|
|
|
344
404
|
# Builds the object from hash
|
|
@@ -364,61 +424,6 @@ module FlatApi
|
|
|
364
424
|
new(transformed_hash)
|
|
365
425
|
end
|
|
366
426
|
|
|
367
|
-
# Deserializes the data based on type
|
|
368
|
-
# @param string type Data type
|
|
369
|
-
# @param string value Value to be deserialized
|
|
370
|
-
# @return [Object] Deserialized data
|
|
371
|
-
def self._deserialize(type, value)
|
|
372
|
-
case type.to_sym
|
|
373
|
-
when :Time
|
|
374
|
-
Time.parse(value)
|
|
375
|
-
when :Date
|
|
376
|
-
Date.parse(value)
|
|
377
|
-
when :String
|
|
378
|
-
value.to_s
|
|
379
|
-
when :Integer
|
|
380
|
-
value.to_i
|
|
381
|
-
when :Float
|
|
382
|
-
value.to_f
|
|
383
|
-
when :Boolean
|
|
384
|
-
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
385
|
-
true
|
|
386
|
-
else
|
|
387
|
-
false
|
|
388
|
-
end
|
|
389
|
-
when :Object
|
|
390
|
-
# generic object (usually a Hash), return directly
|
|
391
|
-
value
|
|
392
|
-
when /\AArray<(?<inner_type>.+)>\z/
|
|
393
|
-
inner_type = Regexp.last_match[:inner_type]
|
|
394
|
-
value.map { |v| _deserialize(inner_type, v) }
|
|
395
|
-
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
396
|
-
k_type = Regexp.last_match[:k_type]
|
|
397
|
-
v_type = Regexp.last_match[:v_type]
|
|
398
|
-
{}.tap do |hash|
|
|
399
|
-
value.each do |k, v|
|
|
400
|
-
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
401
|
-
end
|
|
402
|
-
end
|
|
403
|
-
else # model
|
|
404
|
-
# models (e.g. Pet) or oneOf
|
|
405
|
-
klass = FlatApi.const_get(type)
|
|
406
|
-
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
|
407
|
-
end
|
|
408
|
-
end
|
|
409
|
-
|
|
410
|
-
# Returns the string representation of the object
|
|
411
|
-
# @return [String] String presentation of the object
|
|
412
|
-
def to_s
|
|
413
|
-
to_hash.to_s
|
|
414
|
-
end
|
|
415
|
-
|
|
416
|
-
# to_body is an alias to to_hash (backward compatibility)
|
|
417
|
-
# @return [Hash] Returns the object in the form of hash
|
|
418
|
-
def to_body
|
|
419
|
-
to_hash
|
|
420
|
-
end
|
|
421
|
-
|
|
422
427
|
# Returns the object in the form of hash
|
|
423
428
|
# @return [Hash] Returns the object in the form of hash
|
|
424
429
|
def to_hash
|
|
@@ -435,24 +440,6 @@ module FlatApi
|
|
|
435
440
|
hash
|
|
436
441
|
end
|
|
437
442
|
|
|
438
|
-
# Outputs non-array value in the form of hash
|
|
439
|
-
# For object, use to_hash. Otherwise, just return the value
|
|
440
|
-
# @param [Object] value Any valid value
|
|
441
|
-
# @return [Hash] Returns the value in the form of hash
|
|
442
|
-
def _to_hash(value)
|
|
443
|
-
if value.is_a?(Array)
|
|
444
|
-
value.compact.map { |v| _to_hash(v) }
|
|
445
|
-
elsif value.is_a?(Hash)
|
|
446
|
-
{}.tap do |hash|
|
|
447
|
-
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
448
|
-
end
|
|
449
|
-
elsif value.respond_to? :to_hash
|
|
450
|
-
value.to_hash
|
|
451
|
-
else
|
|
452
|
-
value
|
|
453
|
-
end
|
|
454
|
-
end
|
|
455
|
-
|
|
456
443
|
end
|
|
457
444
|
|
|
458
445
|
end
|