zyphr 0.1.32 → 0.1.33

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.
Files changed (74) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +41 -0
  3. data/docs/AddOrganizationMemberRequest.md +20 -0
  4. data/docs/AuthOrganizationsApi.md +864 -0
  5. data/docs/AuthUserProfileApi.md +76 -0
  6. data/docs/CreateOrganizationRequest.md +22 -0
  7. data/docs/LoginRequest.md +3 -1
  8. data/docs/MuseApi.md +681 -0
  9. data/docs/Organization.md +34 -0
  10. data/docs/OrganizationListResponse.md +20 -0
  11. data/docs/OrganizationListResponseMeta.md +20 -0
  12. data/docs/OrganizationMembersListResponse.md +20 -0
  13. data/docs/OrganizationMembership.md +30 -0
  14. data/docs/OrganizationMembershipResponse.md +20 -0
  15. data/docs/OrganizationMembershipWithUser.md +34 -0
  16. data/docs/OrganizationResponse.md +20 -0
  17. data/docs/RegisterRequest.md +5 -1
  18. data/docs/SwitchOrganizationRequest.md +20 -0
  19. data/docs/SwitchOrganizationResponse.md +20 -0
  20. data/docs/SwitchOrganizationResponseData.md +22 -0
  21. data/docs/SwitchOrganizationResponseDataTokens.md +24 -0
  22. data/docs/SwitchOrganizationResponseDataUser.md +20 -0
  23. data/docs/UpdateOrganizationMemberRoleRequest.md +18 -0
  24. data/docs/UpdateOrganizationRequest.md +22 -0
  25. data/docs/V1MuseSubjectsSuggestPostRequest.md +24 -0
  26. data/lib/zyphr/api/auth_organizations_api.rb +773 -0
  27. data/lib/zyphr/api/auth_user_profile_api.rb +61 -0
  28. data/lib/zyphr/api/muse_api.rb +644 -0
  29. data/lib/zyphr/models/add_organization_member_request.rb +248 -0
  30. data/lib/zyphr/models/create_organization_request.rb +258 -0
  31. data/lib/zyphr/models/login_request.rb +14 -4
  32. data/lib/zyphr/models/organization.rb +434 -0
  33. data/lib/zyphr/models/organization_list_response.rb +265 -0
  34. data/lib/zyphr/models/organization_list_response_meta.rb +230 -0
  35. data/lib/zyphr/models/organization_members_list_response.rb +265 -0
  36. data/lib/zyphr/models/organization_membership.rb +379 -0
  37. data/lib/zyphr/models/organization_membership_response.rb +263 -0
  38. data/lib/zyphr/models/organization_membership_with_user.rb +405 -0
  39. data/lib/zyphr/models/organization_response.rb +263 -0
  40. data/lib/zyphr/models/register_request.rb +43 -4
  41. data/lib/zyphr/models/switch_organization_request.rb +263 -0
  42. data/lib/zyphr/models/switch_organization_response.rb +263 -0
  43. data/lib/zyphr/models/switch_organization_response_data.rb +289 -0
  44. data/lib/zyphr/models/switch_organization_response_data_tokens.rb +339 -0
  45. data/lib/zyphr/models/switch_organization_response_data_user.rb +230 -0
  46. data/lib/zyphr/models/update_organization_member_role_request.rb +223 -0
  47. data/lib/zyphr/models/update_organization_request.rb +239 -0
  48. data/lib/zyphr/models/v1_muse_subjects_suggest_post_request.rb +326 -0
  49. data/lib/zyphr.rb +20 -0
  50. data/spec/api/auth_organizations_api_spec.rb +171 -0
  51. data/spec/api/auth_user_profile_api_spec.rb +12 -0
  52. data/spec/api/muse_api_spec.rb +156 -0
  53. data/spec/models/add_organization_member_request_spec.rb +42 -0
  54. data/spec/models/create_organization_request_spec.rb +48 -0
  55. data/spec/models/login_request_spec.rb +6 -0
  56. data/spec/models/organization_list_response_meta_spec.rb +42 -0
  57. data/spec/models/organization_list_response_spec.rb +42 -0
  58. data/spec/models/organization_members_list_response_spec.rb +42 -0
  59. data/spec/models/organization_membership_response_spec.rb +42 -0
  60. data/spec/models/organization_membership_spec.rb +72 -0
  61. data/spec/models/organization_membership_with_user_spec.rb +84 -0
  62. data/spec/models/organization_response_spec.rb +42 -0
  63. data/spec/models/organization_spec.rb +84 -0
  64. data/spec/models/register_request_spec.rb +12 -0
  65. data/spec/models/switch_organization_request_spec.rb +42 -0
  66. data/spec/models/switch_organization_response_data_spec.rb +48 -0
  67. data/spec/models/switch_organization_response_data_tokens_spec.rb +58 -0
  68. data/spec/models/switch_organization_response_data_user_spec.rb +42 -0
  69. data/spec/models/switch_organization_response_spec.rb +42 -0
  70. data/spec/models/update_organization_member_role_request_spec.rb +36 -0
  71. data/spec/models/update_organization_request_spec.rb +48 -0
  72. data/spec/models/v1_muse_subjects_suggest_post_request_spec.rb +58 -0
  73. data/zyphr.gemspec +1 -1
  74. metadata +82 -2
@@ -76,6 +76,67 @@ module Zyphr
76
76
  return data, status_code, headers
77
77
  end
78
78
 
79
+ # Delete an end user (test environment only)
80
+ # App-credentialed soft-delete for an end user, scoped to the test environment only. Live-mode credentials receive 403 — this is the intentional safety guard against a misconfigured CI runner nuking production users. Mirrors the self-service `DELETE /auth/users/me` flow: revokes all sessions, soft-deletes the row (status='deleted'), and emits a `user.deleted` webhook with `method='application_admin'`. The audit log row survives (no FK to end_users), so org-history queries still resolve. Intended for smoke / test-fixture cleanup. Production deletes should continue to use `DELETE /auth/users/me` from the end-user's own session or the dashboard.
81
+ # @param user_id [String]
82
+ # @param [Hash] opts the optional parameters
83
+ # @return [nil]
84
+ def delete_end_user_by_application(user_id, opts = {})
85
+ delete_end_user_by_application_with_http_info(user_id, opts)
86
+ nil
87
+ end
88
+
89
+ # Delete an end user (test environment only)
90
+ # App-credentialed soft-delete for an end user, scoped to the test environment only. Live-mode credentials receive 403 — this is the intentional safety guard against a misconfigured CI runner nuking production users. Mirrors the self-service `DELETE /auth/users/me` flow: revokes all sessions, soft-deletes the row (status='deleted'), and emits a `user.deleted` webhook with `method='application_admin'`. The audit log row survives (no FK to end_users), so org-history queries still resolve. Intended for smoke / test-fixture cleanup. Production deletes should continue to use `DELETE /auth/users/me` from the end-user's own session or the dashboard.
91
+ # @param user_id [String]
92
+ # @param [Hash] opts the optional parameters
93
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
94
+ def delete_end_user_by_application_with_http_info(user_id, opts = {})
95
+ if @api_client.config.debugging
96
+ @api_client.config.logger.debug 'Calling API: AuthUserProfileApi.delete_end_user_by_application ...'
97
+ end
98
+ # verify the required parameter 'user_id' is set
99
+ if @api_client.config.client_side_validation && user_id.nil?
100
+ fail ArgumentError, "Missing the required parameter 'user_id' when calling AuthUserProfileApi.delete_end_user_by_application"
101
+ end
102
+ # resource path
103
+ local_var_path = '/auth/users/{user_id}'.sub('{' + 'user_id' + '}', CGI.escape(user_id.to_s))
104
+
105
+ # query parameters
106
+ query_params = opts[:query_params] || {}
107
+
108
+ # header parameters
109
+ header_params = opts[:header_params] || {}
110
+
111
+ # form parameters
112
+ form_params = opts[:form_params] || {}
113
+
114
+ # http body (model)
115
+ post_body = opts[:debug_body]
116
+
117
+ # return_type
118
+ return_type = opts[:debug_return_type]
119
+
120
+ # auth_names
121
+ auth_names = opts[:debug_auth_names] || ['ApplicationSecret', 'ApplicationPublicKey']
122
+
123
+ new_options = opts.merge(
124
+ :operation => :"AuthUserProfileApi.delete_end_user_by_application",
125
+ :header_params => header_params,
126
+ :query_params => query_params,
127
+ :form_params => form_params,
128
+ :body => post_body,
129
+ :auth_names => auth_names,
130
+ :return_type => return_type
131
+ )
132
+
133
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
134
+ if @api_client.config.debugging
135
+ @api_client.config.logger.debug "API called: AuthUserProfileApi#delete_end_user_by_application\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
136
+ end
137
+ return data, status_code, headers
138
+ end
139
+
79
140
  # Get current end user profile
80
141
  # Retrieve the profile of the currently authenticated end user.
81
142
  # @param [Hash] opts the optional parameters