diff --git a/CHANGELOG.md b/CHANGELOG.md index 4096cf1b..b2c18128 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,7 @@ * Added Workspaces resource for managing workspaces, auto-grouping, manual assignment, `default`, `policy_id`, and `rule_ids` * Added Domains resource and `ServiceAccountSigner` support for signed Service Account Manage Domains requests, including canonical signed bodies, encoded domain paths, info, and verify operations * Added Applications update support (PATCH /v3/applications) +* Documented Applications update `callback_uris` ID preservation and Workspaces `auto_group` filters * Corrected RedirectUris update verb from PUT to PATCH * Fixed HTTParty content type issue when request body is nil - POST, PUT, PATCH, and DELETE now default to empty object to ensure Content-Type: application/json is sent (#536) * Added support for request_body parameter on DELETE (e.g. cancellation_reason for bookings) (#536) diff --git a/lib/nylas/resources/applications.rb b/lib/nylas/resources/applications.rb index 245a4be9..1d2e1f9a 100644 --- a/lib/nylas/resources/applications.rb +++ b/lib/nylas/resources/applications.rb @@ -27,7 +27,9 @@ def get_details # Update application details. # - # @param request_body [Hash] The values to update the application with. + # @param request_body [Hash] The values to update the application with. Include + # +callback_uris+ entries with +id+ when preserving or updating existing + # callback URIs. # @return [Array(Hash, String)] The updated application details and API Request ID. def update(request_body:) patch( diff --git a/lib/nylas/resources/workspaces.rb b/lib/nylas/resources/workspaces.rb index 254a4ecb..a679d0e8 100644 --- a/lib/nylas/resources/workspaces.rb +++ b/lib/nylas/resources/workspaces.rb @@ -83,7 +83,8 @@ def destroy(workspace_id:) # Runs as a background job and returns immediately with a job ID. Rate limited to one # call per minute per application. # - # @param request_body [Hash] Optional filters to scope which grants are grouped. + # @param request_body [Hash] Optional filters to scope which grants are grouped, + # including +after_created_at+, +invalid_also+, and +specific_domain+. # @return [Array(Hash, String, Hash)] The job info, API Request ID, and response headers. def auto_group(request_body: nil) post( diff --git a/spec/nylas/resources/applications_spec.rb b/spec/nylas/resources/applications_spec.rb index 2ebce8f0..b9e88a16 100644 --- a/spec/nylas/resources/applications_spec.rb +++ b/spec/nylas/resources/applications_spec.rb @@ -77,7 +77,14 @@ subtitle: "string", background_color: "#003400", spacing: 5 - } + }, + callback_uris: [ + { + id: "0556d035-6cb6-4262-a035-6b77e11cf8fc", + url: "https://example.com/callback", + platform: "web" + } + ] } path = "#{api_uri}/v3/applications" allow(application).to receive(:patch)