Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.
TypeScript agentaiai-agentsall-in-onecrmcrm-systememaillinearmcpmessagingnotesnotionofficerustslackslack-alternativestartupstartup-toolstypescriptworkspace
chore: bump axum (#1839)
Sean Ayefe6d07835146
diff --git a/js/app/packages/service-clients/service-notification/generated/client.ts b/js/app/packages/service-clients/service-notification/generated/client.tsindex 2565a6fcd9..09e74a1af6 100644--- a/js/app/packages/service-clients/service-notification/generated/client.ts+++ b/js/app/packages/service-clients/service-notification/generated/client.ts@@ -193,14 +193,16 @@ export type unsubscribeItemResponse =| unsubscribeItemResponseSuccess| unsubscribeItemResponseError;-export const getUnsubscribeItemUrl = () => {- return `/unsubscribe/item/:item_type/:item_id`;+export const getUnsubscribeItemUrl = (itemType: string, itemId: string) => {+ return `/unsubscribe/item/${itemType}/${itemId}`;};export const unsubscribeItem = async (+ itemType: string,+ itemId: string,options?: RequestInit): Promise<unsubscribeItemResponse> => {- const res = await fetch(getUnsubscribeItemUrl(), {+ const res = await fetch(getUnsubscribeItemUrl(itemType, itemId), {...options,method: 'POST',});@@ -248,14 +250,19 @@ export type removeUnsubscribeItemResponse =| removeUnsubscribeItemResponseSuccess| removeUnsubscribeItemResponseError;-export const getRemoveUnsubscribeItemUrl = () => {- return `/unsubscribe/item/:item_type/:item_id`;+export const getRemoveUnsubscribeItemUrl = (+ itemType: string,+ itemId: string+) => {+ return `/unsubscribe/item/${itemType}/${itemId}`;};export const removeUnsubscribeItem = async (+ itemType: string,+ itemId: string,options?: RequestInit): Promise<removeUnsubscribeItemResponse> => {- const res = await fetch(getRemoveUnsubscribeItemUrl(), {+ const res = await fetch(getRemoveUnsubscribeItemUrl(itemType, itemId), {...options,method: 'DELETE',});diff --git a/js/app/packages/service-clients/service-notification/openapi.json b/js/app/packages/service-clients/service-notification/openapi.jsonindex 1928c53ccd..aebf0cfcea 100644--- a/js/app/packages/service-clients/service-notification/openapi.json+++ b/js/app/packages/service-clients/service-notification/openapi.json@@ -110,11 +110,29 @@}}},- "/unsubscribe/item/:item_type/:item_id": {+ "/unsubscribe/item/{item_type}/{item_id}": {"post": {"tags": ["unsubscribe::unsubscribe_item"],"summary": "Unsubscribes a user from a given item for notifications.","operationId": "unsubscribe_item",+ "parameters": [+ {+ "name": "item_type",+ "in": "path",+ "required": true,+ "schema": {+ "type": "string"+ }+ },+ {+ "name": "item_id",+ "in": "path",+ "required": true,+ "schema": {+ "type": "string"+ }+ }+ ],"responses": {"200": {"description": "",@@ -152,6 +170,24 @@"tags": ["unsubscribe::remove_unsubscribe_item"],"summary": "Removes a unsubscribe item for a user.","operationId": "remove_unsubscribe_item",+ "parameters": [+ {+ "name": "item_type",+ "in": "path",+ "required": true,+ "schema": {+ "type": "string"+ }+ },+ {+ "name": "item_id",+ "in": "path",+ "required": true,+ "schema": {+ "type": "string"+ }+ }+ ],"responses": {"200": {"description": "",diff --git a/js/app/packages/service-clients/service-storage/generated/zod.ts b/js/app/packages/service-clients/service-storage/generated/zod.tsindex 5611fe951b..2e3e3c34be 100644--- a/js/app/packages/service-clients/service-storage/generated/zod.ts+++ b/js/app/packages/service-clients/service-storage/generated/zod.ts@@ -296,6 +296,81 @@ export const editAnchorResponse = zod}));+/**+ * @summary Gets a set of comment anchors for a document+ */+export const getDocumentAnchorsParams = zod.object({+ document_id: zod.string().describe('Document ID'),+});++export const getDocumentAnchorsResponse = zod.object({+ data: zod.array(+ zod.union([+ zod+ .object({+ allowableEdits: zod.any().optional(),+ documentId: zod.string(),+ heightPct: zod.number(),+ originalIndex: zod.number(),+ originalPage: zod.number(),+ owner: zod.string(),+ page: zod.number(),+ rotation: zod.number(),+ shouldLockOnSave: zod.boolean(),+ threadId: zod.number(),+ uuid: zod.string().uuid(),+ wasDeleted: zod.boolean(),+ wasEdited: zod.boolean(),+ widthPct: zod.number(),+ xPct: zod.number(),+ yPct: zod.number(),+ })+ .and(+ zod.object({+ anchorType: zod.enum(['placeable']),+ })+ ),+ zod+ .object({+ alpha: zod.number(),+ blue: zod.number(),+ createdAt: zod.string().datetime({}).nullish(),+ deletedAt: zod.string().datetime({}).nullish(),+ documentId: zod.string(),+ green: zod.number(),+ highlightRects: zod.array(+ zod.object({+ height: zod.number(),+ id: zod.number(),+ left: zod.number(),+ top: zod.number(),+ width: zod.number(),+ })+ ),+ highlightType: zod.union([+ zod.literal(1),+ zod.literal(2),+ zod.literal(3),+ ]),+ owner: zod.string(),+ page: zod.number(),+ pageViewportHeight: zod.number(),+ pageViewportWidth: zod.number(),+ red: zod.number(),+ text: zod.string(),+ threadId: zod.number().nullish(),+ updatedAt: zod.string().datetime({}).nullish(),+ uuid: zod.string().uuid(),+ })+ .and(+ zod.object({+ anchorType: zod.enum(['highlight']),+ })+ ),+ ])+ ),+});+/*** @summary Creates an unthreaded anchor for a documentIf you need to create a threaded anchor, see the create comment handler@@ -406,81 +481,6 @@ export const createAnchorResponse = zod}));-/**- * @summary Gets a set of comment anchors for a document- */-export const getDocumentAnchorsParams = zod.object({- document_id: zod.string().describe('Document ID'),-});--export const getDocumentAnchorsResponse = zod.object({- data: zod.array(- zod.union([- zod- .object({- allowableEdits: zod.any().optional(),- documentId: zod.string(),- heightPct: zod.number(),- originalIndex: zod.number(),- originalPage: zod.number(),- owner: zod.string(),- page: zod.number(),- rotation: zod.number(),- shouldLockOnSave: zod.boolean(),- threadId: zod.number(),- uuid: zod.string().uuid(),- wasDeleted: zod.boolean(),- wasEdited: zod.boolean(),- widthPct: zod.number(),- xPct: zod.number(),- yPct: zod.number(),- })- .and(- zod.object({- anchorType: zod.enum(['placeable']),- })- ),- zod- .object({- alpha: zod.number(),- blue: zod.number(),- createdAt: zod.string().datetime({}).nullish(),- deletedAt: zod.string().datetime({}).nullish(),- documentId: zod.string(),- green: zod.number(),- highlightRects: zod.array(- zod.object({- height: zod.number(),- id: zod.number(),- left: zod.number(),- top: zod.number(),- width: zod.number(),- })- ),- highlightType: zod.union([- zod.literal(1),- zod.literal(2),- zod.literal(3),- ]),- owner: zod.string(),- page: zod.number(),- pageViewportHeight: zod.number(),- pageViewportWidth: zod.number(),- red: zod.number(),- text: zod.string(),- threadId: zod.number().nullish(),- updatedAt: zod.string().datetime({}).nullish(),- uuid: zod.string().uuid(),- })- .and(- zod.object({- anchorType: zod.enum(['highlight']),- })- ),- ])- ),-});-/*** @summary Deletes a single comment for a document*/@@ -573,6 +573,44 @@ export const editCommentResponse = zod}));+/**+ * @summary Gets a set of comment threads for a document+ */+export const getDocumentCommentsParams = zod.object({+ document_id: zod.string().describe('Document ID'),+});++export const getDocumentCommentsResponse = zod.object({+ data: zod.array(+ zod.object({+ comments: zod.array(+ zod.object({+ commentId: zod.number(),+ createdAt: zod.string().datetime({}).nullish(),+ deletedAt: zod.string().datetime({}).nullish(),+ metadata: zod.any().optional(),+ order: zod.number().nullish(),+ owner: zod.string(),+ sender: zod.string().nullish(),+ text: zod.string(),+ threadId: zod.number(),+ updatedAt: zod.string().datetime({}).nullish(),+ })+ ),+ thread: zod.object({+ createdAt: zod.string().datetime({}).nullish(),+ deletedAt: zod.string().datetime({}).nullish(),+ documentId: zod.string(),+ metadata: zod.any().optional(),+ owner: zod.string(),+ resolved: zod.boolean(),+ threadId: zod.number(),+ updatedAt: zod.string().datetime({}).nullish(),+ }),+ })+ ),+});+/*** @summary Creates a single comment for a documentOptionally creates a new thread/anchor if one does not exist@@ -773,45 +811,7 @@ export const createCommentResponse = zod);/**- * @summary Gets a set of comment threads for a document- */-export const getDocumentCommentsParams = zod.object({- document_id: zod.string().describe('Document ID'),-});--export const getDocumentCommentsResponse = zod.object({- data: zod.array(- zod.object({- comments: zod.array(- zod.object({- commentId: zod.number(),- createdAt: zod.string().datetime({}).nullish(),- deletedAt: zod.string().datetime({}).nullish(),- metadata: zod.any().optional(),- order: zod.number().nullish(),- owner: zod.string(),- sender: zod.string().nullish(),- text: zod.string(),- threadId: zod.number(),- updatedAt: zod.string().datetime({}).nullish(),- })- ),- thread: zod.object({- createdAt: zod.string().datetime({}).nullish(),- deletedAt: zod.string().datetime({}).nullish(),- documentId: zod.string(),- metadata: zod.any().optional(),- owner: zod.string(),- resolved: zod.boolean(),- threadId: zod.number(),- updatedAt: zod.string().datetime({}).nullish(),- }),- })- ),-});--/**- * @summary Handler for `GET /channels/:channel_id/attachments`.+ * @summary Handler for `GET /channels/{channel_id}/attachments`.*/export const getChannelAttachmentsParams = zod.object({channel_id: zod.string().uuid().describe('Channel ID'),@@ -860,7 +860,7 @@ export const getChannelAttachmentsResponse = zod.describe('Paginated response of channel attachments.');/**- * @summary Handler for `GET /channels/:channel_id/messages`.+ * @summary Handler for `GET /channels/{channel_id}/messages`.*/export const getChannelMessagesParams = zod.object({channel_id: zod.string().uuid().describe('Channel ID'),@@ -1030,7 +1030,7 @@ export const getChannelMessagesResponse = zod.describe('Paginated response of channel messages.');/**- * @summary Handler for `GET /channels/:channel_id/messages/:message_id/replies`.+ * @summary Handler for `GET /channels/{channel_id}/messages/{message_id}/replies`.*/export const getThreadRepliesParams = zod.object({channel_id: zod.string().uuid().describe('Channel ID'),@@ -1090,7 +1090,7 @@ export const getThreadRepliesResponseItem = zodexport const getThreadRepliesResponse = zod.array(getThreadRepliesResponseItem);/**- * @summary Handler for `GET /channels/:channel_id/participants`.+ * @summary Handler for `GET /channels/{channel_id}/participants`.*/export const getChannelParticipantsParams = zod.object({channel_id: zod.string().uuid().describe('Channel ID'),@@ -1775,7 +1775,7 @@ export const getBatchPreviewHandlerResponse = zod.object({/*** Returns document metadata, user access level, and view location.- * @summary Handler for `GET /documents/:document_id`.+ * @summary Handler for `GET /documents/{document_id}`.*/export const getDocumentParams = zod.object({document_id: zod.string().describe('Document ID'),@@ -2014,7 +2014,7 @@ export const saveDocumentHandlerResponse = zod.object({/*** Soft-deletes a document (only owners can delete).- * @summary Handler for `DELETE /documents/:document_id`.+ * @summary Handler for `DELETE /documents/{document_id}`.*/export const deleteDocumentParams = zod.object({document_id: zod.string().describe('Document ID'),@@ -2028,7 +2028,7 @@ export const deleteDocumentResponse = zod.object({* Edits document metadata such as name or project, and modifiesthe document's share permissions. Requires edit access to the document,and edit access to the target project if moving the document.- * @summary Handler for `PATCH /documents/:document_id`.+ * @summary Handler for `PATCH /documents/{document_id}`.*/export const editDocumentParams = zod.object({document_id: zod.string().describe('Document ID'),@@ -2290,7 +2290,7 @@ export const getLocationHandlerResponse = zod.union([/*** Returns a presigned URL or sync service content for accessing the document.- * @summary Handler for `GET /documents/:document_id/location_v3`.+ * @summary Handler for `GET /documents/{document_id}/location_v3`.*/export const getDocumentLocationV3Params = zod.object({document_id: zod.string().describe('Document ID'),@@ -2378,7 +2378,7 @@ export const revertDeleteDocumentResponse = zod.object({/*** Returns the short UUID for a document.- * @summary Handler for `GET /documents/:document_id/short_id`.+ * @summary Handler for `GET /documents/{document_id}/short_id`.*/export const getDocumentShortIdParams = zod.object({document_id: zod.string().describe('Document ID'),diff --git a/js/app/packages/service-clients/service-storage/openapi.json b/js/app/packages/service-clients/service-storage/openapi.jsonindex 90f4cdee8b..320782c599 100644--- a/js/app/packages/service-clients/service-storage/openapi.json+++ b/js/app/packages/service-clients/service-storage/openapi.json@@ -198,39 +198,29 @@}}},- "/annotations/anchors/document/:document_id": {- "post": {- "tags": ["annotations::create_anchor"],- "summary": "Creates an unthreaded anchor for a document\nIf you need to create a threaded anchor, see the create comment handler",- "operationId": "create_anchor",+ "/annotations/anchors/document/{document_id}": {+ "get": {+ "tags": ["annotations::get"],+ "summary": "Gets a set of comment anchors for a document",+ "operationId": "get_document_anchors","parameters": [{"name": "document_id","in": "path",- "description": "The document id",+ "description": "Document ID","required": true,"schema": {"type": "string"}}],- "requestBody": {- "content": {- "application/json": {- "schema": {- "$ref": "#/components/schemas/CreateUnthreadedAnchorRequest"- }- }- },- "required": true- },"responses": {"200": {"description": "","content": {"application/json": {"schema": {- "$ref": "#/components/schemas/CreateUnthreadedAnchorResponse"+ "$ref": "#/components/schemas/AnchorResponse"}}}@@ -266,31 +256,39 @@}}}- }- },- "/annotations/anchors/document/{document_id}": {- "get": {- "tags": ["annotations::get"],- "summary": "Gets a set of comment anchors for a document",- "operationId": "get_document_anchors",+ },+ "post": {+ "tags": ["annotations::create_anchor"],+ "summary": "Creates an unthreaded anchor for a document\nIf you need to create a threaded anchor, see the create comment handler",+ "operationId": "create_anchor","parameters": [{"name": "document_id","in": "path",- "description": "Document ID",+ "description": "The document id","required": true,"schema": {"type": "string"}}],+ "requestBody": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/CreateUnthreadedAnchorRequest"+ }+ }+ },+ "required": true+ },"responses": {"200": {"description": "","content": {"application/json": {"schema": {- "$ref": "#/components/schemas/AnchorResponse"+ "$ref": "#/components/schemas/CreateUnthreadedAnchorResponse"}}}@@ -468,39 +466,29 @@}}},- "/annotations/comments/document/:document_id": {- "post": {- "tags": ["annotations::create_comment"],- "summary": "Creates a single comment for a document\nOptionally creates a new thread/anchor if one does not exist",- "operationId": "create_comment",+ "/annotations/comments/document/{document_id}": {+ "get": {+ "tags": ["annotations::get"],+ "summary": "Gets a set of comment threads for a document",+ "operationId": "get_document_comments","parameters": [{"name": "document_id","in": "path",- "description": "The document id",+ "description": "Document ID","required": true,"schema": {"type": "string"}}],- "requestBody": {- "content": {- "application/json": {- "schema": {- "$ref": "#/components/schemas/CreateCommentRequest"- }- }- },- "required": true- },"responses": {"200": {"description": "","content": {"application/json": {"schema": {- "$ref": "#/components/schemas/CreateCommentResponse"+ "$ref": "#/components/schemas/ThreadResponse"}}}@@ -536,31 +524,39 @@}}}- }- },- "/annotations/comments/document/{document_id}": {- "get": {- "tags": ["annotations::get"],- "summary": "Gets a set of comment threads for a document",- "operationId": "get_document_comments",+ },+ "post": {+ "tags": ["annotations::create_comment"],+ "summary": "Creates a single comment for a document\nOptionally creates a new thread/anchor if one does not exist",+ "operationId": "create_comment","parameters": [{"name": "document_id","in": "path",- "description": "Document ID",+ "description": "The document id","required": true,"schema": {"type": "string"}}],+ "requestBody": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/CreateCommentRequest"+ }+ }+ },+ "required": true+ },"responses": {"200": {"description": "","content": {"application/json": {"schema": {- "$ref": "#/components/schemas/ThreadResponse"+ "$ref": "#/components/schemas/CreateCommentResponse"}}}@@ -601,7 +597,7 @@"/channels/{channel_id}/attachments": {"get": {"tags": ["channels::inbound::axum_router"],- "summary": "Handler for `GET /channels/:channel_id/attachments`.",+ "summary": "Handler for `GET /channels/{channel_id}/attachments`.","operationId": "get_channel_attachments","parameters": [{@@ -682,7 +678,7 @@"/channels/{channel_id}/messages": {"get": {"tags": ["channels::inbound::axum_router"],- "summary": "Handler for `GET /channels/:channel_id/messages`.",+ "summary": "Handler for `GET /channels/{channel_id}/messages`.","operationId": "get_channel_messages","parameters": [{@@ -792,7 +788,7 @@"/channels/{channel_id}/messages/{message_id}/replies": {"get": {"tags": ["channels::inbound::axum_router"],- "summary": "Handler for `GET /channels/:channel_id/messages/:message_id/replies`.",+ "summary": "Handler for `GET /channels/{channel_id}/messages/{message_id}/replies`.","operationId": "get_thread_replies","parameters": [{@@ -866,7 +862,7 @@"/channels/{channel_id}/participants": {"get": {"tags": ["channels::inbound::axum_router"],- "summary": "Handler for `GET /channels/:channel_id/participants`.",+ "summary": "Handler for `GET /channels/{channel_id}/participants`.","operationId": "get_channel_participants","parameters": [{@@ -1534,7 +1530,7 @@"/documents/{document_id}": {"get": {"tags": ["document"],- "summary": "Handler for `GET /documents/:document_id`.",+ "summary": "Handler for `GET /documents/{document_id}`.","description": "Returns document metadata, user access level, and view location.","operationId": "get_document","parameters": [@@ -1671,7 +1667,7 @@},"delete": {"tags": ["document"],- "summary": "Handler for `DELETE /documents/:document_id`.",+ "summary": "Handler for `DELETE /documents/{document_id}`.","description": "Soft-deletes a document (only owners can delete).","operationId": "delete_document","parameters": [@@ -1730,7 +1726,7 @@},"patch": {"tags": ["document"],- "summary": "Handler for `PATCH /documents/:document_id`.",+ "summary": "Handler for `PATCH /documents/{document_id}`.","description": "Edits document metadata such as name or project, and modifies\nthe document's share permissions. Requires edit access to the document,\nand edit access to the target project if moving the document.","operationId": "edit_document","parameters": [@@ -2070,7 +2066,7 @@"/documents/{document_id}/location_v3": {"get": {"tags": ["document"],- "summary": "Handler for `GET /documents/:document_id/location_v3`.",+ "summary": "Handler for `GET /documents/{document_id}/location_v3`.","description": "Returns a presigned URL or sync service content for accessing the document.","operationId": "get_document_location_v3","parameters": [@@ -2402,7 +2398,7 @@"/documents/{document_id}/short_id": {"get": {"tags": ["document"],- "summary": "Handler for `GET /documents/:document_id/short_id`.",+ "summary": "Handler for `GET /documents/{document_id}/short_id`.","description": "Returns the short UUID for a document.","operationId": "get_document_short_id","parameters": [@@ -3216,7 +3212,7 @@}}},- "/pins/:pinned_item_id": {+ "/pins/{pinned_item_id}": {"post": {"tags": ["pins::add_pin"],"summary": "Pins the item for the user",diff --git a/justfile b/justfileindex 91f5c52139..22b3f83eef 100644--- a/justfile+++ b/justfile@@ -20,8 +20,13 @@ get_environment *ARGS:AWS_KEY=$(awk -F'=' '/\[default\]/{found=1} found && /aws_access_key_id/{gsub(/^[ \t]+|[ \t]+$/, "", $2); print $2; exit}' ~/.aws/credentials)AWS_SECRET=$(awk -F'=' '/\[default\]/{found=1} found && /aws_secret_access_key/{gsub(/^[ \t]+|[ \t]+$/, "", $2); print $2; exit}' ~/.aws/credentials)if [ -n "$AWS_KEY" ] && [ -n "$AWS_SECRET" ]; then- sed -i '' "s|^AWS_ACCESS_KEY_ID=.*|AWS_ACCESS_KEY_ID=\"$AWS_KEY\"|" .env- sed -i '' "s|^AWS_SECRET_ACCESS_KEY=.*|AWS_SECRET_ACCESS_KEY=\"$AWS_SECRET\"|" .env+ if [[ "$OSTYPE" == "darwin"* ]]; then+ sed -i '' "s|^AWS_ACCESS_KEY_ID=.*|AWS_ACCESS_KEY_ID=\"$AWS_KEY\"|" .env+ sed -i '' "s|^AWS_SECRET_ACCESS_KEY=.*|AWS_SECRET_ACCESS_KEY=\"$AWS_SECRET\"|" .env+ else+ sed -i "s|^AWS_ACCESS_KEY_ID=.*|AWS_ACCESS_KEY_ID=\"$AWS_KEY\"|" .env+ sed -i "s|^AWS_SECRET_ACCESS_KEY=.*|AWS_SECRET_ACCESS_KEY=\"$AWS_SECRET\"|" .env+ fiecho "Replaced AWS credentials from ~/.aws/credentials [default] profile"elseecho "Warning: Could not read AWS credentials from ~/.aws/credentials [default] profile"diff --git a/rust/cloud-storage/Cargo.lock b/rust/cloud-storage/Cargo.lockindex 5b700a890d..1aee232215 100644--- a/rust/cloud-storage/Cargo.lock+++ b/rust/cloud-storage/Cargo.lock@@ -1319,15 +1319,15 @@ dependencies = [[[package]]name = "axum"-version = "0.7.9"+version = "0.8.8"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "edca88bc138befd0323b20752846e6587272d3b03b0343c8ea28a6f819e6e71f"+checksum = "8b52af3cb4058c895d37317bb27508dccc8e5f2d39454016b297bf4a400597b8"dependencies = [- "async-trait","axum-core","axum-macros","base64 0.22.1","bytes",+ "form_urlencoded","futures-util","http 1.3.1","http-body 1.0.1",@@ -1341,8 +1341,7 @@ dependencies = ["multer","percent-encoding","pin-project-lite",- "rustversion",- "serde",+ "serde_core","serde_json","serde_path_to_error","serde_urlencoded",@@ -1358,19 +1357,17 @@ dependencies = [[[package]]name = "axum-core"-version = "0.4.5"+version = "0.5.6"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "09f2bd6146b97ae3359fa0cc6d6b376d9539582c7b4220f041a33ec24c226199"+checksum = "08c78f31d7b1291f7ee735c1c6780ccde7785daae9a9206026862dab7d8792d1"dependencies = [- "async-trait","bytes",- "futures-util",+ "futures-core","http 1.3.1","http-body 1.0.1","http-body-util","mime","pin-project-lite",- "rustversion","sync_wrapper","tower-layer","tower-service",@@ -1379,32 +1376,31 @@ dependencies = [[[package]]name = "axum-extra"-version = "0.9.6"+version = "0.10.3"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "c794b30c904f0a1c2fb7740f7df7f7972dfaa14ef6f57cb6178dc63e5dca2f04"+checksum = "9963ff19f40c6102c76756ef0a46004c0d58957d87259fc9208ff8441c12ab96"dependencies = ["axum","axum-core","bytes",- "fastrand 2.3.0","futures-util","http 1.3.1","http-body 1.0.1","http-body-util","mime",- "multer","pin-project-lite",- "serde",- "tower 0.5.2",+ "rustversion",+ "serde_core","tower-layer","tower-service",+ "tracing",][[package]]name = "axum-macros"-version = "0.4.2"+version = "0.5.0"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "57d123550fa8d071b7255cb0cc04dc302baa6c8c4a79f55701552684d8399bce"+checksum = "604fde5e028fea851ce1d8570bbdc034bec850d157f7569d10f347d06808c05c"dependencies = ["proc-macro2","quote",@@ -2071,6 +2067,7 @@ name = "connection_gateway"version = "0.1.0"dependencies = ["anyhow",+ "async-trait","aws-sdk-dynamodb","aws-sdk-secretsmanager","axum",@@ -2110,7 +2107,7 @@ dependencies = ["tower 0.5.2","tower-http","tracing",- "tungstenite 0.27.0",+ "tungstenite","url","utoipa","utoipa-swagger-ui",@@ -2271,7 +2268,7 @@ dependencies = ["tracing","utoipa","utoipa-swagger-ui",- "zip",+ "zip 2.4.2",][[package]]@@ -2968,7 +2965,7 @@ dependencies = ["utoipa","utoipa-swagger-ui","uuid",- "zip",+ "zip 2.4.2",][[package]]@@ -3103,7 +3100,7 @@ dependencies = ["tokio","tracing","urlencoding",- "zip",+ "zip 2.4.2",][[package]]@@ -3845,12 +3842,13 @@ checksum = "645cbb3a84e60b7531617d5ae4e57f7e27308f6445f5abf653209ea76dec8dff"[[package]]name = "flate2"-version = "1.0.35"+version = "1.1.9"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "c936bfdafb507ebbf50b8074c54fa31c5be9a1e7e5f467dd659697041407d07c"+checksum = "843fba2746e448b37e26a819579957415c8cef339bf08564fe8b7ddbd959573c"dependencies = ["crc32fast","miniz_oxide",+ "zlib-rs",][[package]]@@ -5886,9 +5884,9 @@ dependencies = [[[package]]name = "matchit"-version = "0.7.3"+version = "0.8.4"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "0e7465ac9959cc2b1404e8e2367b43684a6d13790fe23056cc8c6c5a6b7bcb94"+checksum = "47e1ffaa40ddd1f3ed91f717a33c8c0ee23fff369e3aa8772b9605cc1d22f4c3"[[package]]name = "maud"@@ -6004,9 +6002,9 @@ dependencies = [[[package]]name = "miniz_oxide"-version = "0.8.4"+version = "0.8.9"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "b3b1c9bd4fe1f0f8b387f6eb9eb3b4a1aa26185e5750efb9140301703f62cd1b"+checksum = "1fa76a2c86f704bdb222d66965fb3d63269ce38518b83cb0575fca855ebb6316"dependencies = ["adler2","simd-adler32",@@ -9983,14 +9981,14 @@ dependencies = [[[package]]name = "tokio-tungstenite"-version = "0.24.0"+version = "0.28.0"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "edc5f74e248dc973e0dbb7b74c7e0d6fcc301c694ff50049504004ef4d0cdcd9"+checksum = "d25a406cddcc431a75d3d9afc6a7c0f7428d4891dd973e4d54c56b46127bf857"dependencies = ["futures-util","log","tokio",- "tungstenite 0.24.0",+ "tungstenite",][[package]]@@ -10079,11 +10077,10 @@ dependencies = [[[package]]name = "tower-cookies"-version = "0.10.0"+version = "0.11.0"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "4fd0118512cf0b3768f7fcccf0bef1ae41d68f2b45edc1e77432b36c97c56c6d"+checksum = "151b5a3e3c45df17466454bb74e9ecedecc955269bdedbf4d150dfa393b55a36"dependencies = [- "async-trait","axum-core","cookie","futures-util",@@ -10258,27 +10255,9 @@ checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b"[[package]]name = "tungstenite"-version = "0.24.0"+version = "0.28.0"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "18e5b8366ee7a95b16d32197d0b2604b43a0be89dc5fac9f8e96ccafbaedda8a"-dependencies = [- "byteorder",- "bytes",- "data-encoding",- "http 1.3.1",- "httparse",- "log",- "rand 0.8.5",- "sha1",- "thiserror 1.0.69",- "utf-8",-]--[[package]]-name = "tungstenite"-version = "0.27.0"-source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "eadc29d668c91fcc564941132e17b28a7ceb2f3ebf0b9dae3e03fd7a6748eb0d"+checksum = "8628dcc84e5a09eb3d8423d6cb682965dea9133204e8fb3efee74c2a0c259442"dependencies = ["bytes","data-encoding",@@ -10426,7 +10405,7 @@ dependencies = ["tokio-util","tracing","walkdir",- "zip",+ "zip 2.4.2",][[package]]@@ -10536,9 +10515,9 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821"[[package]]name = "utoipa"-version = "5.3.1"+version = "5.4.0"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "435c6f69ef38c9017b4b4eea965dfb91e71e53d869e896db40d1cf2441dd75c0"+checksum = "2fcc29c80c21c31608227e0912b2d7fddba57ad76b606890627ba8ee7964e993"dependencies = ["indexmap 2.12.1","serde",@@ -10548,9 +10527,9 @@ dependencies = [[[package]]name = "utoipa-gen"-version = "5.3.1"+version = "5.4.0"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "a77d306bc75294fd52f3e99b13ece67c02c1a2789190a6f31d32f736624326f7"+checksum = "6d79d08d92ab8af4c5e8a6da20c47ae3f61a0f1dabc1997cdf2d082b757ca08b"dependencies = ["proc-macro2","quote",@@ -10561,9 +10540,9 @@ dependencies = [[[package]]name = "utoipa-swagger-ui"-version = "8.1.0"+version = "9.0.2"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "db4b5ac679cc6dfc5ea3f2823b0291c777750ffd5e13b21137e0f7ac0e8f9617"+checksum = "d047458f1b5b65237c2f6dc6db136945667f40a7668627b3490b9513a3d43a55"dependencies = ["axum","base64 0.22.1",@@ -10575,7 +10554,7 @@ dependencies = ["url","utoipa","utoipa-swagger-ui-vendored",- "zip",+ "zip 3.0.0",][[package]]@@ -11405,6 +11384,26 @@ dependencies = ["zstd",]+[[package]]+name = "zip"+version = "3.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "12598812502ed0105f607f941c386f43d441e00148fce9dec3ca5ffb0bde9308"+dependencies = [+ "arbitrary",+ "crc32fast",+ "flate2",+ "indexmap 2.12.1",+ "memchr",+ "zopfli",+]++[[package]]+name = "zlib-rs"+version = "0.6.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3be3d40e40a133f9c916ee3f9f4fa2d9d63435b5fbe1bfc6d9dae0aa0ada1513"+[[package]]name = "zopfli"version = "0.8.1"diff --git a/rust/cloud-storage/Cargo.toml b/rust/cloud-storage/Cargo.tomlindex 7d9947b978..ebd16c4e65 100644--- a/rust/cloud-storage/Cargo.toml+++ b/rust/cloud-storage/Cargo.toml@@ -141,10 +141,10 @@ aws-sdk-sns = "1.90.0"aws-sdk-sqs = "1.91.0"aws-smithy-types = "1.2.13"aws_lambda_events = { version = "0.16.0", default-features = false }-axum = { version = "0.7.9", features = [+axum = { version = "0.8", features = ["tower-log",-] } # causes breaking changes to bump to 0.8.x-axum-extra = { version = "0.9" }+] }+axum-extra = { version = "0.10" }base64 = "0.22.1"cached = { version = "0.54.0", features = ["async_tokio_rt_multi_thread"] }chrono = { version = "0.4.39", features = ["serde"] }@@ -217,13 +217,13 @@ tracing-subscriber = { version = "0.3.22", features = ["env-filter", "json"] }tracing-tree = "0.4.0"unsynn = "0.3"urlencoding = "2.1.3"-utoipa = { version = "5.2.0", features = [+utoipa = { version = "5.4.0", features = ["axum_extras","chrono","repr","uuid",] }-utoipa-swagger-ui = { version = "8.0.3", features = ["axum", "vendored"] }+utoipa-swagger-ui = { version = "9", features = ["axum", "vendored"] }uuid = { version = "1.15.1", features = ["fast-rng", "serde", "v4", "v7"] }# this is pinned to match axum 0.7.9 dependency requirementsasync-stripe = { version = "0.41", default-features = false, features = [@@ -231,7 +231,7 @@ async-stripe = { version = "0.41", default-features = false, features = ["checkout","runtime-tokio-hyper",] }-axum-macros = "0.4.2"+axum-macros = "0.5"bytes = "1.11.1"bzip2 = { version = "0.5.1", default-features = false, features = ["libbz2-rs-sys",diff --git a/rust/cloud-storage/authentication_service/Cargo.toml b/rust/cloud-storage/authentication_service/Cargo.tomlindex 61b083f260..2841005d12 100644--- a/rust/cloud-storage/authentication_service/Cargo.toml+++ b/rust/cloud-storage/authentication_service/Cargo.toml@@ -108,7 +108,7 @@ thiserror = { workspace = true }time = { workspace = true }tokio = { workspace = true }tower = { workspace = true }-tower-cookies = { version = "0.10.0" }+tower-cookies = { version = "0.11.0" }tower-http = { workspace = true }tracing = { workspace = true }url = { workspace = true }diff --git a/rust/cloud-storage/authentication_service/src/api/email/mod.rs b/rust/cloud-storage/authentication_service/src/api/email/mod.rsindex 54db891fbe..dc59be0293 100644--- a/rust/cloud-storage/authentication_service/src/api/email/mod.rs+++ b/rust/cloud-storage/authentication_service/src/api/email/mod.rs@@ -16,14 +16,14 @@ pub(in crate::api) mod verify_fusionauth_user_email;pub fn router(jwt_args: JwtValidationArgs) -> Router<ApiContext> {Router::new().route(- "/verify/fusionauth/:verification_id",+ "/verify/fusionauth/{verification_id}",get(verify_fusionauth_user_email::handler),).route("/resend/fusionauth",post(resend_fusionauth_verify_user_email::handler),)- .route("/verify/:verification_id", get(verify_email_link::handler))+ .route("/verify/{verification_id}", get(verify_email_link::handler)).merge(router_with_auth(jwt_args))}diff --git a/rust/cloud-storage/authentication_service/src/api/merge/mod.rs b/rust/cloud-storage/authentication_service/src/api/merge/mod.rsindex fe67d7dca3..0b3e5f6d82 100644--- a/rust/cloud-storage/authentication_service/src/api/merge/mod.rs+++ b/rust/cloud-storage/authentication_service/src/api/merge/mod.rs@@ -12,5 +12,5 @@ pub(in crate::api) mod verify_merge_request;pub fn router() -> Router<ApiContext> {Router::new().route("/", post(create_merge_request::handler))- .route("/verify/:code", get(verify_merge_request::handler))+ .route("/verify/{code}", get(verify_merge_request::handler))}diff --git a/rust/cloud-storage/authentication_service/src/api/middleware/has_payment_source.rs b/rust/cloud-storage/authentication_service/src/api/middleware/has_payment_source.rsindex eadcf0d092..8a512ee895 100644--- a/rust/cloud-storage/authentication_service/src/api/middleware/has_payment_source.rs+++ b/rust/cloud-storage/authentication_service/src/api/middleware/has_payment_source.rs@@ -4,7 +4,7 @@use std::sync::Arc;use axum::{- Extension, Json, RequestPartsExt, async_trait,+ Extension, Json, RequestPartsExt,extract::{FromRef, FromRequestParts},http::{StatusCode, request::Parts},response::{IntoResponse, Response},@@ -64,7 +64,6 @@ impl IntoResponse for StripeCustomerError {}}-#[async_trait]impl<S> FromRequestParts<S> for StripeCustomerExtractorwherePgPool: FromRef<S>,diff --git a/rust/cloud-storage/authentication_service/src/api/middleware/team_access.rs b/rust/cloud-storage/authentication_service/src/api/middleware/team_access.rsindex 2350343dce..459dec4882 100644--- a/rust/cloud-storage/authentication_service/src/api/middleware/team_access.rs+++ b/rust/cloud-storage/authentication_service/src/api/middleware/team_access.rs@@ -1,6 +1,6 @@use crate::api::team::TeamPathParam;use axum::{- Extension, Json, RequestPartsExt, async_trait,+ Extension, Json, RequestPartsExt,extract::{FromRef, FromRequestParts, Path},http::{StatusCode, request::Parts},response::{IntoResponse, Response},@@ -78,7 +78,6 @@ impl IntoResponse for RoleAccessErr {}}-#[async_trait]impl<S, T> FromRequestParts<S> for TeamAccessRoleExtractor<T>wherePgPool: FromRef<S>,diff --git a/rust/cloud-storage/authentication_service/src/api/oauth/mod.rs b/rust/cloud-storage/authentication_service/src/api/oauth/mod.rsindex 49679fbcff..ee12e4cb42 100644--- a/rust/cloud-storage/authentication_service/src/api/oauth/mod.rs+++ b/rust/cloud-storage/authentication_service/src/api/oauth/mod.rs@@ -13,7 +13,7 @@ pub(in crate::api) mod passwordless_callback;pub fn router(state: ApiContext) -> Router<ApiContext> {Router::new().route(- "/passwordless/:code",+ "/passwordless/{code}",get(passwordless_callback::handler).layer(ServiceBuilder::new().layer(CookieManagerLayer::new())diff --git a/rust/cloud-storage/authentication_service/src/api/oauth2/mod.rs b/rust/cloud-storage/authentication_service/src/api/oauth2/mod.rsindex bd5b4d9e4d..9d1984bbac 100644--- a/rust/cloud-storage/authentication_service/src/api/oauth2/mod.rs+++ b/rust/cloud-storage/authentication_service/src/api/oauth2/mod.rs@@ -8,7 +8,7 @@ mod login;pub fn router() -> Router<ApiContext> {Router::new().route(- "/:provider/callback",+ "/{provider}/callback",get(handler).layer(CookieManagerLayer::new()),)}diff --git a/rust/cloud-storage/authentication_service/src/api/session/mod.rs b/rust/cloud-storage/authentication_service/src/api/session/mod.rsindex 3f3d97b0b2..6e3ae53e9f 100644--- a/rust/cloud-storage/authentication_service/src/api/session/mod.rs+++ b/rust/cloud-storage/authentication_service/src/api/session/mod.rs@@ -17,7 +17,7 @@ pub(in crate::api) mod session_login;pub fn router() -> Router<ApiContext> {Router::new().route(- "/login/:session_code",+ "/login/{session_code}",get(session_login::handler).layer(ServiceBuilder::new().layer(CookieManagerLayer::new())),)diff --git a/rust/cloud-storage/authentication_service/src/api/session/session_login.rs b/rust/cloud-storage/authentication_service/src/api/session/session_login.rsindex 5365c89b7b..4f470986ae 100644--- a/rust/cloud-storage/authentication_service/src/api/session/session_login.rs+++ b/rust/cloud-storage/authentication_service/src/api/session/session_login.rs@@ -35,6 +35,7 @@ pub struct Params {))]#[tracing::instrument(skip(ctx))]+#[axum::debug_handler]pub async fn handler(State(ctx): State<ApiContext>,Path(Params { session_code }): Path<Params>,diff --git a/rust/cloud-storage/authentication_service/src/api/team/mod.rs b/rust/cloud-storage/authentication_service/src/api/team/mod.rsindex 4127131bf9..af0b487a12 100644--- a/rust/cloud-storage/authentication_service/src/api/team/mod.rs+++ b/rust/cloud-storage/authentication_service/src/api/team/mod.rs@@ -23,25 +23,25 @@ pub(in crate::api) mod remove_user_from_team;pub fn router(jwt_args: JwtValidationArgs) -> Router<ApiContext> {Router::new().route("/", post(create_team::handler))- .route("/join/:team_invite_id", get(join_team::handler))+ .route("/join/{team_invite_id}", get(join_team::handler)).route("/user", get(get_user_teams::handler)).route("/user/invites", get(get_user_invites::handler))- .route("/:team_id", get(get_team::handler))- .route("/:team_id", patch(patch_team::handler))- .route("/:team_id", delete(delete_team::handler))- .route("/:team_id/invites", get(get_team_invites::handler))- .route("/:team_id/invite", post(invite_to_team::handler))+ .route("/{team_id}", get(get_team::handler))+ .route("/{team_id}", patch(patch_team::handler))+ .route("/{team_id}", delete(delete_team::handler))+ .route("/{team_id}/invites", get(get_team_invites::handler))+ .route("/{team_id}/invite", post(invite_to_team::handler)).route(- "/:team_id/reinvite/:team_invite_id",+ "/{team_id}/reinvite/{team_invite_id}",get(reinvite_to_team::handler),)- .route("/join/:team_invite_id", delete(reject_invitation::handler))+ .route("/join/{team_invite_id}", delete(reject_invitation::handler)).route(- "/:team_id/remove/:remove_user_id",+ "/{team_id}/remove/{remove_user_id}",delete(remove_user_from_team::handler),).route(- "/:team_id/invite/:team_invite_id",+ "/{team_id}/invite/{team_invite_id}",delete(delete_team_invite::handler),).layer(diff --git a/rust/cloud-storage/channels/src/inbound/axum_router.rs b/rust/cloud-storage/channels/src/inbound/axum_router.rsindex 0c02bd5b9b..ceb5545c9f 100644--- a/rust/cloud-storage/channels/src/inbound/axum_router.rs+++ b/rust/cloud-storage/channels/src/inbound/axum_router.rs@@ -141,25 +141,25 @@ where{Router::new().route(- "/:channel_id/messages",+ "/{channel_id}/messages",get(get_channel_messages_handler::<S, Svc>),).route(- "/:channel_id/messages/:message_id/replies",+ "/{channel_id}/messages/{message_id}/replies",get(get_thread_replies_handler::<S, Svc>),).route(- "/:channel_id/attachments",+ "/{channel_id}/attachments",get(get_channel_attachments_handler::<S, Svc>),).route(- "/:channel_id/participants",+ "/{channel_id}/participants",get(get_channel_participants_handler::<S, Svc>),).with_state(state)}-/// Handler for `GET /channels/:channel_id/messages`.+/// Handler for `GET /channels/{channel_id}/messages`.#[utoipa::path(get,operation_id = "get_channel_messages",@@ -235,7 +235,7 @@ pub async fn get_channel_messages_handler<S: ChannelMessagesService, Svc: Entity}))}-/// Handler for `GET /channels/:channel_id/messages/:message_id/replies`.+/// Handler for `GET /channels/{channel_id}/messages/{message_id}/replies`.#[utoipa::path(get,operation_id = "get_thread_replies",@@ -270,7 +270,7 @@ pub async fn get_thread_replies_handler<S: ChannelMessagesService, Svc: EntityAc))}-/// Handler for `GET /channels/:channel_id/attachments`.+/// Handler for `GET /channels/{channel_id}/attachments`.#[utoipa::path(get,operation_id = "get_channel_attachments",@@ -309,7 +309,7 @@ pub async fn get_channel_attachments_handler<Ok(Json(page.type_erase().map(ApiChannelAttachment::from)))}-/// Handler for `GET /channels/:channel_id/participants`.+/// Handler for `GET /channels/{channel_id}/participants`.#[utoipa::path(get,operation_id = "get_channel_participants",diff --git a/rust/cloud-storage/comms_service/src/api/attachments/mod.rs b/rust/cloud-storage/comms_service/src/api/attachments/mod.rsindex 87bbf6ed65..f7a0ee2034 100644--- a/rust/cloud-storage/comms_service/src/api/attachments/mod.rs+++ b/rust/cloud-storage/comms_service/src/api/attachments/mod.rs@@ -5,7 +5,7 @@ pub mod references;pub fn router() -> Router<AppState> {Router::new().route(- "/:entity_type/:entity_id/references",+ "/{entity_type}/{entity_id}/references",get(references::handler),)}diff --git a/rust/cloud-storage/comms_service/src/api/channels/mod.rs b/rust/cloud-storage/comms_service/src/api/channels/mod.rsindex 781d69208c..8488fe7436 100644--- a/rust/cloud-storage/comms_service/src/api/channels/mod.rs+++ b/rust/cloud-storage/comms_service/src/api/channels/mod.rs@@ -27,43 +27,46 @@ use crate::api::context::AppState;pub fn router() -> Router<AppState> {Router::new().route("/", post(create_channel::create_channel_handler))- .route("/:channel_id", get(get_channel::get_channel_handler))+ .route("/{channel_id}", get(get_channel::get_channel_handler)).route(- "/:channel_id",+ "/{channel_id}",delete(delete_channel::delete_channel_handler),)- .route("/:channel_id", patch(patch_channel::patch_channel_handler))+ .route("/{channel_id}", patch(patch_channel::patch_channel_handler)).route(- "/:channel_id/message",+ "/{channel_id}/message",post(post_message::post_message_handler),).route(- "/:channel_id/typing",+ "/{channel_id}/typing",post(post_typing::post_typing_handler),).route(- "/:channel_id/reaction",+ "/{channel_id}/reaction",post(post_reaction::post_reaction_handler),).route(- "/:channel_id/message/:message_id",+ "/{channel_id}/message/{message_id}",patch(patch_message::patch_message_handler),).route(- "/:channel_id/message/:message_id",+ "/{channel_id}/message/{message_id}",delete(delete_message::delete_message_handler),).route(- "/:channel_id/join",+ "/{channel_id}/join",post(join_channel::join_channel_handler),).route(- "/:channel_id/leave",+ "/{channel_id}/leave",post(leave_channel::leave_channel_handler),)- .route("/:channel_id/participants", post(add_participants::handler)).route(- "/:channel_id/participants",+ "/{channel_id}/participants",+ post(add_participants::handler),+ )+ .route(+ "/{channel_id}/participants",delete(remove_participants::handler),).route("/get_or_create_dm", post(get_or_create_dm::handler))@@ -71,13 +74,13 @@ pub fn router() -> Router<AppState> {"/get_or_create_private",post(get_or_create_private::handler),)- .route("/:channel_id/mentions", get(get_mentions::handler))+ .route("/{channel_id}/mentions", get(get_mentions::handler)).route(- "/:channel_id/metadata",+ "/{channel_id}/metadata",get(get_channel_metadata::handler_external),).route(- "/:channel_id/transcript",+ "/{channel_id}/transcript",get(get_channel_transcript::handler_external),).route("/messages/context", get(get_message_with_context::handler))diff --git a/rust/cloud-storage/comms_service/src/api/extractors.rs b/rust/cloud-storage/comms_service/src/api/extractors.rsindex 3a00488b9a..5bb8bf3f39 100644--- a/rust/cloud-storage/comms_service/src/api/extractors.rs+++ b/rust/cloud-storage/comms_service/src/api/extractors.rs@@ -1,5 +1,5 @@use axum::{- RequestPartsExt, async_trait,+ RequestPartsExt,extract::{FromRef, FromRequestParts, Path},http::{StatusCode, request::Parts},response::{IntoResponse, Response},@@ -89,7 +89,6 @@ fn unauthorized(msg: &'static str) -> Response {(StatusCode::UNAUTHORIZED, msg).into_response()}-#[async_trait]impl<S> FromRequestParts<S> for ChannelIdwhereS: Send + Sync,@@ -103,7 +102,6 @@ where}}-#[async_trait]impl<S> FromRequestParts<S> for ChannelParticipantswhereS: Send + Sync,@@ -136,7 +134,6 @@ where#[derive(Clone)]pub struct ChannelInfoExtractor(pub ChannelInfo);-#[async_trait]impl<S> FromRequestParts<S> for ChannelInfoExtractorwhereS: Send + Sync,@@ -158,7 +155,6 @@ where}}-#[async_trait]impl<S, U> FromRequestParts<S> for ChannelName<U>whereS: Send + Sync,@@ -211,11 +207,10 @@ where&name_lookup,);- return Ok(ChannelName(channel_name, PhantomData));+ Ok(ChannelName(channel_name, PhantomData))}}-#[async_trait]impl<S> FromRequestParts<S> for ChannelTypeExtractorwhereS: Send + Sync,@@ -295,7 +290,6 @@ pub async fn get_user_role(}}-#[async_trait]impl<S> FromRequestParts<S> for UserContextWithRolewhereS: Send + Sync,@@ -337,7 +331,6 @@ where#[derive(Clone, Debug)]pub struct ChannelMember(pub UserContextWithRole);-#[async_trait]impl<S> FromRequestParts<S> for ChannelMemberwhereS: Send + Sync,@@ -358,7 +351,6 @@ where#[derive(Clone, Debug)]pub struct ChannelOwner(pub UserContextWithRole);-#[async_trait]impl<S> FromRequestParts<S> for ChannelOwnerwhereS: Send + Sync,@@ -382,7 +374,6 @@ where#[allow(dead_code)]pub struct ChannelAdmin(pub UserContextWithRole);-#[async_trait]impl<S> FromRequestParts<S> for ChannelAdminwhereS: Send + Sync,@@ -406,7 +397,6 @@ where#[derive(Serialize, Deserialize, Clone, Debug)]pub struct MessageId(pub Uuid);-#[async_trait]impl<S> FromRequestParts<S> for MessageIdwhereS: Send + Sync,@@ -423,7 +413,6 @@ where#[derive(Serialize, Deserialize, Clone, Debug)]pub struct MessageSender(pub UserContext);-#[async_trait]impl<S> FromRequestParts<S> for MessageSenderwhereS: Send + Sync,@@ -457,7 +446,6 @@ pub enum MessageSenderOrAdmin {ChannelAdmin(ChannelAdmin),}-#[async_trait]impl<S> FromRequestParts<S> for MessageSenderOrAdminwhereS: Send + Sync,@@ -476,7 +464,6 @@ where}}-#[async_trait]impl<S> FromRequestParts<S> for ParticipantAccesswhereS: Send + Sync,diff --git a/rust/cloud-storage/comms_service/src/api/mentions/mod.rs b/rust/cloud-storage/comms_service/src/api/mentions/mod.rsindex 421ea421bd..a92c5f9a89 100644--- a/rust/cloud-storage/comms_service/src/api/mentions/mod.rs+++ b/rust/cloud-storage/comms_service/src/api/mentions/mod.rs@@ -13,5 +13,5 @@ mod mentions_middleware;pub fn router() -> Router<AppState> {Router::new().route("/", post(create_mention_handler))- .route("/:mention_id", delete(delete_mention_handler))+ .route("/{mention_id}", delete(delete_mention_handler))}diff --git a/rust/cloud-storage/connection_gateway/Cargo.toml b/rust/cloud-storage/connection_gateway/Cargo.tomlindex 2ab2cacfdc..c88fbad0ca 100644--- a/rust/cloud-storage/connection_gateway/Cargo.toml+++ b/rust/cloud-storage/connection_gateway/Cargo.toml@@ -22,6 +22,7 @@ path = "src/openapi.rs"[dependencies]anyhow = { workspace = true }+async-trait = { workspace = true }aws-sdk-dynamodb = { workspace = true }aws-sdk-secretsmanager = { workspace = true }axum = { workspace = true, features = ["macros", "tower-log", "ws"] }@@ -68,7 +69,7 @@ tokio = { workspace = true }tower = { workspace = true }tower-http = { workspace = true }tracing = { workspace = true, features = ["attributes"] }-tungstenite = "0.27.0"+tungstenite = "0.28"url = { workspace = true }utoipa = { workspace = true, features = ["axum_extras"] }utoipa-swagger-ui = { workspace = true, features = ["axum"] }diff --git a/rust/cloud-storage/connection_gateway/src/api/entities/mod.rs b/rust/cloud-storage/connection_gateway/src/api/entities/mod.rsindex bbd2bcecb5..9d76b6146c 100644--- a/rust/cloud-storage/connection_gateway/src/api/entities/mod.rs+++ b/rust/cloud-storage/connection_gateway/src/api/entities/mod.rs@@ -19,7 +19,7 @@ whereS: Send + Sync + Clone + 'static,{Router::new()- .route("/:entity_type/:entity_id", get(get_entity_handler))+ .route("/{entity_type}/{entity_id}", get(get_entity_handler)).layer(axum::middleware::from_fn_with_state(state.clone(),auth::internal_access::handler,diff --git a/rust/cloud-storage/connection_gateway/src/api/message/mod.rs b/rust/cloud-storage/connection_gateway/src/api/message/mod.rsindex a4e4d2e626..b22d03b28f 100644--- a/rust/cloud-storage/connection_gateway/src/api/message/mod.rs+++ b/rust/cloud-storage/connection_gateway/src/api/message/mod.rs@@ -18,7 +18,10 @@ whereS: Send + Sync + Clone + 'static,{Router::new()- .route("/send/:entity_type/:entity_id", post(send_message_handler))+ .route(+ "/send/{entity_type}/{entity_id}",+ post(send_message_handler),+ ).route("/batch_send", post(batch_send_message_handler)).route("/batch_send_unique",diff --git a/rust/cloud-storage/connection_gateway/src/model/message.rs b/rust/cloud-storage/connection_gateway/src/model/message.rsindex aad366b6e6..588bf213be 100644--- a/rust/cloud-storage/connection_gateway/src/model/message.rs+++ b/rust/cloud-storage/connection_gateway/src/model/message.rs@@ -33,7 +33,7 @@ impl TryFrom<Message> for axum::extract::ws::Message {fn try_from(msg: Message) -> Result<Self> {let string: String = serde_json::to_string(&msg)?;- Ok(axum::extract::ws::Message::Text(string))+ Ok(axum::extract::ws::Message::Text(string.into()))}}@@ -42,7 +42,7 @@ impl TryFrom<OutgoingMessage> for axum::extract::ws::Message {fn try_from(msg: OutgoingMessage) -> Result<Self> {match msg {- OutgoingMessage::Pong => Ok(axum::extract::ws::Message::Text("pong".to_string())),+ OutgoingMessage::Pong => Ok(axum::extract::ws::Message::Text("pong".into())),OutgoingMessage::Message(message) => message.try_into(),}}diff --git a/rust/cloud-storage/connection_gateway/src/service/connection.rs b/rust/cloud-storage/connection_gateway/src/service/connection.rsindex beea72f66e..be17db3195 100644--- a/rust/cloud-storage/connection_gateway/src/service/connection.rs+++ b/rust/cloud-storage/connection_gateway/src/service/connection.rs@@ -4,7 +4,7 @@ use crate::model::{tracking::{EntityConnection, UserEntityConnection},};use anyhow::Result;-use axum::async_trait;+use async_trait::async_trait;use dashmap::DashMap;use model_entity::Entity;use std::{diff --git a/rust/cloud-storage/connection_gateway/src/service/dynamodb.rs b/rust/cloud-storage/connection_gateway/src/service/dynamodb.rsindex 668845a70b..f6119f71c8 100644--- a/rust/cloud-storage/connection_gateway/src/service/dynamodb.rs+++ b/rust/cloud-storage/connection_gateway/src/service/dynamodb.rs@@ -2,9 +2,9 @@ use crate::model::connection::StoredConnectionEntity;use crate::model::tracking::{EntityConnection, UserEntityConnection};use crate::service::connection::{ConnectionManager, ConnectionRepo};use anyhow::{Context, Result};+use async_trait::async_trait;use aws_sdk_dynamodb::error::ProvideErrorMetadata;use aws_sdk_dynamodb::types::{AttributeValue, ReturnValue};-use axum::async_trait;use ensure_exists::dynamodb::{CreateTableErr, DefineTable, DynamoClientWrapper};use ensure_exists::{DoesExist, EnsureExists};use macro_env_var::env_var;diff --git a/rust/cloud-storage/document_cognition_service/src/api/attachments/mod.rs b/rust/cloud-storage/document_cognition_service/src/api/attachments/mod.rsindex ba79e56590..11e20b7047 100644--- a/rust/cloud-storage/document_cognition_service/src/api/attachments/mod.rs+++ b/rust/cloud-storage/document_cognition_service/src/api/attachments/mod.rs@@ -7,7 +7,7 @@ use crate::api::context::ApiContext;pub fn router() -> Router<ApiContext> {Router::new().route(- "/:attachment_id/chats",+ "/{attachment_id}/chats",get(get_chats_for_attachment::get_chats_for_attachment_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn(macro_middleware::auth::ensure_user_exists::handler,diff --git a/rust/cloud-storage/document_cognition_service/src/api/chats/mod.rs b/rust/cloud-storage/document_cognition_service/src/api/chats/mod.rsindex 237ddaa46a..9ce1c194d2 100644--- a/rust/cloud-storage/document_cognition_service/src/api/chats/mod.rs+++ b/rust/cloud-storage/document_cognition_service/src/api/chats/mod.rs@@ -41,7 +41,7 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {),).route(- "/:chat_id/copy",+ "/{chat_id}/copy",post(copy_chat::copy_chat_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn(@@ -51,12 +51,12 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {),).route(- "/:chat_id",+ "/{chat_id}",get(get_chat::get_chat_handler).layer(ServiceBuilder::new().layer(ensure_chat_exists.clone())),).route(- "/:chat_id/revert_delete",+ "/{chat_id}/revert_delete",put(revert_delete_chat::handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn(@@ -66,7 +66,7 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {),).route(- "/:chat_id",+ "/{chat_id}",delete(delete_chat::delete_chat_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn(@@ -76,7 +76,7 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {),).route(- "/:chat_id/permanent",+ "/{chat_id}/permanent",delete(delete_chat::permanently_delete_chat_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn(@@ -86,7 +86,7 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {),).route(- "/:chat_id",+ "/{chat_id}",patch(patch_chat::patch_chat_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn(@@ -96,7 +96,7 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {),).route(- "/:chat_id/permissions",+ "/{chat_id}/permissions",get(get_chat_permissions::get_chat_permissions_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn(@@ -106,7 +106,7 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {),).route(- "/history/:chat_id",+ "/history/{chat_id}",get(chat_history::get_chat_history_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn(diff --git a/rust/cloud-storage/document_cognition_service/src/api/citations/mod.rs b/rust/cloud-storage/document_cognition_service/src/api/citations/mod.rsindex b51c205555..7125ab5d3d 100644--- a/rust/cloud-storage/document_cognition_service/src/api/citations/mod.rs+++ b/rust/cloud-storage/document_cognition_service/src/api/citations/mod.rs@@ -11,7 +11,7 @@ use model::{citations::DocumentTextPart, user::UserContext};use sqlx::PgPool;pub fn router() -> Router<ApiContext> {- Router::new().route("/:id", get(get_citation_handler))+ Router::new().route("/{id}", get(get_citation_handler))}#[derive(serde::Deserialize)]diff --git a/rust/cloud-storage/document_cognition_service/src/api/id_mapping/mod.rs b/rust/cloud-storage/document_cognition_service/src/api/id_mapping/mod.rsindex ab7b547cb6..0cb8b3695b 100644--- a/rust/cloud-storage/document_cognition_service/src/api/id_mapping/mod.rs+++ b/rust/cloud-storage/document_cognition_service/src/api/id_mapping/mod.rs@@ -17,13 +17,13 @@ mod get_mapping;pub fn router() -> Router<ApiContext> {Router::new().route(- "/:source_id",+ "/{source_id}",post(create::create_id_mapping_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn(macro_middleware::auth::ensure_user_exists::handler),)),).route(- "/:source_id",+ "/{source_id}",get(get_mapping::get_id_mapping_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn(macro_middleware::auth::ensure_user_exists::handler),)),diff --git a/rust/cloud-storage/document_cognition_service/src/api/mod.rs b/rust/cloud-storage/document_cognition_service/src/api/mod.rsindex aae004de58..da7e1e911d 100644--- a/rust/cloud-storage/document_cognition_service/src/api/mod.rs+++ b/rust/cloud-storage/document_cognition_service/src/api/mod.rs@@ -97,6 +97,6 @@ fn api_router(api_context: ApiContext) -> Router {);Router::new()- .nest("/:version", internal_router.clone())+ .nest("/{version}", internal_router.clone()).merge(internal_router)}diff --git a/rust/cloud-storage/document_storage_service/src/api/annotations/create_anchor.rs b/rust/cloud-storage/document_storage_service/src/api/annotations/create_anchor.rsindex ec70575eb5..84bd78c42d 100644--- a/rust/cloud-storage/document_storage_service/src/api/annotations/create_anchor.rs+++ b/rust/cloud-storage/document_storage_service/src/api/annotations/create_anchor.rs@@ -33,7 +33,7 @@ pub struct Params {/// If you need to create a threaded anchor, see the create comment handler#[utoipa::path(post,- path = "/annotations/anchors/document/:document_id",+ path = "/annotations/anchors/document/{document_id}",params(("document_id" = String, Path, description = "The document id")),diff --git a/rust/cloud-storage/document_storage_service/src/api/annotations/create_comment.rs b/rust/cloud-storage/document_storage_service/src/api/annotations/create_comment.rsindex c1b0507309..5581a1c8d5 100644--- a/rust/cloud-storage/document_storage_service/src/api/annotations/create_comment.rs+++ b/rust/cloud-storage/document_storage_service/src/api/annotations/create_comment.rs@@ -35,7 +35,7 @@ pub struct Params {/// Optionally creates a new thread/anchor if one does not exist#[utoipa::path(post,- path = "/annotations/comments/document/:document_id",+ path = "/annotations/comments/document/{document_id}",params(("document_id" = String, Path, description = "The document id")),diff --git a/rust/cloud-storage/document_storage_service/src/api/annotations/mod.rs b/rust/cloud-storage/document_storage_service/src/api/annotations/mod.rsindex 2ee01c5f81..9cbac1ddfe 100644--- a/rust/cloud-storage/document_storage_service/src/api/annotations/mod.rs+++ b/rust/cloud-storage/document_storage_service/src/api/annotations/mod.rs@@ -26,7 +26,7 @@ use tower::ServiceBuilder;pub fn router(state: ApiContext) -> Router<ApiContext> {Router::new().route(- "/comments/document/:document_id",+ "/comments/document/{document_id}",get(get::get_document_comments_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn_with_state(state.clone(),@@ -35,7 +35,7 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {)),).route(- "/comments/document/:document_id",+ "/comments/document/{document_id}",post(create_comment::create_comment_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn_with_state(state.clone(),@@ -44,17 +44,17 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {)),).route(- "/comments/comment/:comment_id",+ "/comments/comment/{comment_id}",delete(delete_comment::delete_comment_handler),).route("/anchors", delete(delete_anchor::delete_anchor_handler)).route("/anchors", patch(edit_anchor::edit_anchor_handler)).route(- "/comments/comment/:comment_id",+ "/comments/comment/{comment_id}",patch(edit_comment::edit_comment_handler),).route(- "/anchors/document/:document_id",+ "/anchors/document/{document_id}",get(get::get_document_anchors_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn_with_state(state.clone(),@@ -63,7 +63,7 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {)),).route(- "/anchors/document/:document_id",+ "/anchors/document/{document_id}",post(create_anchor::create_anchor_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn_with_state(state.clone(),diff --git a/rust/cloud-storage/document_storage_service/src/api/documents/mod.rs b/rust/cloud-storage/document_storage_service/src/api/documents/mod.rsindex 8988252563..b5caa235e3 100644--- a/rust/cloud-storage/document_storage_service/src/api/documents/mod.rs+++ b/rust/cloud-storage/document_storage_service/src/api/documents/mod.rs@@ -91,26 +91,26 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {)),).route(- "/:document_id/permissions",+ "/{document_id}/permissions",get(get_document_permissions::get_document_permissions_handler).layer(ensure_document_exists_middleware.clone()),).route(- "/:document_id/location",+ "/{document_id}/location",get(location::get_location_handler).layer(ensure_document_exists_middleware.clone()),)- // NOTE: /:document_id/location_v3 is now served by the documents hex crate router+ // NOTE: /{document_id}/location_v3 is now served by the documents hex crate router.route(- "/:document_id/text",+ "/{document_id}/text",get(get_document_text::handler).layer(ensure_document_exists_middleware.clone()),).route(- "/:document_id/:document_version_id/key",+ "/{document_id}/{document_version_id}/key",get(get_document_key::get_document_key_handler).layer(ensure_document_exists_middleware.clone()),).route(- "/:document_id/copy",+ "/{document_id}/copy",post(copy_document::copy_document_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn(@@ -127,53 +127,53 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {)),),)- // NOTE: GET /:document_id is now served by the documents hex crate router+ // NOTE: GET /{document_id} is now served by the documents hex crate router.route(- "/:document_id/views",+ "/{document_id}/views",get(get_document_views::get_document_views_handler).layer(ensure_document_exists_middleware.clone()),).route(- "/:document_id/export",+ "/{document_id}/export",get(export_document::handler).layer(ensure_document_exists_middleware.clone()),).route(- "/:document_id/:document_version_id",+ "/{document_id}/{document_version_id}",get(get_document_version::handler).layer(ensure_document_exists_middleware.clone()),)- // NOTE: PATCH /:document_id (edit_document) is now served by the documents hex crate router+ // NOTE: PATCH /{document_id} (edit_document) is now served by the documents hex crate router.route(- "/:document_id",+ "/{document_id}",put(save_document::save_document_handler).layer(ensure_document_exists_middleware.clone()),).route(- "/presave/:document_id",+ "/presave/{document_id}",#[allow(deprecated, reason = "allow presave_document_handler")]put(pre_save::presave_document_handler).layer(ensure_document_exists_middleware.clone()),).route(- "/:document_id/simple_save",+ "/{document_id}/simple_save",put(simple_save::handler).layer(ensure_document_exists_middleware.clone()),)- // NOTE: DELETE /:document_id is now served by the documents hex crate router+ // NOTE: DELETE /{document_id} is now served by the documents hex crate router.route(- "/:document_id/permanent",+ "/{document_id}/permanent",delete(delete_document::permanently_delete_document_handler).layer(ensure_document_exists_middleware.clone()),).route(- "/:document_id/revert_delete",+ "/{document_id}/revert_delete",put(revert_delete_document::handler).layer(ensure_document_exists_middleware.clone()),).route(- "/:document_id/processing",+ "/{document_id}/processing",get(get_document_processing_result::handler).layer(ensure_document_exists_middleware),).with_state(state).route(- "/:document_id/processing/:job_id",+ "/{document_id}/processing/{job_id}",get(job_processing_result::job_processing_result_handler),).route(diff --git a/rust/cloud-storage/document_storage_service/src/api/documents/permissions_token/mod.rs b/rust/cloud-storage/document_storage_service/src/api/documents/permissions_token/mod.rsindex 6409796dc3..d50f3a5702 100644--- a/rust/cloud-storage/document_storage_service/src/api/documents/permissions_token/mod.rs+++ b/rust/cloud-storage/document_storage_service/src/api/documents/permissions_token/mod.rs@@ -9,7 +9,7 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {Router::new().route("/validate", post(validate_permissions_token::handler)).route(- "/:document_id",+ "/{document_id}",post(create_permission_token::handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn_with_state(state.clone(),diff --git a/rust/cloud-storage/document_storage_service/src/api/entity/mod.rs b/rust/cloud-storage/document_storage_service/src/api/entity/mod.rsindex 5f8b031a26..9be733bfb7 100644--- a/rust/cloud-storage/document_storage_service/src/api/entity/mod.rs+++ b/rust/cloud-storage/document_storage_service/src/api/entity/mod.rs@@ -5,7 +5,7 @@ use axum::{Router, routing::get};pub fn router() -> Router<ApiContext> {Router::new().route(- "/:entity_type/:entity_id/permissions",+ "/{entity_type}/{entity_id}/permissions",get(get_entity_permission::handler),)}diff --git a/rust/cloud-storage/document_storage_service/src/api/history/mod.rs b/rust/cloud-storage/document_storage_service/src/api/history/mod.rsindex e57f896336..1506af3fe4 100644--- a/rust/cloud-storage/document_storage_service/src/api/history/mod.rs+++ b/rust/cloud-storage/document_storage_service/src/api/history/mod.rs@@ -12,11 +12,11 @@ pub fn router() -> Router<ApiContext> {Router::new().route("/", get(get_history::get_history_handler)).route(- "/:item_type/:item_id",+ "/{item_type}/{item_id}",post(upsert_history::upsert_history_handler),).route(- "/:item_type/:item_id",+ "/{item_type}/{item_id}",delete(delete_history::delete_history_handler),).layer(axum::middleware::from_fn(diff --git a/rust/cloud-storage/document_storage_service/src/api/internal/mod.rs b/rust/cloud-storage/document_storage_service/src/api/internal/mod.rsindex 5a3d7b3212..101bd09972 100644--- a/rust/cloud-storage/document_storage_service/src/api/internal/mod.rs+++ b/rust/cloud-storage/document_storage_service/src/api/internal/mod.rs@@ -43,12 +43,12 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {post(permissions::update_user_channel_permissions::handler),).route(- "/users/:user_id",+ "/users/{user_id}",delete(delete_user_items::delete_user_items_handler),)// Document routes.route(- "/documents/:document_id",+ "/documents/{document_id}",get(documents_hex::inbound::axum_router::get_document_handler::<DocumentService,EntityAccessService,@@ -56,29 +56,29 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {.layer(ensure_document_exists_middleware.clone()),).route(- "/documents/:document_id/basic",+ "/documents/{document_id}/basic",get(get_document::get_document_basic_handler).layer(ensure_document_exists_middleware.clone()),).route(- "/documents/:document_id/export",+ "/documents/{document_id}/export",get(export_document::handler).layer(ensure_document_exists_middleware.clone()),).route(- "/documents/:document_id/text",+ "/documents/{document_id}/text",get(get_document_text::handler).layer(ensure_document_exists_middleware.clone()),).route(- "/documents/:document_id/full_pdf_modification_data",+ "/documents/{document_id}/full_pdf_modification_data",get(get_full_pdf_modification_data::handler).layer(ensure_document_exists_middleware.clone()),).route(- "/documents/:document_id/location",+ "/documents/{document_id}/location",get(location::get_location_handler).layer(ensure_document_exists_middleware.clone()),).route(- "/documents/:document_id/location_v3",+ "/documents/{document_id}/location_v3",get(documents_hex::inbound::axum_router::get_location_v3_handler::<DocumentService,@@ -88,11 +88,11 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {.layer(ensure_document_exists_middleware.clone()),).route(- "/documents/:document_id/permissions",+ "/documents/{document_id}/permissions",get(get_document_permissions::get_document_permissions_handler),).route(- "/documents/:document_id/access_level",+ "/documents/{document_id}/access_level",get(get_document_access_level::handler),).route(@@ -109,37 +109,37 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {get(list_documents_with_access::list_documents_with_access_handler),).route(- "/documents/:document_id",+ "/documents/{document_id}",put(save_document::save_document_handler).layer(ensure_document_exists_middleware.clone()),).route(- "/documents/:document_id/:document_version_id",+ "/documents/{document_id}/{document_version_id}",get(get_document_version::handler),).route(- "/documents/:document_id/:document_version_id/key",+ "/documents/{document_id}/{document_version_id}/key",get(get_document_key::get_document_key_handler).layer(ensure_document_exists_middleware.clone()),).route(- "/documents/:document_id/update",+ "/documents/{document_id}/update",put(put_document_update::handler),).route("/documents/metadata", post(get_documents_metadata::handler))// History routes.route(- "/history/:item_type/:item_id",+ "/history/{item_type}/{item_id}",post(upsert_history::upsert_history_handler).layer(ensure_user_exists_middleware.clone()),).route(- "/history/:item_type/:item_id",+ "/history/{item_type}/{item_id}",delete(delete_history::delete_history_handler).layer(ensure_user_exists_middleware.clone()),).route(- "/threads/:thread_id/access_level",+ "/threads/{thread_id}/access_level",get(get_thread_access_level::handler).layer(axum::middleware::from_fn_with_state(state.clone(),ensure_thread_exists::handler,diff --git a/rust/cloud-storage/document_storage_service/src/api/mod.rs b/rust/cloud-storage/document_storage_service/src/api/mod.rsindex f786ceecb2..ec5a1c91fe 100644--- a/rust/cloud-storage/document_storage_service/src/api/mod.rs+++ b/rust/cloud-storage/document_storage_service/src/api/mod.rs@@ -241,6 +241,6 @@ fn api_router(state: ApiContext) -> Router {).with_state(state);Router::new()- .nest("/:version", internal_router.clone())+ .nest("/{version}", internal_router.clone()).merge(internal_router)}diff --git a/rust/cloud-storage/document_storage_service/src/api/notification/mod.rs b/rust/cloud-storage/document_storage_service/src/api/notification/mod.rsindex 3213bd8a5e..f23d8fb2a9 100644--- a/rust/cloud-storage/document_storage_service/src/api/notification/mod.rs+++ b/rust/cloud-storage/document_storage_service/src/api/notification/mod.rs@@ -10,11 +10,11 @@ pub(in crate::api) mod get_project_notification_users;pub fn router() -> Router<ApiContext> {Router::new().route(- "/document/:document_id",+ "/document/{document_id}",get(get_document_notification_users::handler),).route(- "/project/:project_id",+ "/project/{project_id}",get(get_project_notification_users::handler),)}diff --git a/rust/cloud-storage/document_storage_service/src/api/pins/add_pin.rs b/rust/cloud-storage/document_storage_service/src/api/pins/add_pin.rsindex d232eab191..266a9ac49f 100644--- a/rust/cloud-storage/document_storage_service/src/api/pins/add_pin.rs+++ b/rust/cloud-storage/document_storage_service/src/api/pins/add_pin.rs@@ -21,7 +21,7 @@ pub struct Params {/// Pins the item for the user#[utoipa::path(post,- path = "/pins/:pinned_item_id",+ path = "/pins/{pinned_item_id}",params(("pinned_item_id" = String, Path, description = "ID of the pinned item")),diff --git a/rust/cloud-storage/document_storage_service/src/api/pins/mod.rs b/rust/cloud-storage/document_storage_service/src/api/pins/mod.rsindex fedd76926e..4eafb6a898 100644--- a/rust/cloud-storage/document_storage_service/src/api/pins/mod.rs+++ b/rust/cloud-storage/document_storage_service/src/api/pins/mod.rs@@ -13,8 +13,8 @@ pub(in crate::api) mod reorder_pins;pub fn router() -> Router<ApiContext> {Router::new().route("/", get(get_pins::get_pins_handler))- .route("/:pinned_item_id", post(add_pin::add_pin_handler))- .route("/:pinned_item_id", delete(remove_pin::remove_pin_handler))+ .route("/{pinned_item_id}", post(add_pin::add_pin_handler))+ .route("/{pinned_item_id}", delete(remove_pin::remove_pin_handler)).route("/", patch(reorder_pins::reorder_pins_handler)).layer(axum::middleware::from_fn(macro_middleware::auth::ensure_user_exists::handler,diff --git a/rust/cloud-storage/document_storage_service/src/api/pins/remove_pin.rs b/rust/cloud-storage/document_storage_service/src/api/pins/remove_pin.rsindex cb37c1fa12..3bc1be3314 100644--- a/rust/cloud-storage/document_storage_service/src/api/pins/remove_pin.rs+++ b/rust/cloud-storage/document_storage_service/src/api/pins/remove_pin.rs@@ -19,7 +19,7 @@ pub struct Params {/// Deletes the pin for the user#[utoipa::path(delete,- path = "/pins/:pinned_item_id",+ path = "/pins/{pinned_item_id}",params(("pinned_item_id" = String, Path, description = "ID of the pinned item")),diff --git a/rust/cloud-storage/document_storage_service/src/api/projects/mod.rs b/rust/cloud-storage/document_storage_service/src/api/projects/mod.rsindex f2082b9ea9..76b48359bb 100644--- a/rust/cloud-storage/document_storage_service/src/api/projects/mod.rs+++ b/rust/cloud-storage/document_storage_service/src/api/projects/mod.rs@@ -33,17 +33,17 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {)),).route(- "/:id/permissions",+ "/{id}/permissions",get(project_permission::get_project_permissions_handler).layer(ensure_project_exists_middleware.clone()),).route(- "/:id/access_level",+ "/{id}/access_level",get(project_permission::get_project_access_level_handler).layer(ensure_project_exists_middleware.clone()),).route(- "/:id/content",+ "/{id}/content",get(get_project::get_project_content_handler).layer(ensure_project_exists_middleware.clone()),)@@ -87,26 +87,26 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {),).route(- "/:id",+ "/{id}",patch(edit_project::edit_project_handler).layer(ensure_project_exists_middleware.clone()),).route(- "/:id/revert_delete",+ "/{id}/revert_delete",put(revert_delete_project::handler).layer(ensure_project_exists_middleware.clone()),).route(- "/:id",+ "/{id}",delete(delete_project::delete_project_handler).layer(ensure_project_exists_middleware.clone()),).route(- "/:id/permanent",+ "/{id}/permanent",delete(delete_project::permanently_delete_project_handler).layer(ensure_project_exists_middleware.clone()),).route(- "/:id",+ "/{id}",get(get_project::get_project_handler).layer(ensure_project_exists_middleware),).route(diff --git a/rust/cloud-storage/document_storage_service/src/api/saved_views.rs b/rust/cloud-storage/document_storage_service/src/api/saved_views.rsindex cb4df702fa..05ed9e0fb6 100644--- a/rust/cloud-storage/document_storage_service/src/api/saved_views.rs+++ b/rust/cloud-storage/document_storage_service/src/api/saved_views.rs@@ -1,10 +1,10 @@+use axum::Json;use axum::extract::{FromRef, FromRequestParts, Path, State};use axum::http::StatusCode;use axum::http::request::Parts;use axum::response::{IntoResponse, Response};use axum::routing::{delete, patch, post};use axum::{Extension, Router, routing::get};-use axum::{Json, async_trait};use model::response::ErrorResponse;use model::user::UserContext;use saved_views::{ExcludedDefaultViewStorage, PgViewStorage, ViewStorage};@@ -23,8 +23,8 @@ pub fn router() -> Router<ApiContext> {Router::new().route("/", get(get_views_handler)).route("/", post(create_view_handler))- .route("/:saved_view_id", delete(delete_view_handler))- .route("/:saved_view_id", patch(patch_view_handler))+ .route("/{saved_view_id}", delete(delete_view_handler))+ .route("/{saved_view_id}", patch(patch_view_handler)).route("/exclude_default", post(exclude_default_view_handler))}@@ -112,7 +112,6 @@ async fn authorize_view_access(#[derive(Debug)]struct SavedViewOwner(pub UserContext);-#[async_trait]impl<S> FromRequestParts<S> for SavedViewOwnerwhereS: Send + Sync,diff --git a/rust/cloud-storage/document_storage_service/src/api/threads/mod.rs b/rust/cloud-storage/document_storage_service/src/api/threads/mod.rsindex f9cd817458..fef76956b1 100644--- a/rust/cloud-storage/document_storage_service/src/api/threads/mod.rs+++ b/rust/cloud-storage/document_storage_service/src/api/threads/mod.rs@@ -7,7 +7,7 @@ use axum::routing::patch;pub fn router(state: ApiContext) -> Router<ApiContext> {Router::new().route(- "/:thread_id",+ "/{thread_id}",patch(edit_thread::edit_thread_handler).layer(axum::middleware::from_fn_with_state(state,macro_middleware::cloud_storage::thread::ensure_thread_exists::handler,diff --git a/rust/cloud-storage/document_storage_service/src/api/user_document_view_location/mod.rs b/rust/cloud-storage/document_storage_service/src/api/user_document_view_location/mod.rsindex 96c1c52dcd..63ba251b47 100644--- a/rust/cloud-storage/document_storage_service/src/api/user_document_view_location/mod.rs+++ b/rust/cloud-storage/document_storage_service/src/api/user_document_view_location/mod.rs@@ -11,15 +11,15 @@ pub(in crate::api) mod upsert_user_document_view_location;pub fn router(state: ApiContext) -> Router<ApiContext> {Router::new().route(- "/:document_id",+ "/{document_id}",get(get_user_document_view_location::handler),).route(- "/:document_id",+ "/{document_id}",post(upsert_user_document_view_location::handler),).route(- "/:document_id",+ "/{document_id}",delete(delete_user_document_view_location::handler),).layer(axum::middleware::from_fn_with_state(diff --git a/rust/cloud-storage/documents/src/inbound/axum_router.rs b/rust/cloud-storage/documents/src/inbound/axum_router.rsindex 8525896dfa..5af3efaa13 100644--- a/rust/cloud-storage/documents/src/inbound/axum_router.rs+++ b/rust/cloud-storage/documents/src/inbound/axum_router.rs@@ -2,10 +2,10 @@//!//! Provides routes://! - `POST /` — create a new document-//! - `GET /:document_id` — get document metadata-//! - `GET /:document_id/location_v3` — get document content location (presigned URL)-//! - `GET /:document_id/short_id` — get document short ID-//! - `DELETE /:document_id` — soft-delete a document+//! - `GET /{document_id}` — get document metadata+//! - `GET /{document_id}/location_v3` — get document content location (presigned URL)+//! - `GET /{document_id}/short_id` — get document short ID+//! - `DELETE /{document_id}` — soft-delete a document#[cfg(test)]mod tests;@@ -106,17 +106,17 @@ where// Routes that need ensure_document_exists middlewarelet document_id_routes = Router::new().route(- "/:document_id",+ "/{document_id}",axum::routing::get(get_document_handler::<T, Svc>).patch(edit_document_handler::<T, Svc>).delete(delete_document_handler::<T, Svc>),).route(- "/:document_id/location_v3",+ "/{document_id}/location_v3",axum::routing::get(get_location_v3_handler::<T, Svc>),).route(- "/:document_id/short_id",+ "/{document_id}/short_id",axum::routing::get(get_short_id_handler::<T, Svc>),).layer(middleware::from_fn_with_state(diff --git a/rust/cloud-storage/documents/src/inbound/axum_router/delete_document.rs b/rust/cloud-storage/documents/src/inbound/axum_router/delete_document.rsindex 48648b960e..d03cdcaa10 100644--- a/rust/cloud-storage/documents/src/inbound/axum_router/delete_document.rs+++ b/rust/cloud-storage/documents/src/inbound/axum_router/delete_document.rs@@ -1,4 +1,4 @@-//! Handler for `DELETE /documents/:document_id`.+//! Handler for `DELETE /documents/{document_id}`.use axum::{Extension, Json,@@ -15,7 +15,7 @@ use super::{DocumentRouterState, Params};use crate::domain::models::DocumentError;use crate::domain::ports::DocumentService;-/// Handler for `DELETE /documents/:document_id`.+/// Handler for `DELETE /documents/{document_id}`.////// Soft-deletes a document (only owners can delete).#[utoipa::path(diff --git a/rust/cloud-storage/documents/src/inbound/axum_router/edit_document.rs b/rust/cloud-storage/documents/src/inbound/axum_router/edit_document.rsindex 4b4b848b88..b0ef579c35 100644--- a/rust/cloud-storage/documents/src/inbound/axum_router/edit_document.rs+++ b/rust/cloud-storage/documents/src/inbound/axum_router/edit_document.rs@@ -1,4 +1,4 @@-//! Handler for `PATCH /documents/:document_id`.+//! Handler for `PATCH /documents/{document_id}`.use axum::{Extension, Json,@@ -25,7 +25,7 @@ pub struct EditDocumentResponse {pub data: GenericSuccessResponse,}-/// Handler for `PATCH /documents/:document_id`.+/// Handler for `PATCH /documents/{document_id}`.////// Edits document metadata such as name or project, and modifies/// the document's share permissions. Requires edit access to the document,diff --git a/rust/cloud-storage/documents/src/inbound/axum_router/get_document.rs b/rust/cloud-storage/documents/src/inbound/axum_router/get_document.rsindex f1575e36ca..56a3303166 100644--- a/rust/cloud-storage/documents/src/inbound/axum_router/get_document.rs+++ b/rust/cloud-storage/documents/src/inbound/axum_router/get_document.rs@@ -1,4 +1,4 @@-//! Handler for `GET /documents/:document_id`.+//! Handler for `GET /documents/{document_id}`.use axum::{Extension, Json,@@ -14,7 +14,7 @@ use super::{DocumentRouterState, Params};use crate::domain::models::DocumentError;use crate::domain::ports::DocumentService;-/// Handler for `GET /documents/:document_id`.+/// Handler for `GET /documents/{document_id}`.////// Returns document metadata, user access level, and view location.#[utoipa::path(diff --git a/rust/cloud-storage/documents/src/inbound/axum_router/get_location.rs b/rust/cloud-storage/documents/src/inbound/axum_router/get_location.rsindex ad8f1c14e3..83828f49a4 100644--- a/rust/cloud-storage/documents/src/inbound/axum_router/get_location.rs+++ b/rust/cloud-storage/documents/src/inbound/axum_router/get_location.rs@@ -1,4 +1,4 @@-//! Handler for `GET /documents/:document_id/location_v3`.+//! Handler for `GET /documents/{document_id}/location_v3`.use axum::{Extension, Json,@@ -15,7 +15,7 @@ use super::{DocumentRouterState, Params};use crate::domain::models::{DocumentError, LocationQueryParams};use crate::domain::ports::DocumentService;-/// Handler for `GET /documents/:document_id/location_v3`.+/// Handler for `GET /documents/{document_id}/location_v3`.////// Returns a presigned URL or sync service content for accessing the document.#[utoipa::path(diff --git a/rust/cloud-storage/documents/src/inbound/axum_router/get_short_id.rs b/rust/cloud-storage/documents/src/inbound/axum_router/get_short_id.rsindex 8a7546652d..b32782b9c2 100644--- a/rust/cloud-storage/documents/src/inbound/axum_router/get_short_id.rs+++ b/rust/cloud-storage/documents/src/inbound/axum_router/get_short_id.rs@@ -1,4 +1,4 @@-//! Handler for `GET /documents/:document_id/short_id`.+//! Handler for `GET /documents/{document_id}/short_id`.use axum::{Json,@@ -20,7 +20,7 @@ pub struct ShortIdResponse {short_id: String,}-/// Handler for `GET /documents/:document_id/short_id`.+/// Handler for `GET /documents/{document_id}/short_id`.////// Returns the short UUID for a document.#[utoipa::path(diff --git a/rust/cloud-storage/email/src/inbound/axum/axum_impls.rs b/rust/cloud-storage/email/src/inbound/axum/axum_impls.rsindex a51efe9f27..6bc0b01921 100644--- a/rust/cloud-storage/email/src/inbound/axum/axum_impls.rs+++ b/rust/cloud-storage/email/src/inbound/axum/axum_impls.rs@@ -6,7 +6,7 @@ use crate::{inbound::{ApiSortMethod, EmailRouterState},};use axum::{- RequestPartsExt, async_trait,+ RequestPartsExt,extract::{FromRef, FromRequestParts, Path, rejection::PathRejection},http::{StatusCode, request::Parts},response::{IntoResponse, Response},@@ -48,7 +48,6 @@ impl IntoResponse for GetPreviewsCursorError {pub(crate) struct PreviewViewPathExtractor(pub PreviewView);-#[async_trait]impl<S: Send + Sync> FromRequestParts<S> for PreviewViewPathExtractor {type Rejection = GetPreviewsCursorError;@@ -102,7 +101,6 @@ impl IntoResponse for EmailLinkErr {}}-#[async_trait]impl<S, U> FromRequestParts<S> for EmailLinkExtractor<U>whereEmailRouterState<U>: FromRef<S>,@@ -136,7 +134,6 @@ impl<U> Clone for OptionalEmailLinkExtractor<U> {}}-#[async_trait]impl<S, U> FromRequestParts<S> for OptionalEmailLinkExtractor<U>whereEmailRouterState<U>: FromRef<S>,@@ -230,7 +227,6 @@ impl IntoResponse for GmailAccessTokenErr {}}-#[async_trait]impl<S, U, V> FromRequestParts<S> for GmailAccessTokenExtractor<U, V>whereEmailRouterState<U>: FromRef<S>,diff --git a/rust/cloud-storage/email/src/inbound/axum/get_thread_router.rs b/rust/cloud-storage/email/src/inbound/axum/get_thread_router.rsindex 18f6df69b5..e74563a29f 100644--- a/rust/cloud-storage/email/src/inbound/axum/get_thread_router.rs+++ b/rust/cloud-storage/email/src/inbound/axum/get_thread_router.rs@@ -49,7 +49,7 @@ whereSvc: EntityAccessService,{Router::new()- .route("/:thread_id", get(get_thread_handler::<T, Svc>))+ .route("/{thread_id}", get(get_thread_handler::<T, Svc>)).with_state(state)}diff --git a/rust/cloud-storage/email/src/inbound/axum/previews_router.rs b/rust/cloud-storage/email/src/inbound/axum/previews_router.rsindex 69c2bee080..1d5df12eb5 100644--- a/rust/cloud-storage/email/src/inbound/axum/previews_router.rs+++ b/rust/cloud-storage/email/src/inbound/axum/previews_router.rs@@ -54,7 +54,7 @@ whereT: EmailService,{Router::new()- .route("/cursor/:view", get(cursor_handler))+ .route("/cursor/{view}", get(cursor_handler)).with_state(state)}diff --git a/rust/cloud-storage/email/src/inbound/axum/thread_labels_router.rs b/rust/cloud-storage/email/src/inbound/axum/thread_labels_router.rsindex aff27091bd..6da2595d7a 100644--- a/rust/cloud-storage/email/src/inbound/axum/thread_labels_router.rs+++ b/rust/cloud-storage/email/src/inbound/axum/thread_labels_router.rs@@ -69,7 +69,7 @@ impl From<EmailErr> for UpdateThreadLabelError {}}-/// Create the thread labels router with a `PATCH /:id/labels` handler.+/// Create the thread labels router with a `PATCH /{id}/labels` handler.pub fn thread_labels_router<S, T, G>() -> Router<S>whereS: Send + Sync + Clone + 'static,@@ -78,7 +78,7 @@ whereEmailRouterState<T>: axum::extract::FromRef<S>,GmailTokenState<G>: axum::extract::FromRef<S>,{- Router::new().route("/:id/labels", patch(update_thread_labels_handler::<T, G>))+ Router::new().route("/{id}/labels", patch(update_thread_labels_handler::<T, G>))}/// Add or remove a label from all messages in a thread.diff --git a/rust/cloud-storage/email_db_client/.sqlx/query-83f2f13e4b5dba3ece419b618a2e4402baa3c61a921570ff7cb0fb92e0a211ee.json b/rust/cloud-storage/email_db_client/.sqlx/query-83f2f13e4b5dba3ece419b618a2e4402baa3c61a921570ff7cb0fb92e0a211ee.jsondeleted file mode 100644index e49f80eaaf..0000000000--- a/rust/cloud-storage/email_db_client/.sqlx/query-83f2f13e4b5dba3ece419b618a2e4402baa3c61a921570ff7cb0fb92e0a211ee.json+++ /dev/null@@ -1,33 +0,0 @@-{- "db_name": "PostgreSQL",- "query": "\n INSERT INTO email_messages (\n id, provider_id, link_id, thread_id, provider_thread_id,\n replying_to_id, subject, from_contact_id, sent_at,\n has_attachments, is_read, is_starred, is_sent, is_draft,\n body_text, body_html_sanitized, body_macro, headers_jsonb,\n created_at, updated_at\n )\n VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15, $16, $17, $18, $19, $20)\n ON CONFLICT (id) DO UPDATE SET\n id = EXCLUDED.id,\n provider_id = EXCLUDED.provider_id,\n thread_id = EXCLUDED.thread_id,\n provider_thread_id = EXCLUDED.provider_thread_id,\n replying_to_id = EXCLUDED.replying_to_id,\n provider_history_id = EXCLUDED.provider_history_id,\n subject = EXCLUDED.subject,\n from_contact_id = EXCLUDED.from_contact_id,\n sent_at = EXCLUDED.sent_at,\n has_attachments = EXCLUDED.has_attachments,\n is_read = EXCLUDED.is_read,\n is_starred = EXCLUDED.is_starred,\n is_sent = EXCLUDED.is_sent,\n is_draft = EXCLUDED.is_draft,\n body_text = EXCLUDED.body_text,\n body_html_sanitized = EXCLUDED.body_html_sanitized,\n body_macro = EXCLUDED.body_macro,\n headers_jsonb = EXCLUDED.headers_jsonb,\n updated_at = NOW()\n ",- "describe": {- "columns": [],- "parameters": {- "Left": [- "Uuid",- "Text",- "Uuid",- "Uuid",- "Text",- "Uuid",- "Text",- "Uuid",- "Timestamptz",- "Bool",- "Bool",- "Bool",- "Bool",- "Bool",- "Text",- "Text",- "Text",- "Jsonb",- "Timestamptz",- "Timestamptz"- ]- },- "nullable": []- },- "hash": "83f2f13e4b5dba3ece419b618a2e4402baa3c61a921570ff7cb0fb92e0a211ee"-}diff --git a/rust/cloud-storage/email_db_client/.sqlx/query-b8b844a48297ecdd487dde0f6057c97793378b825cf227dd6f891e27e87a987a.json b/rust/cloud-storage/email_db_client/.sqlx/query-b8b844a48297ecdd487dde0f6057c97793378b825cf227dd6f891e27e87a987a.jsondeleted file mode 100644index ca5719693b..0000000000--- a/rust/cloud-storage/email_db_client/.sqlx/query-b8b844a48297ecdd487dde0f6057c97793378b825cf227dd6f891e27e87a987a.json+++ /dev/null@@ -1,174 +0,0 @@-{- "db_name": "PostgreSQL",- "query": "\n SELECT\n id,\n provider_id,\n global_id,\n thread_id,\n provider_thread_id,\n replying_to_id,\n link_id,\n provider_history_id,\n internal_date_ts,\n snippet,\n size_estimate,\n subject,\n from_name,\n from_contact_id,\n sent_at,\n has_attachments,\n is_read,\n is_starred,\n is_sent,\n is_draft,\n body_text,\n body_html_sanitized,\n body_macro,\n headers_jsonb,\n created_at,\n updated_at\n FROM email_messages\n WHERE thread_id = $1\n ORDER BY internal_date_ts DESC\n LIMIT $2 OFFSET $3\n ",- "describe": {- "columns": [- {- "ordinal": 0,- "name": "id",- "type_info": "Uuid"- },- {- "ordinal": 1,- "name": "provider_id",- "type_info": "Text"- },- {- "ordinal": 2,- "name": "global_id",- "type_info": "Text"- },- {- "ordinal": 3,- "name": "thread_id",- "type_info": "Uuid"- },- {- "ordinal": 4,- "name": "provider_thread_id",- "type_info": "Text"- },- {- "ordinal": 5,- "name": "replying_to_id",- "type_info": "Uuid"- },- {- "ordinal": 6,- "name": "link_id",- "type_info": "Uuid"- },- {- "ordinal": 7,- "name": "provider_history_id",- "type_info": "Text"- },- {- "ordinal": 8,- "name": "internal_date_ts",- "type_info": "Timestamptz"- },- {- "ordinal": 9,- "name": "snippet",- "type_info": "Text"- },- {- "ordinal": 10,- "name": "size_estimate",- "type_info": "Int8"- },- {- "ordinal": 11,- "name": "subject",- "type_info": "Text"- },- {- "ordinal": 12,- "name": "from_name",- "type_info": "Varchar"- },- {- "ordinal": 13,- "name": "from_contact_id",- "type_info": "Uuid"- },- {- "ordinal": 14,- "name": "sent_at",- "type_info": "Timestamptz"- },- {- "ordinal": 15,- "name": "has_attachments",- "type_info": "Bool"- },- {- "ordinal": 16,- "name": "is_read",- "type_info": "Bool"- },- {- "ordinal": 17,- "name": "is_starred",- "type_info": "Bool"- },- {- "ordinal": 18,- "name": "is_sent",- "type_info": "Bool"- },- {- "ordinal": 19,- "name": "is_draft",- "type_info": "Bool"- },- {- "ordinal": 20,- "name": "body_text",- "type_info": "Text"- },- {- "ordinal": 21,- "name": "body_html_sanitized",- "type_info": "Text"- },- {- "ordinal": 22,- "name": "body_macro",- "type_info": "Text"- },- {- "ordinal": 23,- "name": "headers_jsonb",- "type_info": "Jsonb"- },- {- "ordinal": 24,- "name": "created_at",- "type_info": "Timestamptz"- },- {- "ordinal": 25,- "name": "updated_at",- "type_info": "Timestamptz"- }- ],- "parameters": {- "Left": [- "Uuid",- "Int8",- "Int8"- ]- },- "nullable": [- false,- true,- true,- false,- true,- true,- false,- true,- true,- true,- true,- true,- true,- true,- true,- false,- false,- false,- false,- false,- true,- true,- true,- true,- false,- false- ]- },- "hash": "b8b844a48297ecdd487dde0f6057c97793378b825cf227dd6f891e27e87a987a"-}diff --git a/rust/cloud-storage/email_db_client/.sqlx/query-dd15fda96e1b98735b60511816fd12960fa5e0a348b924edd568855e0060d01b.json b/rust/cloud-storage/email_db_client/.sqlx/query-dd15fda96e1b98735b60511816fd12960fa5e0a348b924edd568855e0060d01b.jsondeleted file mode 100644index 35cf32f7eb..0000000000--- a/rust/cloud-storage/email_db_client/.sqlx/query-dd15fda96e1b98735b60511816fd12960fa5e0a348b924edd568855e0060d01b.json+++ /dev/null@@ -1,76 +0,0 @@-{- "db_name": "PostgreSQL",- "query": "\n SELECT t.id, t.provider_id, t.link_id, t.inbox_visible, t.is_read,\n t.latest_inbound_message_ts, t.latest_outbound_message_ts,\n t.latest_non_spam_message_ts, t.created_at, t.updated_at\n FROM email_threads t\n WHERE t.id = $1\n ",- "describe": {- "columns": [- {- "ordinal": 0,- "name": "id",- "type_info": "Uuid"- },- {- "ordinal": 1,- "name": "provider_id",- "type_info": "Text"- },- {- "ordinal": 2,- "name": "link_id",- "type_info": "Uuid"- },- {- "ordinal": 3,- "name": "inbox_visible",- "type_info": "Bool"- },- {- "ordinal": 4,- "name": "is_read",- "type_info": "Bool"- },- {- "ordinal": 5,- "name": "latest_inbound_message_ts",- "type_info": "Timestamptz"- },- {- "ordinal": 6,- "name": "latest_outbound_message_ts",- "type_info": "Timestamptz"- },- {- "ordinal": 7,- "name": "latest_non_spam_message_ts",- "type_info": "Timestamptz"- },- {- "ordinal": 8,- "name": "created_at",- "type_info": "Timestamptz"- },- {- "ordinal": 9,- "name": "updated_at",- "type_info": "Timestamptz"- }- ],- "parameters": {- "Left": [- "Uuid"- ]- },- "nullable": [- false,- true,- false,- false,- false,- true,- true,- true,- false,- false- ]- },- "hash": "dd15fda96e1b98735b60511816fd12960fa5e0a348b924edd568855e0060d01b"-}diff --git a/rust/cloud-storage/email_service/src/api/email/attachments/mod.rs b/rust/cloud-storage/email_service/src/api/email/attachments/mod.rsindex 9fb5b16147..3374e432eb 100644--- a/rust/cloud-storage/email_service/src/api/email/attachments/mod.rs+++ b/rust/cloud-storage/email_service/src/api/email/attachments/mod.rs@@ -9,8 +9,8 @@ pub(crate) mod get_document_id;pub fn router(state: ApiContext) -> Router<ApiContext> {Router::new()- .route("/:id", get(get::handler))- .route("/:id/document_id", get(get_document_id::handler))+ .route("/{id}", get(get::handler))+ .route("/{id}/document_id", get(get_document_id::handler)).layer(ServiceBuilder::new().layer(axum::middleware::from_fn_with_state(diff --git a/rust/cloud-storage/email_service/src/api/email/backfill/mod.rs b/rust/cloud-storage/email_service/src/api/email/backfill/mod.rsindex 63ea0e2f89..6d5bb5f0f8 100644--- a/rust/cloud-storage/email_service/src/api/email/backfill/mod.rs+++ b/rust/cloud-storage/email_service/src/api/email/backfill/mod.rs@@ -9,7 +9,7 @@ use crate::api::ApiContext;pub fn router(state: ApiContext) -> Router<ApiContext> {Router::new().route("/gmail", delete(cancel::handler))- .route("/gmail/:id", get(get::handler))+ .route("/gmail/{id}", get(get::handler)).route("/gmail/active", get(get::active_handler)).layer(axum::middleware::from_fn_with_state(state.email_service,diff --git a/rust/cloud-storage/email_service/src/api/email/drafts/mod.rs b/rust/cloud-storage/email_service/src/api/email/drafts/mod.rsindex 2898cf6124..2b6e6cb64b 100644--- a/rust/cloud-storage/email_service/src/api/email/drafts/mod.rs+++ b/rust/cloud-storage/email_service/src/api/email/drafts/mod.rs@@ -14,18 +14,18 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {Router::new().merge(draft_router(state.email_service.clone())).nest("/scheduled", scheduled::router())- .route("/:id", delete(delete::handler))- .route("/:id/attachments", post(add_attachment::handler))+ .route("/{id}", delete(delete::handler))+ .route("/{id}/attachments", post(add_attachment::handler)).route(- "/:id/attachments/:attachment_id",+ "/{id}/attachments/{attachment_id}",delete(remove_attachment::handler),).route(- "/:id/forwarded-attachments",+ "/{id}/forwarded-attachments",post(add_forwarded_attachment::handler),).route(- "/:id/forwarded-attachments/:attachment_id",+ "/{id}/forwarded-attachments/{attachment_id}",delete(remove_forwarded_attachment::handler),).layer(axum::middleware::from_fn_with_state(diff --git a/rust/cloud-storage/email_service/src/api/email/drafts/scheduled/mod.rs b/rust/cloud-storage/email_service/src/api/email/drafts/scheduled/mod.rsindex 49084b28d1..e6ef794c70 100644--- a/rust/cloud-storage/email_service/src/api/email/drafts/scheduled/mod.rs+++ b/rust/cloud-storage/email_service/src/api/email/drafts/scheduled/mod.rs@@ -7,7 +7,8 @@ pub(crate) mod remove;pub(crate) mod upsert;pub fn router() -> Router<ApiContext> {- Router::new()- .route("/", get(list::handler))- .route("/:message_id", delete(remove::handler).put(upsert::handler))+ Router::new().route("/", get(list::handler)).route(+ "/{message_id}",+ delete(remove::handler).put(upsert::handler),+ )}diff --git a/rust/cloud-storage/email_service/src/api/email/labels/mod.rs b/rust/cloud-storage/email_service/src/api/email/labels/mod.rsindex b728edae09..38a574fbe2 100644--- a/rust/cloud-storage/email_service/src/api/email/labels/mod.rs+++ b/rust/cloud-storage/email_service/src/api/email/labels/mod.rs@@ -12,7 +12,7 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {Router::new().route("/", post(create::handler))- .route("/:id", delete(delete::handler))+ .route("/{id}", delete(delete::handler)).layer(axum::middleware::from_fn_with_state(state.clone(),crate::api::middleware::gmail_token::attach_gmail_token,diff --git a/rust/cloud-storage/email_service/src/api/email/messages/mod.rs b/rust/cloud-storage/email_service/src/api/email/messages/mod.rsindex 196a76c0ca..fdd74c650e 100644--- a/rust/cloud-storage/email_service/src/api/email/messages/mod.rs+++ b/rust/cloud-storage/email_service/src/api/email/messages/mod.rs@@ -24,5 +24,5 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {state.email_service,crate::api::middleware::link::attach_link_context,))- .route("/:id", get(get::handler))+ .route("/{id}", get(get::handler))}diff --git a/rust/cloud-storage/email_service/src/api/email/threads/mod.rs b/rust/cloud-storage/email_service/src/api/email/threads/mod.rsindex 9caeb57550..8da43f5c16 100644--- a/rust/cloud-storage/email_service/src/api/email/threads/mod.rs+++ b/rust/cloud-storage/email_service/src/api/email/threads/mod.rs@@ -15,15 +15,15 @@ pub fn router(state: ApiContext) -> Router<ApiContext> {email::inbound::router(state.email_service.clone()),).route(- "/:id/seen",+ "/{id}/seen",post(seen::seen_handler).layer(axum::middleware::from_fn_with_state(state.clone(),crate::api::middleware::gmail_token::attach_gmail_token,)),)- .route("/:id/messages", get(get::get_thread_messages_handler))+ .route("/{id}/messages", get(get::get_thread_messages_handler)).route(- "/:id/archived",+ "/{id}/archived",patch(archived::archived_handler).layer(ServiceBuilder::new().layer(axum::middleware::from_fn_with_state(state.clone(),diff --git a/rust/cloud-storage/email_service/src/api/internal/mod.rs b/rust/cloud-storage/email_service/src/api/internal/mod.rsindex d4c7fb5101..50981f2bb4 100644--- a/rust/cloud-storage/email_service/src/api/internal/mod.rs+++ b/rust/cloud-storage/email_service/src/api/internal/mod.rs@@ -13,7 +13,7 @@ mod gmail;pub fn router() -> Router<ApiContext> {Router::new()- .route("/messages/:id", get(get_message_by_id::handler))+ .route("/messages/{id}", get(get_message_by_id::handler)).route("/messages/batch",post(get_message_by_id::get_message_by_id_batch_handler),@@ -21,12 +21,12 @@ pub fn router() -> Router<ApiContext> {.route("/messages/senders", post(get_message_senders::handler)).route("/threads/histories", post(get_thread_histories::handler)).route(- "/threads/:id/messages",+ "/threads/{id}/messages",get(get_messages_by_thread_id::handler),).route("/backfill/provider/gmail", post(gmail::create::handler)).route("/backfill/provider/gmail", delete(gmail::cancel::handler))- .route("/backfill/provider/gmail/:id", get(gmail::get::handler))- .route("/delete_user/:id", delete(delete_user::handler))- .route("/threads/:id/owner", get(get_thread_owner::handler))+ .route("/backfill/provider/gmail/{id}", get(gmail::get::handler))+ .route("/delete_user/{id}", delete(delete_user::handler))+ .route("/threads/{id}/owner", get(get_thread_owner::handler))}diff --git a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/channel.rs b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/channel.rsindex 563d614fb4..6710e9d15e 100644--- a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/channel.rs+++ b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/channel.rs@@ -4,7 +4,7 @@ use std::marker::PhantomData;use std::sync::Arc;use axum::{- Extension, RequestPartsExt, async_trait,+ Extension, RequestPartsExt,extract::{FromRef, FromRequestParts, Path},http::request::Parts,};@@ -35,7 +35,6 @@ pub struct ChannelAccessLevelExtractor<T: RequiredPermission, Svc> {_marker: PhantomData<(T, Svc)>,}-#[async_trait]impl<T, S, Svc> FromRequestParts<S> for ChannelAccessLevelExtractor<T, Svc>whereT: RequiredPermission,diff --git a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/chat.rs b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/chat.rsindex e19df25093..6154c070e5 100644--- a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/chat.rs+++ b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/chat.rs@@ -4,7 +4,7 @@ use std::marker::PhantomData;use std::sync::Arc;use axum::{- Extension, RequestPartsExt, async_trait,+ Extension, RequestPartsExt,extract::{FromRef, FromRequestParts},http::request::Parts,};@@ -34,7 +34,6 @@ pub struct ChatAccessLevelExtractor<T: RequiredPermission, Svc> {_marker: PhantomData<(T, Svc)>,}-#[async_trait]impl<T, S, Svc> FromRequestParts<S> for ChatAccessLevelExtractor<T, Svc>whereT: RequiredPermission,diff --git a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/document.rs b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/document.rsindex 194b92b85b..8018c9013d 100644--- a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/document.rs+++ b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/document.rs@@ -4,7 +4,7 @@ use std::marker::PhantomData;use std::sync::Arc;use axum::{- Extension, RequestPartsExt, async_trait,+ Extension, RequestPartsExt,extract::{FromRef, FromRequestParts},http::request::Parts,};@@ -39,7 +39,6 @@ pub struct DocumentAccessExtractor<T: RequiredPermission, Svc> {_marker: PhantomData<(T, Svc)>,}-#[async_trait]impl<T, S, Svc> FromRequestParts<S> for DocumentAccessExtractor<T, Svc>whereT: RequiredPermission,diff --git a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/entity_permission.rs b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/entity_permission.rsindex b3b35b6ec1..a52bff0ddf 100644--- a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/entity_permission.rs+++ b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/entity_permission.rs@@ -4,7 +4,7 @@ use std::marker::PhantomData;use std::sync::Arc;use axum::{- Extension, RequestPartsExt, async_trait,+ Extension, RequestPartsExt,extract::{FromRef, FromRequestParts, Path},http::request::Parts,};@@ -37,7 +37,6 @@ pub struct EntityPermissionExtractor<Svc> {_marker: PhantomData<Svc>,}-#[async_trait]impl<S, Svc> FromRequestParts<S> for EntityPermissionExtractor<Svc>whereArc<Svc>: FromRef<S>,diff --git a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/history.rs b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/history.rsindex 162d5a01e4..a90342faef 100644--- a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/history.rs+++ b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/history.rs@@ -4,7 +4,7 @@ use std::marker::PhantomData;use std::sync::Arc;use axum::{- Extension, RequestPartsExt, async_trait,+ Extension, RequestPartsExt,extract::{FromRef, FromRequestParts, Path},http::request::Parts,};@@ -37,7 +37,6 @@ pub struct HistoryAccessExtractor<T: RequiredPermission, Svc> {_marker: PhantomData<(T, Svc)>,}-#[async_trait]impl<T, S, Svc> FromRequestParts<S> for HistoryAccessExtractor<T, Svc>whereT: RequiredPermission,diff --git a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/project.rs b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/project.rsindex 003f09afee..fc980d5d3e 100644--- a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/project.rs+++ b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/project.rs@@ -4,7 +4,7 @@ use std::marker::PhantomData;use std::sync::Arc;use axum::{- Extension, Json, RequestExt, RequestPartsExt, async_trait,+ Extension, Json, RequestExt, RequestPartsExt,extract::{FromRef, FromRequest, FromRequestParts, Request},http::request::Parts,};@@ -35,7 +35,6 @@ pub struct ProjectAccessLevelExtractor<T: RequiredPermission, Svc> {_marker: PhantomData<(T, Svc)>,}-#[async_trait]impl<T, S, Svc> FromRequestParts<S> for ProjectAccessLevelExtractor<T, Svc>whereT: RequiredPermission,@@ -228,7 +227,6 @@ impl<T: RequiredPermission, V, Svc> ProjectBodyAccessLevelExtractor<T, V, Svc> {}}-#[async_trait]impl<T, S, V, Svc> FromRequest<S> for ProjectBodyAccessLevelExtractor<T, V, Svc>whereT: RequiredPermission,diff --git a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/thread.rs b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/thread.rsindex 45564d539f..4a1f0c7cc3 100644--- a/rust/cloud-storage/entity_access/src/inbound/axum_extractors/thread.rs+++ b/rust/cloud-storage/entity_access/src/inbound/axum_extractors/thread.rs@@ -5,7 +5,7 @@ use std::marker::PhantomData;use std::sync::Arc;use axum::{- Extension, RequestPartsExt, async_trait,+ Extension, RequestPartsExt,extract::{FromRef, FromRequestParts, Path},http::request::Parts,};@@ -32,7 +32,6 @@ pub struct ThreadAccessLevelExtractor<T: RequiredPermission, Svc> {_marker: PhantomData<(T, Svc)>,}-#[async_trait]impl<T, S, Svc> FromRequestParts<S> for ThreadAccessLevelExtractor<T, Svc>whereT: RequiredPermission,diff --git a/rust/cloud-storage/github/.sqlx/query-28c518d844cd4d843c097af1551f6f384a4763514d278b5444341390f58a8281.json b/rust/cloud-storage/github/.sqlx/query-28c518d844cd4d843c097af1551f6f384a4763514d278b5444341390f58a8281.jsonnew file mode 100644index 0000000000..98ceb2aeec--- /dev/null+++ b/rust/cloud-storage/github/.sqlx/query-28c518d844cd4d843c097af1551f6f384a4763514d278b5444341390f58a8281.json@@ -0,0 +1,14 @@+{+ "db_name": "PostgreSQL",+ "query": "UPDATE \"Project\" SET \"updatedAt\" = NOW() WHERE id = $1",+ "describe": {+ "columns": [],+ "parameters": {+ "Left": [+ "Text"+ ]+ },+ "nullable": []+ },+ "hash": "28c518d844cd4d843c097af1551f6f384a4763514d278b5444341390f58a8281"+}diff --git a/rust/cloud-storage/github/.sqlx/query-37b5168f739c490a3373c65eab35f247a34af0a8e659cbad61cb99e3094e5a60.json b/rust/cloud-storage/github/.sqlx/query-37b5168f739c490a3373c65eab35f247a34af0a8e659cbad61cb99e3094e5a60.jsonnew file mode 100644index 0000000000..44d3a67e72--- /dev/null+++ b/rust/cloud-storage/github/.sqlx/query-37b5168f739c490a3373c65eab35f247a34af0a8e659cbad61cb99e3094e5a60.json@@ -0,0 +1,23 @@+{+ "db_name": "PostgreSQL",+ "query": "\n SELECT EXISTS (\n SELECT 1\n FROM public.email_threads t\n JOIN public.email_links l ON l.id = t.link_id\n WHERE t.id = $1::uuid\n AND l.macro_id = $2\n ) AS \"exists!\"\n ",+ "describe": {+ "columns": [+ {+ "ordinal": 0,+ "name": "exists!",+ "type_info": "Bool"+ }+ ],+ "parameters": {+ "Left": [+ "Uuid",+ "Text"+ ]+ },+ "nullable": [+ null+ ]+ },+ "hash": "37b5168f739c490a3373c65eab35f247a34af0a8e659cbad61cb99e3094e5a60"+}diff --git a/rust/cloud-storage/github/.sqlx/query-3a7be99469ed150e0506efa786b672198a6d3419c6bd5548418520cd3e6a8e95.json b/rust/cloud-storage/github/.sqlx/query-3a7be99469ed150e0506efa786b672198a6d3419c6bd5548418520cd3e6a8e95.jsonnew file mode 100644index 0000000000..60bfee0647--- /dev/null+++ b/rust/cloud-storage/github/.sqlx/query-3a7be99469ed150e0506efa786b672198a6d3419c6bd5548418520cd3e6a8e95.json@@ -0,0 +1,23 @@+{+ "db_name": "PostgreSQL",+ "query": "\n WITH RECURSIVE project_hierarchy AS (\n SELECT p.id as project_id\n FROM \"Document\" d\n JOIN \"Project\" p ON d.\"projectId\" = p.id AND p.\"deletedAt\" IS NULL\n WHERE d.id = $1 AND d.\"deletedAt\" IS NULL\n UNION ALL\n SELECT parent.id as project_id\n FROM project_hierarchy ph\n JOIN \"Project\" parent ON parent.id = (\n SELECT \"parentId\" FROM \"Project\" WHERE id = ph.project_id AND \"parentId\" IS NOT NULL AND \"deletedAt\" IS NULL\n )\n )\n SELECT access_level FROM (\n -- Source 1: Cast the AccessLevel enum to text.\n SELECT access_level::text FROM \"UserItemAccess\"\n WHERE user_id = $2 AND item_id IN (\n SELECT $1\n UNION\n SELECT project_id FROM project_hierarchy\n )\n UNION ALL\n -- Source 2: Select the publicAccessLevel (which is already text).\n SELECT \"publicAccessLevel\" as access_level\n FROM \"SharePermission\"\n WHERE \"isPublic\" = true AND \"publicAccessLevel\" IS NOT NULL AND id IN (\n SELECT \"sharePermissionId\" FROM \"DocumentPermission\" WHERE \"documentId\" = $1\n UNION\n SELECT \"sharePermissionId\" FROM \"ProjectPermission\" WHERE \"projectId\" IN (SELECT project_id FROM project_hierarchy)\n )\n ) as all_levels\n ",+ "describe": {+ "columns": [+ {+ "ordinal": 0,+ "name": "access_level",+ "type_info": "Text"+ }+ ],+ "parameters": {+ "Left": [+ "Text",+ "Text"+ ]+ },+ "nullable": [+ null+ ]+ },+ "hash": "3a7be99469ed150e0506efa786b672198a6d3419c6bd5548418520cd3e6a8e95"+}diff --git a/rust/cloud-storage/github/.sqlx/query-4afa79ca95bdbcebe9d3de7ebb204636419e6cf89e650a8716c40ab2e588aa5b.json b/rust/cloud-storage/github/.sqlx/query-4afa79ca95bdbcebe9d3de7ebb204636419e6cf89e650a8716c40ab2e588aa5b.jsonnew file mode 100644index 0000000000..58618b2697--- /dev/null+++ b/rust/cloud-storage/github/.sqlx/query-4afa79ca95bdbcebe9d3de7ebb204636419e6cf89e650a8716c40ab2e588aa5b.json@@ -0,0 +1,23 @@+{+ "db_name": "PostgreSQL",+ "query": "\n -- CTE to recursively find all parent projects, starting from the given project.\n WITH RECURSIVE project_hierarchy AS (\n -- Base case: Start with the project ID provided.\n SELECT id as project_id\n FROM \"Project\"\n WHERE id = $1 AND \"deletedAt\" IS NULL\n UNION ALL\n -- Recursive case: Find the parent of the project from the previous step.\n SELECT parent.id as project_id\n FROM project_hierarchy ph\n JOIN \"Project\" parent ON parent.id = (\n SELECT \"parentId\" FROM \"Project\" WHERE id = ph.project_id AND \"parentId\" IS NOT NULL AND \"deletedAt\" IS NULL\n )\n )\n -- The subquery now gathers all levels as plain text.\n SELECT access_level FROM (\n -- Source 1: Cast the AccessLevel enum to text.\n SELECT access_level::text FROM \"UserItemAccess\"\n WHERE user_id = $2 AND item_id IN (\n -- The hierarchy CTE includes the starting project, so this is all we need.\n SELECT project_id FROM project_hierarchy\n )\n UNION ALL\n -- Source 2: Select the publicAccessLevel (which is already text).\n SELECT \"publicAccessLevel\" as access_level\n FROM \"SharePermission\"\n WHERE \"isPublic\" = true AND \"publicAccessLevel\" IS NOT NULL AND id IN (\n -- We only need to check ProjectPermission for the items in the hierarchy.\n SELECT \"sharePermissionId\" FROM \"ProjectPermission\"\n WHERE \"projectId\" IN (SELECT project_id FROM project_hierarchy)\n )\n ) as all_levels\n ",+ "describe": {+ "columns": [+ {+ "ordinal": 0,+ "name": "access_level",+ "type_info": "Text"+ }+ ],+ "parameters": {+ "Left": [+ "Text",+ "Text"+ ]+ },+ "nullable": [+ null+ ]+ },+ "hash": "4afa79ca95bdbcebe9d3de7ebb204636419e6cf89e650a8716c40ab2e588aa5b"+}diff --git a/rust/cloud-storage/github/.sqlx/query-4c695b011d49ba7d5fce4b309875ed952dc386ac760444d7883c5a76718f15be.json b/rust/cloud-storage/github/.sqlx/query-4c695b011d49ba7d5fce4b309875ed952dc386ac760444d7883c5a76718f15be.jsonnew file mode 100644index 0000000000..524cc25ec7--- /dev/null+++ b/rust/cloud-storage/github/.sqlx/query-4c695b011d49ba7d5fce4b309875ed952dc386ac760444d7883c5a76718f15be.json@@ -0,0 +1,23 @@+{+ "db_name": "PostgreSQL",+ "query": "\n WITH RECURSIVE project_hierarchy AS (\n SELECT p.id as project_id\n FROM \"Chat\" c\n JOIN \"Project\" p ON c.\"projectId\" = p.id AND p.\"deletedAt\" IS NULL\n WHERE c.id = $1 AND c.\"deletedAt\" IS NULL\n UNION ALL\n SELECT parent.id as project_id\n FROM project_hierarchy ph\n JOIN \"Project\" parent ON parent.id = (\n SELECT \"parentId\" FROM \"Project\" WHERE id = ph.project_id AND \"parentId\" IS NOT NULL AND \"deletedAt\" IS NULL\n )\n )\n SELECT access_level FROM (\n -- Source 1: Cast the AccessLevel enum to text.\n SELECT access_level::text FROM \"UserItemAccess\"\n WHERE user_id = $2 AND item_id IN (\n SELECT $1 -- The chat itself\n UNION\n SELECT project_id FROM project_hierarchy -- All parent projects\n )\n UNION ALL\n -- Source 2: Select the publicAccessLevel (which is already text).\n SELECT \"publicAccessLevel\" as access_level\n FROM \"SharePermission\"\n WHERE \"isPublic\" = true AND \"publicAccessLevel\" IS NOT NULL AND id IN (\n SELECT \"sharePermissionId\" FROM \"ChatPermission\" WHERE \"chatId\" = $1\n UNION\n SELECT \"sharePermissionId\" FROM \"ProjectPermission\" WHERE \"projectId\" IN (SELECT project_id FROM project_hierarchy)\n )\n ) as all_levels\n ",+ "describe": {+ "columns": [+ {+ "ordinal": 0,+ "name": "access_level",+ "type_info": "Text"+ }+ ],+ "parameters": {+ "Left": [+ "Text",+ "Text"+ ]+ },+ "nullable": [+ null+ ]+ },+ "hash": "4c695b011d49ba7d5fce4b309875ed952dc386ac760444d7883c5a76718f15be"+}diff --git a/rust/cloud-storage/github/.sqlx/query-54e3755d63a676a7fa70da77321e618032f0130c73eb6b0ae985f07c5c6c448b.json b/rust/cloud-storage/github/.sqlx/query-54e3755d63a676a7fa70da77321e618032f0130c73eb6b0ae985f07c5c6c448b.jsonnew file mode 100644index 0000000000..03a8dbf6bb--- /dev/null+++ b/rust/cloud-storage/github/.sqlx/query-54e3755d63a676a7fa70da77321e618032f0130c73eb6b0ae985f07c5c6c448b.json@@ -0,0 +1,22 @@+{+ "db_name": "PostgreSQL",+ "query": "\n WITH RECURSIVE project_hierarchy AS (\n SELECT p.id as project_id\n FROM \"Chat\" c\n JOIN \"Project\" p ON c.\"projectId\" = p.id AND p.\"deletedAt\" IS NULL\n WHERE c.id = $1 AND c.\"deletedAt\" IS NULL\n UNION ALL\n SELECT parent.id as project_id\n FROM project_hierarchy ph\n JOIN \"Project\" parent ON parent.id = (\n SELECT \"parentId\" FROM \"Project\" WHERE id = ph.project_id AND \"parentId\" IS NOT NULL AND \"deletedAt\" IS NULL\n )\n )\n SELECT DISTINCT user_id FROM \"UserItemAccess\"\n WHERE item_id IN (\n SELECT $1\n UNION\n SELECT project_id FROM project_hierarchy\n )\n ",+ "describe": {+ "columns": [+ {+ "ordinal": 0,+ "name": "user_id",+ "type_info": "Text"+ }+ ],+ "parameters": {+ "Left": [+ "Text"+ ]+ },+ "nullable": [+ false+ ]+ },+ "hash": "54e3755d63a676a7fa70da77321e618032f0130c73eb6b0ae985f07c5c6c448b"+}diff --git a/rust/cloud-storage/github/.sqlx/query-7617f808df94ffe77c8195a911ee6b230a21fe9935e099d1310d244248ca253a.json b/rust/cloud-storage/github/.sqlx/query-7617f808df94ffe77c8195a911ee6b230a21fe9935e099d1310d244248ca253a.jsonnew file mode 100644index 0000000000..655495fb29--- /dev/null+++ b/rust/cloud-storage/github/.sqlx/query-7617f808df94ffe77c8195a911ee6b230a21fe9935e099d1310d244248ca253a.json@@ -0,0 +1,23 @@+{+ "db_name": "PostgreSQL",+ "query": "\n SELECT c.id\n FROM comms_channels c\n INNER JOIN comms_channel_participants cp ON cp.channel_id = c.id\n WHERE cp.user_id = $1 AND cp.left_at IS NULL\n AND c.id = ANY($2::uuid[])\n ",+ "describe": {+ "columns": [+ {+ "ordinal": 0,+ "name": "id",+ "type_info": "Uuid"+ }+ ],+ "parameters": {+ "Left": [+ "Text",+ "UuidArray"+ ]+ },+ "nullable": [+ false+ ]+ },+ "hash": "7617f808df94ffe77c8195a911ee6b230a21fe9935e099d1310d244248ca253a"+}diff --git a/rust/cloud-storage/github/.sqlx/query-79d3bc72e6f424765706f7deea426379ae49cbd70dd122daedd95343618b9ac6.json b/rust/cloud-storage/github/.sqlx/query-79d3bc72e6f424765706f7deea426379ae49cbd70dd122daedd95343618b9ac6.jsonnew file mode 100644index 0000000000..2bde15938f--- /dev/null+++ b/rust/cloud-storage/github/.sqlx/query-79d3bc72e6f424765706f7deea426379ae49cbd70dd122daedd95343618b9ac6.json@@ -0,0 +1,22 @@+{+ "db_name": "PostgreSQL",+ "query": "\n WITH RECURSIVE project_hierarchy AS (\n SELECT id as project_id\n FROM \"Project\"\n WHERE id = $1 AND \"deletedAt\" IS NULL\n UNION ALL\n SELECT parent.id as project_id\n FROM project_hierarchy ph\n JOIN \"Project\" parent ON parent.id = (\n SELECT \"parentId\" FROM \"Project\" WHERE id = ph.project_id AND \"parentId\" IS NOT NULL AND \"deletedAt\" IS NULL\n )\n )\n SELECT DISTINCT user_id FROM \"UserItemAccess\"\n WHERE item_id IN (\n SELECT project_id FROM project_hierarchy\n )\n ",+ "describe": {+ "columns": [+ {+ "ordinal": 0,+ "name": "user_id",+ "type_info": "Text"+ }+ ],+ "parameters": {+ "Left": [+ "Text"+ ]+ },+ "nullable": [+ false+ ]+ },+ "hash": "79d3bc72e6f424765706f7deea426379ae49cbd70dd122daedd95343618b9ac6"+}diff --git a/rust/cloud-storage/github/.sqlx/query-96d853b887f2e6d7aac6b15ddd2b71a8d8900d2ef30047da7ca1a5940503b6d0.json b/rust/cloud-storage/github/.sqlx/query-96d853b887f2e6d7aac6b15ddd2b71a8d8900d2ef30047da7ca1a5940503b6d0.jsonnew file mode 100644index 0000000000..e42c9f2009--- /dev/null+++ b/rust/cloud-storage/github/.sqlx/query-96d853b887f2e6d7aac6b15ddd2b71a8d8900d2ef30047da7ca1a5940503b6d0.json@@ -0,0 +1,22 @@+{+ "db_name": "PostgreSQL",+ "query": "\n WITH RECURSIVE project_hierarchy AS (\n SELECT p.id as project_id\n FROM \"Document\" d\n JOIN \"Project\" p ON d.\"projectId\" = p.id AND p.\"deletedAt\" IS NULL\n WHERE d.id = $1 AND d.\"deletedAt\" IS NULL\n UNION ALL\n SELECT parent.id as project_id\n FROM project_hierarchy ph\n JOIN \"Project\" parent ON parent.id = (\n SELECT \"parentId\" FROM \"Project\" WHERE id = ph.project_id AND \"parentId\" IS NOT NULL AND \"deletedAt\" IS NULL\n )\n )\n SELECT DISTINCT user_id FROM \"UserItemAccess\"\n WHERE item_id IN (\n SELECT $1\n UNION\n SELECT project_id FROM project_hierarchy\n )\n ",+ "describe": {+ "columns": [+ {+ "ordinal": 0,+ "name": "user_id",+ "type_info": "Text"+ }+ ],+ "parameters": {+ "Left": [+ "Text"+ ]+ },+ "nullable": [+ false+ ]+ },+ "hash": "96d853b887f2e6d7aac6b15ddd2b71a8d8900d2ef30047da7ca1a5940503b6d0"+}diff --git a/rust/cloud-storage/github/.sqlx/query-b3aeddd507e0efee0e0cecef6eae7503820f0f3302e95a459790c5cb78e5dfb0.json b/rust/cloud-storage/github/.sqlx/query-b3aeddd507e0efee0e0cecef6eae7503820f0f3302e95a459790c5cb78e5dfb0.jsonnew file mode 100644index 0000000000..2b67c5606d--- /dev/null+++ b/rust/cloud-storage/github/.sqlx/query-b3aeddd507e0efee0e0cecef6eae7503820f0f3302e95a459790c5cb78e5dfb0.json@@ -0,0 +1,23 @@+{+ "db_name": "PostgreSQL",+ "query": "\n -- CTE to recursively find all parent projects for the given email thread.\n WITH RECURSIVE project_hierarchy AS (\n -- Base case: Start with the project directly associated with the thread.\n SELECT\n p.id as project_id\n FROM\n \"EmailThreadPermission\" etp\n JOIN \"Project\" p ON etp.\"projectId\" = p.id AND p.\"deletedAt\" IS NULL\n WHERE\n etp.\"threadId\" = $1\n UNION ALL\n -- Recursive case: Find the parent of the project from the previous step.\n SELECT\n parent.id as project_id\n FROM\n project_hierarchy ph\n JOIN \"Project\" parent ON parent.id = (\n SELECT \"parentId\" FROM \"Project\" WHERE id = ph.project_id AND \"parentId\" IS NOT NULL AND \"deletedAt\" IS NULL\n )\n )\n -- The subquery now gathers all levels as plain text.\n SELECT access_level FROM (\n -- Source 1: Cast the AccessLevel enum to text.\n SELECT access_level::text FROM \"UserItemAccess\"\n WHERE user_id = $2 AND item_id IN (\n SELECT $1 -- The thread ID itself\n UNION\n SELECT project_id FROM project_hierarchy -- All parent projects\n )\n UNION ALL\n -- Source 2: Select the publicAccessLevel (which is already text).\n SELECT \"publicAccessLevel\" as access_level\n FROM \"SharePermission\"\n WHERE \"isPublic\" = true AND \"publicAccessLevel\" IS NOT NULL AND id IN (\n SELECT \"sharePermissionId\" FROM \"EmailThreadPermission\" WHERE \"threadId\" = $1\n UNION\n SELECT \"sharePermissionId\" FROM \"ProjectPermission\" WHERE \"projectId\" IN (SELECT project_id FROM project_hierarchy)\n )\n ) as all_levels\n ",+ "describe": {+ "columns": [+ {+ "ordinal": 0,+ "name": "access_level",+ "type_info": "Text"+ }+ ],+ "parameters": {+ "Left": [+ "Text",+ "Text"+ ]+ },+ "nullable": [+ null+ ]+ },+ "hash": "b3aeddd507e0efee0e0cecef6eae7503820f0f3302e95a459790c5cb78e5dfb0"+}diff --git a/rust/cloud-storage/github/.sqlx/query-e7235d6ad2033a2ff7be0bf57ab042cd71e3b3d0e1f8a9750e55cdda92e70c6f.json b/rust/cloud-storage/github/.sqlx/query-e7235d6ad2033a2ff7be0bf57ab042cd71e3b3d0e1f8a9750e55cdda92e70c6f.jsonnew file mode 100644index 0000000000..4c96ff0fd5--- /dev/null+++ b/rust/cloud-storage/github/.sqlx/query-e7235d6ad2033a2ff7be0bf57ab042cd71e3b3d0e1f8a9750e55cdda92e70c6f.json@@ -0,0 +1,22 @@+{+ "db_name": "PostgreSQL",+ "query": "\n WITH RECURSIVE project_hierarchy AS (\n SELECT p.id as project_id\n FROM \"EmailThreadPermission\" etp\n JOIN \"Project\" p ON etp.\"projectId\" = p.id AND p.\"deletedAt\" IS NULL\n WHERE etp.\"threadId\" = $1\n UNION ALL\n SELECT parent.id as project_id\n FROM project_hierarchy ph\n JOIN \"Project\" parent ON parent.id = (\n SELECT \"parentId\" FROM \"Project\" WHERE id = ph.project_id AND \"parentId\" IS NOT NULL AND \"deletedAt\" IS NULL\n )\n )\n SELECT DISTINCT user_id FROM \"UserItemAccess\"\n WHERE item_id IN (\n SELECT $1\n UNION\n SELECT project_id FROM project_hierarchy\n )\n ",+ "describe": {+ "columns": [+ {+ "ordinal": 0,+ "name": "user_id",+ "type_info": "Text"+ }+ ],+ "parameters": {+ "Left": [+ "Text"+ ]+ },+ "nullable": [+ false+ ]+ },+ "hash": "e7235d6ad2033a2ff7be0bf57ab042cd71e3b3d0e1f8a9750e55cdda92e70c6f"+}diff --git a/rust/cloud-storage/github/src/inbound/github_sync_router/mod.rs b/rust/cloud-storage/github/src/inbound/github_sync_router/mod.rsindex 9e5d87be29..9886dfa868 100644--- a/rust/cloud-storage/github/src/inbound/github_sync_router/mod.rs+++ b/rust/cloud-storage/github/src/inbound/github_sync_router/mod.rs@@ -8,7 +8,7 @@mod test;use axum::{- Router, async_trait,+ Router,extract::{FromRequest, Request, State},response::Redirect,};@@ -75,7 +75,6 @@ pub async fn install_sync_handler<T: GithubSyncService>(/// [`ValidatedGithubWebhookEvent`].pub struct GithubWebhookEventExtractor(pub ValidatedGithubWebhookEvent);-#[async_trait]impl<T> FromRequest<GithubSyncRouterState<T>> for GithubWebhookEventExtractorwhereT: GithubSyncService,diff --git a/rust/cloud-storage/macro_middleware/src/auth/internal_access.rs b/rust/cloud-storage/macro_middleware/src/auth/internal_access.rsindex 67105402d8..cf1b0e3bc9 100644--- a/rust/cloud-storage/macro_middleware/src/auth/internal_access.rs+++ b/rust/cloud-storage/macro_middleware/src/auth/internal_access.rs@@ -1,6 +1,5 @@use axum::{- async_trait,- extract::{FromRef, FromRequestParts, Request},+ extract::{FromRef, FromRequestParts, OptionalFromRequestParts, Request},http::{HeaderMap, StatusCode, request::Parts},middleware::Next,response::Response,@@ -25,7 +24,6 @@ env_var!(#[derive(Debug)]pub struct ValidInternalKey(());-#[async_trait]impl<S> FromRequestParts<S> for ValidInternalKeywhereLocalOrRemoteSecret<InternalApiSecretKey>: FromRef<S>,@@ -55,6 +53,25 @@ where}}+impl<S> OptionalFromRequestParts<S> for ValidInternalKey+where+ LocalOrRemoteSecret<InternalApiSecretKey>: FromRef<S>,+ S: Send + Sync + 'static,+{+ type Rejection = std::convert::Infallible;++ async fn from_request_parts(+ parts: &mut Parts,+ state: &S,+ ) -> Result<Option<Self>, Self::Rejection> {+ Ok(+ <Self as FromRequestParts<S>>::from_request_parts(parts, state)+ .await+ .ok(),+ )+ }+}+/// Validates that the INTERNAL_API_KEY_HEADER header is/// provided and valid#[axum::debug_middleware(state = LocalOrRemoteSecret<InternalApiSecretKey>)]diff --git a/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/chat.rs b/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/chat.rsindex 5898c85fb2..fb2ef2828b 100644--- a/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/chat.rs+++ b/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/chat.rs@@ -3,7 +3,7 @@ use std::marker::PhantomData;use super::get_users_access_level_v2;use crate::cloud_storage::ensure_access::{AccessLevelErr, BuildAccessLevel};use axum::{- Extension, RequestPartsExt, async_trait,+ Extension, RequestPartsExt,extract::{FromRef, FromRequestParts},http::request::Parts,};@@ -20,7 +20,6 @@ pub struct ChatAccessLevelExtractor<T> {desired: PhantomData<T>,}-#[async_trait]impl<T, S> FromRequestParts<S> for ChatAccessLevelExtractor<T>whereT: BuildAccessLevel,diff --git a/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/document.rs b/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/document.rsindex 477fad8078..e3bfa36af9 100644--- a/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/document.rs+++ b/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/document.rs@@ -1,7 +1,7 @@use std::marker::PhantomData;use axum::{- Extension, RequestPartsExt, async_trait,+ Extension, RequestPartsExt,extract::{FromRef, FromRequestParts},http::request::Parts,};@@ -19,7 +19,6 @@ pub struct DocumentAccessExtractor<T> {desired: PhantomData<T>,}-#[async_trait]impl<T, S> FromRequestParts<S> for DocumentAccessExtractor<T>whereT: BuildAccessLevel,diff --git a/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/history.rs b/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/history.rsindex d2a09eba2d..37c73bfcd4 100644--- a/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/history.rs+++ b/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/history.rs@@ -3,7 +3,6 @@ use std::marker::PhantomData;use crate::cloud_storage::ensure_access::{AccessLevelErr, BuildAccessLevel, get_users_access_level_v2,};-use axum::async_trait;use axum::extract::FromRef;use axum::http::request::Parts;use axum::{@@ -26,7 +25,6 @@ pub struct HistoryAccessExtractor<T> {desired: PhantomData<T>,}-#[async_trait]impl<T, S> FromRequestParts<S> for HistoryAccessExtractor<T>whereT: BuildAccessLevel,diff --git a/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/pin.rs b/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/pin.rsindex 98aa3c72e1..a7a4bfa9c0 100644--- a/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/pin.rs+++ b/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/pin.rs@@ -5,7 +5,7 @@ use crate::cloud_storage::ensure_access::{};use axum::extract::FromRef;use axum::{- Extension, async_trait,+ Extension,extract::{FromRequest, Path, Request},};use axum::{Json, RequestExt};@@ -36,7 +36,6 @@ pub struct PinAccessLevelExtractor<T, V> {desired: PhantomData<T>,}-#[async_trait]impl<T, S, V> FromRequest<S> for PinAccessLevelExtractor<T, V>whereT: BuildAccessLevel,diff --git a/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/project.rs b/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/project.rsindex b28a05bce1..a422ba1c02 100644--- a/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/project.rs+++ b/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/project.rs@@ -1,7 +1,7 @@use super::get_users_access_level_v2;use crate::cloud_storage::ensure_access::{AccessLevelErr, BuildAccessLevel};use axum::{- Extension, Json, RequestExt, RequestPartsExt, async_trait,+ Extension, Json, RequestExt, RequestPartsExt,extract::{FromRef, FromRequest, FromRequestParts, Request},http::request::Parts,};@@ -19,7 +19,6 @@ pub struct ProjectAccessLevelExtractor<T> {desired: PhantomData<T>,}-#[async_trait]impl<T, S> FromRequestParts<S> for ProjectAccessLevelExtractor<T>whereT: BuildAccessLevel,@@ -131,7 +130,6 @@ impl<T, V> ProjectBodyAccessLevelExtractor<T, V> {}}-#[async_trait]impl<T, S, V> FromRequest<S> for ProjectBodyAccessLevelExtractor<T, V>whereT: BuildAccessLevel,diff --git a/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/thread.rs b/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/thread.rsindex 93142e8973..3984534a18 100644--- a/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/thread.rs+++ b/rust/cloud-storage/macro_middleware/src/cloud_storage/ensure_access/thread.rs@@ -3,7 +3,7 @@ use std::marker::PhantomData;use super::get_users_access_level_v2;use crate::cloud_storage::ensure_access::{AccessLevelErr, BuildAccessLevel};use axum::{- Extension, RequestPartsExt, async_trait,+ Extension, RequestPartsExt,extract::{FromRef, FromRequestParts},http::request::Parts,};@@ -19,7 +19,6 @@ pub struct ThreadAccessLevelExtractor<T> {desired: PhantomData<T>,}-#[async_trait]impl<T, S> FromRequestParts<S> for ThreadAccessLevelExtractor<T>whereT: BuildAccessLevel,diff --git a/rust/cloud-storage/macro_middleware/src/user_permissions/attach_user_permissions.rs b/rust/cloud-storage/macro_middleware/src/user_permissions/attach_user_permissions.rsindex cff0cf009c..5e11cad3dd 100644--- a/rust/cloud-storage/macro_middleware/src/user_permissions/attach_user_permissions.rs+++ b/rust/cloud-storage/macro_middleware/src/user_permissions/attach_user_permissions.rs@@ -1,6 +1,6 @@use crate::error_handler::error_handler;use axum::{- Extension, RequestPartsExt, async_trait,+ Extension, RequestPartsExt,extract::{FromRef, FromRequestParts, Request, State, rejection::ExtensionRejection},http::{StatusCode, request::Parts},middleware::Next,@@ -28,7 +28,6 @@ impl IntoResponse for PermissionErr {}}-#[async_trait]impl<S> FromRequestParts<S> for PermissionsExtractorwhereS: Send + Sync + 'static,diff --git a/rust/cloud-storage/model_user/src/axum_extractor.rs b/rust/cloud-storage/model_user/src/axum_extractor.rsindex df0572b959..5584935cb9 100644--- a/rust/cloud-storage/model_user/src/axum_extractor.rs+++ b/rust/cloud-storage/model_user/src/axum_extractor.rs@@ -35,7 +35,6 @@ pub struct MacroUserExtractor {pub user_context: UserContext,}-#[axum::async_trait]impl<S> FromRequestParts<S> for MacroUserExtractorwhereS: Send + Sync,@@ -68,7 +67,6 @@ pub struct OptionalMacroUserExtractor {pub user_context: UserContext,}-#[axum::async_trait]impl<S> FromRequestParts<S> for OptionalMacroUserExtractorwhereS: Send + Sync,diff --git a/rust/cloud-storage/models_pagination/src/axum.rs b/rust/cloud-storage/models_pagination/src/axum.rsindex 8d4c142915..0364ea03cd 100644--- a/rust/cloud-storage/models_pagination/src/axum.rs+++ b/rust/cloud-storage/models_pagination/src/axum.rs@@ -1,8 +1,8 @@use crate::{Base64SerdeErr, Base64Str, Cursor, CursorVal, CursorWithValAndFilter, Sortable};+use axum::Json;use axum::extract::{FromRequestParts, Query};use axum::http::{StatusCode, request::Parts};use axum::response::IntoResponse;-use axum::{Json, async_trait};use model_error_response::ErrorResponse;use serde::Deserialize;use serde::de::DeserializeOwned;@@ -112,7 +112,6 @@ where.map_err(CursorExtractErr::DecodeErr)}-#[async_trait]impl<S, Id, Sort, F> FromRequestParts<S> for CursorExtractor<Id, Sort, F>whereS: Send + Sync,@@ -177,7 +176,6 @@ impl<Id, S: Sortable, F> BidirectionalCursorExtractor<Id, S, F> {}}-#[async_trait]impl<S, Id, Sort, F> FromRequestParts<S> for BidirectionalCursorExtractor<Id, Sort, F>whereS: Send + Sync,diff --git a/rust/cloud-storage/native_app_service/src/inbound.rs b/rust/cloud-storage/native_app_service/src/inbound.rsindex dcdea2d428..4997c41b94 100644--- a/rust/cloud-storage/native_app_service/src/inbound.rs+++ b/rust/cloud-storage/native_app_service/src/inbound.rs@@ -31,11 +31,11 @@ impl<S> Clone for RouterState<S> {pub fn native_app_router<S: NativeAppService, T>(state: RouterState<S>) -> Router<T> {Router::new().route(- "/update/desktop/:desktop_target/:arch/:current_version",+ "/update/desktop/{desktop_target}/{arch}/{current_version}",get(desktop_update_handler),).route(- "/update/bundle/:all_target/:arch/:current_version",+ "/update/bundle/{all_target}/{arch}/{current_version}",get(bundle_update_handler),).route(diff --git a/rust/cloud-storage/notification_service/src/api/mod.rs b/rust/cloud-storage/notification_service/src/api/mod.rsindex d71c24a68f..41d981f688 100644--- a/rust/cloud-storage/notification_service/src/api/mod.rs+++ b/rust/cloud-storage/notification_service/src/api/mod.rs@@ -82,6 +82,6 @@ fn api_router<S: ::notification::domain::service::NotificationReader>(.nest("/unsubscribe", unsubscribe::router()).layer(middleware);Router::new()- .nest("/:version", internal_router.clone())+ .nest("/{version}", internal_router.clone()).merge(internal_router)}diff --git a/rust/cloud-storage/notification_service/src/api/unsubscribe/mod.rs b/rust/cloud-storage/notification_service/src/api/unsubscribe/mod.rsindex 9a3adbe573..e720e7f01f 100644--- a/rust/cloud-storage/notification_service/src/api/unsubscribe/mod.rs+++ b/rust/cloud-storage/notification_service/src/api/unsubscribe/mod.rs@@ -17,9 +17,12 @@ pub fn router() -> Router<ApiContext> {Router::new().route("/email", get(unsubscribe_email::handler)).route("/", get(get_unsubscribes::handler))- .route("/item/:item_type/:item_id", post(unsubscribe_item::handler)).route(- "/item/:item_type/:item_id",+ "/item/{item_type}/{item_id}",+ post(unsubscribe_item::handler),+ )+ .route(+ "/item/{item_type}/{item_id}",delete(remove_unsubscribe_item::handler),).route(diff --git a/rust/cloud-storage/notification_service/src/api/unsubscribe/remove_unsubscribe_item.rs b/rust/cloud-storage/notification_service/src/api/unsubscribe/remove_unsubscribe_item.rsindex 1edc450188..c7ff637a57 100644--- a/rust/cloud-storage/notification_service/src/api/unsubscribe/remove_unsubscribe_item.rs+++ b/rust/cloud-storage/notification_service/src/api/unsubscribe/remove_unsubscribe_item.rs@@ -15,7 +15,8 @@ use super::unsubscribe_item::UnsubscribeItemPathParams;#[utoipa::path(delete,operation_id = "remove_unsubscribe_item",- path = "/unsubscribe/item/:item_type/:item_id",+ path = "/unsubscribe/item/{item_type}/{item_id}",+ params(UnsubscribeItemPathParams),responses((status = 200, body=EmptyResponse),(status = 401, body=ErrorResponse),diff --git a/rust/cloud-storage/notification_service/src/api/unsubscribe/unsubscribe_item.rs b/rust/cloud-storage/notification_service/src/api/unsubscribe/unsubscribe_item.rsindex 12192b3acd..b16f96bd4d 100644--- a/rust/cloud-storage/notification_service/src/api/unsubscribe/unsubscribe_item.rs+++ b/rust/cloud-storage/notification_service/src/api/unsubscribe/unsubscribe_item.rs@@ -6,13 +6,13 @@ use axum::{};use model::response::{EmptyResponse, ErrorResponse};use serde::{Deserialize, Serialize};-use utoipa::ToSchema;+use utoipa::{IntoParams, ToSchema};use crate::api::context::ApiContext;use model::user::UserContext;-#[derive(Deserialize, Serialize, ToSchema)]+#[derive(Deserialize, Serialize, ToSchema, IntoParams)]pub struct UnsubscribeItemPathParams {pub item_type: String,pub item_id: String,@@ -22,7 +22,8 @@ pub struct UnsubscribeItemPathParams {#[utoipa::path(post,operation_id = "unsubscribe_item",- path = "/unsubscribe/item/:item_type/:item_id",+ path = "/unsubscribe/item/{item_type}/{item_id}",+ params(UnsubscribeItemPathParams),responses((status = 200, body=EmptyResponse),(status = 401, body=ErrorResponse),diff --git a/rust/cloud-storage/notification_service/src/api/user_notification.rs b/rust/cloud-storage/notification_service/src/api/user_notification.rsindex 7f8f323fdb..12129a1398 100644--- a/rust/cloud-storage/notification_service/src/api/user_notification.rs+++ b/rust/cloud-storage/notification_service/src/api/user_notification.rs@@ -110,11 +110,11 @@ pub fn router<S: ::notification::domain::service::NotificationReader>()axum::routing::post(bulk_get_typed_notifications_by_event_item_ids::<S>),).route(- "/item/:event_item_id",+ "/item/{event_item_id}",axum::routing::get(get_typed_by_event_item_id::<S>),).route(- "/:notification_id",+ "/{notification_id}",axum::routing::get(get_typed_notification_by_id::<S>).delete(::notification::inbound::http::delete_notification::<S>),)diff --git a/rust/cloud-storage/properties_service/src/api/properties/mod.rs b/rust/cloud-storage/properties_service/src/api/properties/mod.rsindex 06fc969504..4c846a1386 100644--- a/rust/cloud-storage/properties_service/src/api/properties/mod.rs+++ b/rust/cloud-storage/properties_service/src/api/properties/mod.rs@@ -23,25 +23,25 @@ pub fn router() -> Router<PropertiesHandlerState> {.layer(ensure_user_exists.clone()),).route(- "/definitions/:definition_id",+ "/definitions/{definition_id}",delete(definitions::delete::delete_property_definition).layer(ensure_user_exists.clone()),)// Property Options Management - requires authentication.route(- "/definitions/:definition_id/options",+ "/definitions/{definition_id}/options",get(options::get::get_property_options).post(options::create::add_property_option).layer(ensure_user_exists.clone()),).route(- "/definitions/:definition_id/options/:option_id",+ "/definitions/{definition_id}/options/{option_id}",delete(options::delete::delete_property_option).layer(ensure_user_exists.clone()),)// Entity Property Operations// GET allows anonymous access for public entities.route(- "/entities/:entity_type/:entity_id",+ "/entities/{entity_type}/{entity_id}",get(entities::get::get_entity_properties),)// Bulk entity properties - requires authentication@@ -51,17 +51,17 @@ pub fn router() -> Router<PropertiesHandlerState> {)// PUT/DELETE require authentication.route(- "/entities/:entity_type/:entity_id/:property_id",+ "/entities/{entity_type}/{entity_id}/{property_id}",put(entities::set::set_entity_property).layer(ensure_user_exists.clone()),).route(- "/entity_properties/:entity_property_id",+ "/entity_properties/{entity_property_id}",delete(entities::delete_property::delete_entity_property).layer(ensure_user_exists.clone()),)// Status shortcut - requires authentication.route(- "/entities/:entity_type/:entity_id/status/complete",+ "/entities/{entity_type}/{entity_id}/status/complete",patch(entities::set_property_status_complete::set_property_status_complete).layer(ensure_user_exists),)diff --git a/rust/cloud-storage/search_processing_service/src/api/internal/mod.rs b/rust/cloud-storage/search_processing_service/src/api/internal/mod.rsindex a482f4d3ee..8112edf7e6 100644--- a/rust/cloud-storage/search_processing_service/src/api/internal/mod.rs+++ b/rust/cloud-storage/search_processing_service/src/api/internal/mod.rs@@ -9,6 +9,6 @@ pub(in crate::api) mod extract_sync;pub fn router() -> Router<ApiContext> {Router::new()- .route("/delete/:document_id", delete(delete_document::handler))+ .route("/delete/{document_id}", delete(delete_document::handler)).route("/extract_sync", post(extract_sync::handler))}diff --git a/rust/cloud-storage/static_file_service/src/api/file/mod.rs b/rust/cloud-storage/static_file_service/src/api/file/mod.rsindex 9444d6343f..11509e2885 100644--- a/rust/cloud-storage/static_file_service/src/api/file/mod.rs+++ b/rust/cloud-storage/static_file_service/src/api/file/mod.rs@@ -12,15 +12,15 @@ use crate::api::context::AppState;pub fn router() -> Router<AppState> {Router::new().route(- "/file/metadata/:file_id",+ "/file/metadata/{file_id}",get(metadata::handle_get_metadata),).route(- "/file/:file_id/presigned-url",+ "/file/{file_id}/presigned-url",get(get_file::handle_get_presigned_url),).route("/file", put(put_presigned_url::put_presigned_url))- .route("/file/:file_id", delete(delete_file::handle_delete_file))+ .route("/file/{file_id}", delete(delete_file::handle_delete_file)).route("/file/bulk-delete",post(bulk_delete_file::handle_bulk_delete_file),